|
Special Relativity in Financial Modeling 1.0.0
Lorentz transforms, spacetime classification, and geodesic price paths for quantitative finance
|
Computes Christoffel symbols Γ^λ_μν for an NAssetManifold. More...
#include <christoffel_n.hpp>
Public Member Functions | |
| ChristoffelN (const NAssetManifold &manifold) noexcept | |
| Construct from a manifold reference. | |
| std::optional< double > | symbol (int lambda, int mu, int nu, const Eigen::VectorXd &x) const noexcept |
| Compute a single Christoffel symbol Γ^lambda_mu_nu at point x. | |
| std::optional< std::vector< std::vector< std::vector< double > > > > | all_symbols (const Eigen::VectorXd &x) const noexcept |
| Compute all Christoffel symbols at point x. | |
| bool | verify_symmetry (const Eigen::VectorXd &x, double tol=1e-10) const noexcept |
| Verify that Γ^λ_μν = Γ^λ_νμ for all indices at point x. | |
| int | dim () const noexcept |
| Return the dimension of the manifold. | |
Static Public Attributes | |
| static constexpr double | FD_STEP = 1e-5 |
| Central finite-difference step size used for metric derivatives. | |
Computes Christoffel symbols Γ^λ_μν for an NAssetManifold.
Metric derivatives are approximated by central finite differences with step size FD_STEP. For a constant metric all derivatives vanish and every Christoffel symbol is exactly zero.
Definition at line 44 of file christoffel_n.hpp.
|
explicitnoexcept |
Construct from a manifold reference.
The manifold must remain valid for the lifetime of this object.
| manifold | The NAssetManifold providing the metric. |
Definition at line 28 of file christoffel_n.cpp.
|
noexcept |
|
inlinenoexcept |
Return the dimension of the manifold.
Definition at line 151 of file christoffel_n.hpp.
|
noexcept |
Compute a single Christoffel symbol Γ^lambda_mu_nu at point x.
Uses the formula: Γ^λ_μν = ½ g^λσ (∂_μ g_νσ + ∂_ν g_μσ - ∂_σ g_μν)
Metric derivatives are approximated by central FD with step FD_STEP.
| lambda | Contravariant index, in [0, dim). |
| mu | First covariant index, in [0, dim). |
| nu | Second covariant index, in [0, dim). |
| x | Coordinate point, must have length dim(). |
Definition at line 67 of file christoffel_n.cpp.
|
noexcept |
Verify that Γ^λ_μν = Γ^λ_νμ for all indices at point x.
Checks the symmetry of the lower two indices, which holds for torsion-free connections.
| x | Coordinate point of length dim(). |
| tol | Tolerance for the symmetry check (default 1e-10). |
Definition at line 159 of file christoffel_n.cpp.
|
staticconstexpr |
Central finite-difference step size used for metric derivatives.
Definition at line 47 of file christoffel_n.hpp.