Planetary Orbital Evolution due to Tides
Orbital evolution of two objects experiencing tides
EvolvingStellarZone.h
Go to the documentation of this file.
1 
8 #ifndef __EVOLVING_STELLAR_ZONE_H
9 #define __EVOLVING_STELLAR_ZONE_H
10 
11 #include "../Core/SharedLibraryExportMacros.h"
12 #include "../Evolve/BrokenPowerlawPhaseLagZone.h"
13 #include "../Core/Functions.h"
14 #include "../StellarEvolution/EvolvingStellarQuantity.h"
15 
16 #include <initializer_list>
17 
18 namespace Star {
19 
21  class LIB_PUBLIC EvolvingStellarZone :
23  {
24  private:
26  double __current_age;
27 
30  mutable std::vector< const Core::FunctionDerivatives* >
32 
34  const std::vector< const StellarEvolution::EvolvingStellarQuantity* >
36 
38  void reset_current_quantities();
39 
40  public:
46  std::initializer_list<
48  > evolving_quantities
49  ) :
50  __current_age(Core::NaN),
51  __current_age_quantities(evolving_quantities.size(), NULL),
52  __evolving_quantities(evolving_quantities)
53  {}
54 
57  virtual void configure(
59  bool initialize,
60 
62  double age,
63 
65  double orbital_frequency,
66 
68  double eccentricity,
69 
71  double orbital_angmom,
72 
75  double spin,
76 
78  double inclination,
79 
82  double periapsis,
83 
85  bool spin_is_frequency
86  );
87 
92  //__current_age_quantities if already present.
93  double current_age_quantity(
96  size_t quantity,
97 
99  unsigned deriv_order=0
100  ) const;
101 
106  double any_age_quantity(
109  size_t quantity,
110 
112  double age,
113 
115  unsigned deriv_order=0
116  ) const;
117 
119  double current_age() {return __current_age;}
120 
124  void reached_critical_age(double age);
125 
128  double next_stop_age() const;
129 
131  double min_interp_age() const;
132 
139  virtual void select_interpolation_region(double age) const;
140 
143  };//End EvolvingStellarZone class.
144 
145 }//End Star namespace.
146 
147 #endif
EvolvingStellarZone(std::initializer_list< const StellarEvolution::EvolvingStellarQuantity * > evolving_quantities)
std::vector< const Core::FunctionDerivatives *> __current_age_quantities
Pre-computed values and derivatives for quantities which only depend on age at the current age...
double current_age()
Return the last age with which ::configure() was called.
Base class for zones of low mass evolving stars.
double __current_age
The age for the last configure() call.
A class for stellar properties that depend on age.
const std::vector< const StellarEvolution::EvolvingStellarQuantity *> __evolving_quantities
The quantities describing the stellar zone.
void select_interpolation_region(const EvolvingStar *star, double age)
Prepare the zone quantities for interpolation around the given age.
Definition: CInterface.cpp:99
A DissipatingZone where the phase lag is described by a broken powerlaw.