Planetary Orbital Evolution due to Tides
Orbital evolution of two objects experiencing tides
YRECEvolution Class Reference

A stellar evolution interpolator based on the YREC tracks. More...

#include <YRECIO.h>

+ Inheritance diagram for YRECEvolution:
+ Collaboration diagram for YRECEvolution:

Public Member Functions

 YRECEvolution ()
 Default constructor, use load_state to get a working interpolator. More...
 
 YRECEvolution (const std::string &model_directory, double smooth_radius=-2.0, double smooth_conv_inertia=0, double smooth_rad_inertia=2.0, double smooth_rad_mass=2.0, double smooth_core_env_boundary=3.5, int radius_nodes=-1000, int conv_inertia_nodes=-1000, int rad_inertia_nodes=-1000, int rad_mass_nodes=-1000, int core_env_boundary_nodes=-5000)
 Creates a stellar evolution interpolator based on evolution tracks computed with YREC. More...
 

Private Member Functions

void read_model_file (const std::string &filename)
 Reads a single evolution track file. More...
 
EvolutionIterator begin ()
 Returns an EvolutionIterator pointing to the beginning of all quantities. More...
 
EvolutionIterator end ()
 Returns an EvolutionIterator pointing to the end of all quantities. More...
 
void move (EvolutionIterator &dest, EvolutionIterator &source)
 Moves source to right before destination. More...
 
void sort_masses ()
 Sorts the data by mass. More...
 

Private Attributes

std::list< double > mass_list
 The masses of the available tracks. More...
 
std::list< std::valarray< double > > ages
 The ages in each track. More...
 
std::list< std::valarray< double > > radii
 The stellar radii in each track. More...
 
std::list< std::valarray< double > > luminosities
 The luminosities in each track. More...
 
std::list< std::valarray< double > > rad_masses
 The masses of the core in each track. More...
 
std::list< std::valarray< double > > core_boundaries
 The core-envelope boundary radius in each track. More...
 
std::list< std::valarray< double > > conv_inertias
 The moments of inertia of the convective envelope. More...
 
std::list< std::valarray< double > > rad_inertias
 The moments of inertia of the radiative zone of the star. More...
 

Detailed Description

A stellar evolution interpolator based on the YREC tracks.

It relies on 10 tracks, all at solar metallicitity and none of them going past 10Gyr stellar age. The masses of the tracks are (in \(M_\odot\)): 0.5, 0.6, 0.7, 0.8, 0.9, 1.0, 1.05, 1.1, 1.15, and 1.2.

Definition at line 148 of file YRECIO.h.

Constructor & Destructor Documentation

◆ YRECEvolution() [1/2]

YRECEvolution::YRECEvolution ( )
inline

Default constructor, use load_state to get a working interpolator.

Definition at line 186 of file YRECIO.h.

◆ YRECEvolution() [2/2]

YRECEvolution::YRECEvolution ( const std::string &  model_directory,
double  smooth_radius = -2.0,
double  smooth_conv_inertia = 0,
double  smooth_rad_inertia = 2.0,
double  smooth_rad_mass = 2.0,
double  smooth_core_env_boundary = 3.5,
int  radius_nodes = -1000,
int  conv_inertia_nodes = -1000,
int  rad_inertia_nodes = -1000,
int  rad_mass_nodes = -1000,
int  core_env_boundary_nodes = -5000 
)

Creates a stellar evolution interpolator based on evolution tracks computed with YREC.

Parameters
model_directoryThe directory containing the YREC evolution tracks
smooth_radiusHow much to smooth the radius of the star when fitting.
smooth_conv_inertiaHow much to smooth the moment of inertia of the convective zone when fitting.
smooth_rad_inertiaHow much to smooth the moment of inertia of the radiative zone of the star when fitting.
smooth_rad_massHow much to smooth the mass in the radiative zone when fitting.
smooth_core_env_boundaryHow much to smooth the radius in the radiative zone when fitting.
radius_nodesHow many nodes to use when smoothing the stellar radius (ignored if smooth_conv_inertia is NaN - no smoothing).

Negative values result in using min(-radius_nodes, number of tabulated ages for each track).

Parameters
conv_inertia_nodesHow many nodes to use when smoothing the moment of inertia of the convective zone (ignored if smooth_conv_inertia is NaN - no smoothing).

Negative values result in using min(-conv_inertia_nodes, number of tabulated ages for each track).

Parameters
rad_inertia_nodesHow many nodes to use when smoothing the moment of inertia of the radiative zone (ignored if smooth_rad_inertia is NaN - no smoothing).

Negative values result in using min(-rad_inertia_nodes, number of tabulated ages for each track).

Parameters
rad_mass_nodesHow many nodes to use when smoothing the mass of the radiative zone (ignored if smooth_rad_mass is NaN - no smoothing).

Negative values result in using min(-rad_mass_nodes, number of tabulated ages for each track).

Parameters
core_env_boundary_nodesHow many nodes to use when smoothing the radius of the radiative zone (ignored if smooth_core_env_boundary is NaN - no smoothing).

Negative values result in using min(-core_env_boundary_nodes, number of tabulated ages for each track).

Definition at line 226 of file YRECIO.cpp.

Member Function Documentation

◆ begin()

EvolutionIterator YRECEvolution::begin ( )
private

Returns an EvolutionIterator pointing to the beginning of all quantities.

Definition at line 165 of file YRECIO.cpp.

◆ end()

EvolutionIterator YRECEvolution::end ( )
private

Returns an EvolutionIterator pointing to the end of all quantities.

Definition at line 179 of file YRECIO.cpp.

◆ move()

void YRECEvolution::move ( EvolutionIterator dest,
EvolutionIterator source 
)
private

Moves source to right before destination.

Definition at line 193 of file YRECIO.cpp.

◆ read_model_file()

void YRECEvolution::read_model_file ( const std::string &  filename)
private

Reads a single evolution track file.

Definition at line 102 of file YRECIO.cpp.

◆ sort_masses()

void YRECEvolution::sort_masses ( )
private

Sorts the data by mass.

Definition at line 209 of file YRECIO.cpp.

Member Data Documentation

◆ ages

std::list< std::valarray<double> > YRECEvolution::ages
private

The ages in each track.

Definition at line 154 of file YRECIO.h.

◆ conv_inertias

std::list< std::valarray<double> > YRECEvolution::conv_inertias
private

The moments of inertia of the convective envelope.

Definition at line 154 of file YRECIO.h.

◆ core_boundaries

std::list< std::valarray<double> > YRECEvolution::core_boundaries
private

The core-envelope boundary radius in each track.

Definition at line 154 of file YRECIO.h.

◆ luminosities

std::list< std::valarray<double> > YRECEvolution::luminosities
private

The luminosities in each track.

Definition at line 154 of file YRECIO.h.

◆ mass_list

std::list<double> YRECEvolution::mass_list
private

The masses of the available tracks.

Definition at line 151 of file YRECIO.h.

◆ rad_inertias

std::list< std::valarray<double> > YRECEvolution::rad_inertias
private

The moments of inertia of the radiative zone of the star.

Definition at line 154 of file YRECIO.h.

◆ rad_masses

std::list< std::valarray<double> > YRECEvolution::rad_masses
private

The masses of the core in each track.

Definition at line 154 of file YRECIO.h.

◆ radii

std::list< std::valarray<double> > YRECEvolution::radii
private

The stellar radii in each track.

Definition at line 154 of file YRECIO.h.


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