Special Relativity in Financial Modeling 1.0.0
Lorentz transforms, spacetime classification, and geodesic price paths for quantitative finance
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
srfm::portfolio::PortfolioState Struct Reference

A point in portfolio space + time. More...

#include <geodesic_path.hpp>

Public Member Functions

int dim () const noexcept
 Dimension of the portfolio (number of assets).
 
bool is_valid () const noexcept
 Returns true if weights is non-empty and all elements are finite.
 
double sum_weights () const noexcept
 Sum of all weights.
 

Public Attributes

std::vector< double > weights
 Portfolio weights (any length >= 1)
 
int64_t timestamp_ms
 Wall-clock time in milliseconds.
 

Detailed Description

A point in portfolio space + time.

Definition at line 52 of file geodesic_path.hpp.

Member Function Documentation

◆ dim()

int srfm::portfolio::PortfolioState::dim ( ) const
inlinenoexcept

Dimension of the portfolio (number of assets).

Definition at line 57 of file geodesic_path.hpp.

◆ is_valid()

bool srfm::portfolio::PortfolioState::is_valid ( ) const
noexcept

Returns true if weights is non-empty and all elements are finite.

Definition at line 33 of file geodesic_path.cpp.

◆ sum_weights()

double srfm::portfolio::PortfolioState::sum_weights ( ) const
noexcept

Sum of all weights.

Definition at line 41 of file geodesic_path.cpp.

Member Data Documentation

◆ timestamp_ms

int64_t srfm::portfolio::PortfolioState::timestamp_ms

Wall-clock time in milliseconds.

Definition at line 54 of file geodesic_path.hpp.

◆ weights

std::vector<double> srfm::portfolio::PortfolioState::weights

Portfolio weights (any length >= 1)

Definition at line 53 of file geodesic_path.hpp.


The documentation for this struct was generated from the following files: