9 #ifndef __POLYNOMIAL_EVOLUTION_ZONE_H 10 #define __POLYNOMIAL_EVOLUTION_ZONE_H 12 #include "../../Evolve/DissipatingZone.h" 14 #include <gsl/gsl_poly.h> 48 const std::valarray<double> &coefficients,
60 const std::valarray<double> &mass_coefficients,
63 const std::valarray<double> &radius_coefficients,
67 const std::valarray<double> &inertia_coefficients
70 __radius_coefficients(radius_coefficients),
71 __inertia_coefficients(inertia_coefficients),
73 __current_radius(
Core::NaN, 3),
74 __current_inertia(
Core::NaN, 3)
80 double orbital_frequency,
82 double orbital_angmom,
86 bool spin_is_frequency);
98 {
return __current_radius[deriv_order];}
106 {
return __current_inertia[deriv_order];}
virtual double moment_of_inertia(double age, int deriv_order=0) const
See DissipatingZone::moment_of_inertia(double, int).
double love_coefficient(int, int, Dissipation::QuantityEntry) const
See DissipatingZone::love_coefficient()
double periapsis(bool evolution_rate=false) const
The argument of periapsis of this zone minus the reference zone's.
double outer_radius(int deriv_order=0) const
See DissipatingZone::outer_radius(int).
std::valarray< double > __current_radius
The outer radius ofthe zone at the age of the last call to configure() and its first and second deriv...
std::valarray< double > __current_mass
The outer mass ofthe zone at the age of the last call to configure() and its first and second derivat...
Orientations of zones of bodies in a binary system.
double outer_mass(double age, int deriv_order=0) const
See DissipatingZone::outer_mass(double, int).
A layer of a system body for which the tidal bulge is not exactly in phase with the tidal potential...
virtual void configure(bool initialize, double age, double orbital_frequency, double eccentricity, double orbital_angmom, double spin, double inclination, double periapsis, bool spin_is_frequency)
See DissipatingZone::configure().
PolynomialEvolutionZone(const std::valarray< double > &mass_coefficients, const std::valarray< double > &radius_coefficients, const std::valarray< double > &inertia_coefficients)
Construct a polynomial evolution zone with the given coefficients.
std::valarray< double > __inertia_coefficients
The coefficients of the polynomial for the moment of inertia evolution.
std::valarray< double > __radius_coefficients
The coefficients of the polynomial for the radius evolution.
virtual double moment_of_inertia(int deriv_order=0) const
See DissipatingZone::moment_of_inertia(int).
double outer_radius(double age, int deriv_order=0) const
See DissipatingZone::outer_radius(double, int).
double inclination(bool evolution_rate=false) const
The angle between the angular momenta of the zone and the orbit.
std::valarray< double > __current_inertia
The moment of inertia ofthe zone at the age of the last call to configure() and its first and second ...
double outer_mass(int deriv_order=0) const
See DissipatingZone::outer_mass(int).
double evaluate_polynomial(const std::valarray< double > &coefficients, double age, int deriv_order) const
Evaluate either the given order derivative of either the mass or the radius polynomial.
std::valarray< double > __mass_coefficients
The coefficients of the polynomial for the mass evolution.