|
SpECTRE
v2026.04.01
|
A static spherically symmetric star. More...
#include <TovStar.hpp>
Classes | |
| struct | CentralDensity |
| The central density of the star. More... | |
| struct | Coordinates |
| Areal (Schwarzschild) or isotropic coordinates. More... | |
Public Types | |
| using | equation_of_state_type = EquationsOfState::EquationOfState<true, 1> |
| using | options |
| template<typename DataType> | |
| using | tags |
| Public Types inherited from RelativisticEuler::AnalyticSolution< 3 > | |
| using | tags |
Public Member Functions | |
| TovStar (const TovStar &) | |
| TovStar & | operator= (const TovStar &) |
| TovStar (TovStar &&)=default | |
| TovStar & | operator= (TovStar &&)=default |
| TovStar (double central_rest_mass_density, std::unique_ptr< EquationsOfState::EquationOfState< true, 1 > > equation_of_state, const RelativisticEuler::Solutions::TovCoordinates coordinate_system=RelativisticEuler::Solutions::TovCoordinates::Schwarzschild) | |
| auto | get_clone () const -> std::unique_ptr< evolution::initial_data::InitialData > override |
| template<typename DataType, typename... Tags> | |
| tuples::TaggedTuple< Tags... > | variables (const tnsr::I< DataType, 3 > &x, const double, tmpl::list< Tags... >) const |
| Retrieve a collection of variables at (x, t) | |
| void | pup (PUP::er &) override |
| NOLINTNEXTLINE(google-runtime-references) | |
| const EquationsOfState::EquationOfState< true, 1 > & | equation_of_state () const |
| const RelativisticEuler::Solutions::TovSolution & | radial_solution () const |
| The radial profile of the star. | |
Static Public Attributes | |
| static constexpr size_t | volume_dim = 3_st |
| static constexpr Options::String | help |
| Static Public Attributes inherited from RelativisticEuler::AnalyticSolution< 3 > | |
| static constexpr size_t | volume_dim |
Protected Member Functions | |
| template<template< class, tov_detail::StarRegion > class VarsComputer, typename DataType, typename... Tags, typename... VarsComputerArgs> | |
| tuples::TaggedTuple< Tags... > | variables_impl (const tnsr::I< DataType, 3 > &x, tmpl::list< Tags... >, VarsComputerArgs &&... vars_computer_args) const |
Friends | |
| bool | operator== (const TovStar &lhs, const TovStar &rhs) |
A static spherically symmetric star.
An analytic solution for a static, spherically-symmetric star found by solving the Tolman-Oppenheimer-Volkoff (TOV) equations. The equation of state is assumed to be that of a polytropic fluid.
If the spherically symmetric metric is written as
\[ds^2 = - e^{2 \Phi_t} dt^2 + e^{2 \Phi_r} dr^2 + e^{2 \Phi_\Omega} r^2 d\Omega^2 \]
where \(r = \delta_{mn} x^m x^n\) is the radial coordinate and \(\Phi_t\), \(\Phi_r\), and \(\Phi_\Omega\) are the metric potentials, then the lapse, shift, and spatial metric in Cartesian coordinates are
\begin{align*}\alpha &= e^{\Phi_t} \\ \beta^i &= 0 \\ \gamma_{ij} &= \delta_{ij} e^{2 \Phi_\Omega} + \delta_{im} \delta_{jn} \frac{x^m x^n}{r^2} \left( e^{2 \Phi_r} - e^{2 \Phi_\Omega} \right) \end{align*}
We solve the TOV equations with the method implemented in RelativisticEuler::Solutions::TovSolution. It provides the areal mass-over-radius \(m(r)/r\) and the log of the specific enthalpy \(\log{h}\). In areal (Schwarzschild) coordinates the spatial metric potentials are
\begin{align}e^{\Phi_r} &= \left(1 - \frac{2m}{r}\right)^{-1/2} \\ e^{\Phi_\Omega} &= 1 \end{align}
In isotropic coordinates the spatial metric potentials are
\begin{equation}e^{2\Phi_r} = e^{2\Phi_\Omega} = \psi^4 \text{,} \end{equation}
where \(\psi = \sqrt{r / \bar{r}}\) is the conformal factor, \(r\) is the areal (Schwarzschild) radius and \(\bar{r}\) is the isotropic radius. See RelativisticEuler::Solutions::TovSolution for details.
| using RelativisticEuler::Solutions::TovStar::options |
| using RelativisticEuler::Solutions::TovStar::tags |
|
overridevirtual |
Implements evolution::initial_data::InitialData.
|
staticconstexpr |