52 #ifndef __PCL_OsculatingElements_h
53 #define __PCL_OsculatingElements_h
201 return Abs( 1 - this->e ) < 0.001;
251 return Norm2Pi( MeanMotion( GM, m )*(t - this->T) );
262 return MeanAnomalyFromTimeOfPerifocalPassage( t, GM, m );
281 return t - this->M/MeanMotion( GM, m );
292 return TimeOfPerifocalPassageFromMeanAnomaly( t, GM, m );
300 return (1 - this->e)*this->a;
311 return PerifocalDistanceFromSemimajorAxis();
319 double ai = (1 - this->e)/this->q;
320 if (
Abs( ai ) < 2*std::numeric_limits<double>::epsilon() )
333 return SemimajorAxisFromPerifocalDistance();
389 ToPerifocalPositionAndVelocity( xp, yp, u1, u2, t, GM, m );
Generic vector of arbitrary length.
Osculating conic orbital elements.
double MeanMotion(double GM=0, double m=0) const
double PerihelionDistanceFromSemimajorAxis() const
bool IsNearParabolic() const
OsculatingElements(const OsculatingElements &)=default
static void GetOrbitOrientationFromStateVectors(double &i, double &O, double &w, const Vector &r, const Vector &v, double GM=0, double m=0)
double MeanAnomalyFromTimeOfPerihelionPassage(const TimePoint &t, double GM=0, double m=0) const
double MeanAnomalyFromTimeOfPerifocalPassage(const TimePoint &t, double GM=0, double m=0) const
void ToPerifocalPosition(double &xp, double &yp, const TimePoint &t, double GM=0, double m=0) const
double OrbitalPeriod(double GM=0, double m=0) const
TimePoint TimeOfPerifocalPassageFromMeanAnomaly(const TimePoint &t, double GM=0, double m=0) const
static OsculatingElements FromStateVectors(const Vector &r, const Vector &v, const TimePoint &t, double GM=0, double m=0)
void ToStateVectors(Vector &r, Vector &v, const TimePoint &t, double GM=0, double m=0) const
TimePoint TimeOfPerihelionPassageFromMeanAnomaly(const TimePoint &t, double GM=0, double m=0) const
void ToPerifocalPositionAndVelocity(double &xp, double &yp, double &xv, double &yv, const TimePoint &t, double GM=0, double m=0) const
double SemimajorAxisFromPerifocalDistance() const
double PerifocalDistanceFromSemimajorAxis() const
OsculatingElements()=default
double SemimajorAxisFromPerihelionDistance() const
OsculatingElements(const Vector &r, const Vector &v, const TimePoint &t, double GM=0, double m=0)
An instant in any timescale.
T Abs(const Complex< T > &c) noexcept
constexpr T Norm2Pi(T x) noexcept