public final class OrbitalElements extends Object
Modifier and Type | Method and Description |
---|---|
static double |
computeEccentricity(double radiusOfPeriapsis,
double inverseSemimajorAxis)
Calculates the eccentricity of the orbit.
|
static double |
computeMeanMotion(double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter)
Calculates the mean motion of the orbit.
|
static double |
computePeriod(double inverseSemimajorAxis,
double gravitationalParameter)
Calculates the period of the orbit.
|
static double |
computeRadiusOfApoapsis(double radiusOfPeriapsis,
double eccentricity)
Calculates the radius of apoapsis of the orbit.
|
static double |
computeRadiusOfPeriapsis(double semilatusRectum,
double eccentricity)
Calculates the radius of periapsis of the orbit.
|
static double |
computeSemilatusRectum(double radiusOfPeriapsis,
double eccentricity)
Calculates the semilatus rectum of the orbit.
|
static double |
computeSemimajorAxis(double radiusOfPeriapsis,
double eccentricity)
Calculates the semimajor axis of the orbit.
|
static double |
computeTimeOfFlight(double initialTrueAnomaly,
double finalTrueAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter)
Calculates the time of flight between two true anomalies.
|
static double |
convertEccentricAnomalyToMeanAnomaly(double eccentricAnomaly,
double eccentricity)
Tries to convert the eccentric anomaly to the mean anomaly.
|
static double |
convertEccentricAnomalyToTimeFromPeriapsis(double eccentricAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter)
Converts the eccentric anomaly to the time of flight from the corresponding periapsis passage in seconds.
|
static double |
convertEccentricAnomalyToTrueAnomaly(double eccentricAnomaly,
double eccentricity)
Converts the eccentric anomaly to the true anomaly.
|
static double |
convertHyperbolicAnomalyToMeanAnomaly(double hyperbolicAnomaly,
double eccentricity)
Converts the hyperbolic anomaly to the mean anomaly.
|
static double |
convertHyperbolicAnomalyToTimeFromPeriapsis(double hyperbolicAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter)
Converts the hyperbolic anomaly to the time of flight from the corresponding periapsis passage in seconds.
|
static double |
convertHyperbolicAnomalyToTrueAnomaly(double hyperbolicAnomaly,
double eccentricity)
Converts the hyperbolic anomaly to the true anomaly.
|
static double |
convertMeanAnomalyToEccentricAnomaly(double meanAnomaly,
double eccentricity)
Converts the mean anomaly to the eccentric anomaly.
|
static double |
convertMeanAnomalyToHyperbolicAnomaly(double meanAnomaly,
double eccentricity)
Tries to convert the mean anomaly to the hyperbolic anomaly.
|
static double |
convertMeanAnomalyToParabolicAnomaly(double meanAnomaly,
double eccentricity)
Converts the mean anomaly to the parabolic anomaly.
|
static double |
convertMeanAnomalyToTimeFromPeriapsis(double meanAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter)
Converts the mean anomaly to the time of flight from the corresponding periapsis passage in seconds.
|
static double |
convertMeanAnomalyToTimeSincePreviousPeriapsis(double meanAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter)
Converts the mean anomaly to the time of flight since the previous periapsis passage in seconds.
|
static double |
convertMeanAnomalyToTimeUntilNextPeriapsis(double meanAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter)
Converts the mean anomaly to the time of flight until the next periapsis passage in seconds.
|
static double |
convertMeanAnomalyToTrueAnomaly(double meanAnomaly,
double eccentricity)
Converts the mean anomaly to the true anomaly.
|
static double |
convertParabolicAnomalyToMeanAnomaly(double parabolicAnomaly,
double eccentricity)
Converts the parabolic anomaly to the mean anomaly.
|
static double |
convertParabolicAnomalyToTimeFromPeriapsis(double parabolicAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter)
Converts the parabolic anomaly to the time of flight from the corresponding periapsis passage in seconds.
|
static double |
convertParabolicAnomalyToTrueAnomaly(double parabolicAnomaly,
double eccentricity)
Converts the parabolic anomaly to the true anomaly.
|
static double |
convertTimeFromPeriapsisToEccentricAnomaly(double timeFromPeriapsis,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter)
Converts the time from periapsis passage to eccentric anomaly.
|
static double |
convertTimeFromPeriapsisToHyperbolicAnomaly(double timeFromPeriapsis,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter)
Converts the time from periapsis passage to hyperbolic anomaly.
|
static double |
convertTimeFromPeriapsisToMeanAnomaly(double timeFromPeriapsis,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter)
Converts the time from periapsis passage to mean anomaly.
|
static double |
convertTimeFromPeriapsisToParabolicAnomaly(double timeFromPeriapsis,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter)
Converts the time from periapsis passage to parabolic anomaly.
|
static double |
convertTimeFromPeriapsisToTrueAnomaly(double timeFromPeriapsis,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter)
Converts the time from periapsis passage to true anomaly.
|
static double |
convertTrueAnomalyToEccentricAnomaly(double trueAnomaly,
double eccentricity)
Converts the true anomaly to the eccentric anomaly.
|
static double |
convertTrueAnomalyToHyperbolicAnomaly(double trueAnomaly,
double eccentricity)
Converts the true anomaly to the hyperbolic anomaly.
|
static double |
convertTrueAnomalyToMeanAnomaly(double trueAnomaly,
double eccentricity)
Converts the true anomaly to the mean anomaly.
|
static double |
convertTrueAnomalyToParabolicAnomaly(double trueAnomaly,
double eccentricity)
Converts the true anomaly to the parabolic anomaly.
|
static double |
convertTrueAnomalyToTimeFromPeriapsis(double trueAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter)
Converts the true anomaly to the time of flight from the corresponding periapsis passage in seconds.
|
static double |
convertTrueAnomalyToTimeSincePreviousPeriapsis(double trueAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter)
Converts the true anomaly to the time of flight since the previous periapsis passage in seconds.
|
static double |
convertTrueAnomalyToTimeUntilNextPeriapsis(double trueAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter)
Converts the true anomaly to the time of flight until the next periapsis passage in seconds.
|
static Matrix3By3 |
perifocalToCartesianMatrix(double argumentOfPeriapsis,
double inclination,
double ascendingNodeRightAscension)
Calculates the transformation matrix from the perifocal axes to the inertial axes.
|
static boolean |
tryComputeEccentricity(double radiusOfPeriapsis,
double inverseSemimajorAxis,
double[] eccentricity)
Tries to calculate the eccentricity of the orbit.
|
static boolean |
tryComputeMeanMotion(double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter,
double[] meanMotion)
Tries to calculate the mean motion of the orbit.
|
static boolean |
tryComputePeriod(double inverseSemimajorAxis,
double gravitationalParameter,
double[] period)
Tries to calculate the period of the orbit.
|
static boolean |
tryComputeRadiusOfApoapsis(double radiusOfPeriapsis,
double eccentricity,
double[] radiusOfApoapsis)
Tries to calculate the radius of apoapsis of the orbit.
|
static boolean |
tryComputeRadiusOfPeriapsis(double semilatusRectum,
double eccentricity,
double[] radiusOfPeriapsis)
Tries to calculate the radius of periapsis of the orbit.
|
static boolean |
tryComputeSemilatusRectum(double radiusOfPeriapsis,
double eccentricity,
double[] semilatusRectum)
Tries to calculate the semilatus rectum of the orbit.
|
static boolean |
tryComputeSemimajorAxis(double radiusOfPeriapsis,
double eccentricity,
double[] semimajorAxis)
Tries to calculate the semimajor axis of the orbit.
|
static boolean |
tryComputeTimeOfFlight(double initialTrueAnomaly,
double finalTrueAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter,
double[] timeOfFlight)
Tries to calculate the time of flight between two true anomalies.
|
static boolean |
tryConvertEccentricAnomalyToMeanAnomaly(double eccentricAnomaly,
double eccentricity,
double[] meanAnomaly)
Tries to convert the eccentric anomaly to the mean anomaly.
|
static boolean |
tryConvertEccentricAnomalyToTimeFromPeriapsis(double eccentricAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter,
double[] timeFromPeriapsis)
Tries to convert the eccentric anomaly to the time of flight from the corresponding periapsis passage in seconds.
|
static boolean |
tryConvertEccentricAnomalyToTrueAnomaly(double eccentricAnomaly,
double eccentricity,
double[] trueAnomaly)
Tries to convert the eccentric anomaly to the true anomaly.
|
static boolean |
tryConvertHyperbolicAnomalyToMeanAnomaly(double hyperbolicAnomaly,
double eccentricity,
double[] meanAnomaly)
Tries to convert the hyperbolic anomaly to the mean anomaly.
|
static boolean |
tryConvertHyperbolicAnomalyToTimeFromPeriapsis(double hyperbolicAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter,
double[] timeFromPeriapsis)
Tries to convert the hyperbolic anomaly to the time of flight from the corresponding periapsis passage in seconds.
|
static boolean |
tryConvertHyperbolicAnomalyToTrueAnomaly(double hyperbolicAnomaly,
double eccentricity,
double[] trueAnomaly)
Tries to convert the hyperbolic anomaly to the true anomaly.
|
static boolean |
tryConvertMeanAnomalyToEccentricAnomaly(double meanAnomaly,
double eccentricity,
double[] eccentricAnomaly)
Tries to convert the mean anomaly to the eccentric anomaly.
|
static boolean |
tryConvertMeanAnomalyToHyperbolicAnomaly(double meanAnomaly,
double eccentricity,
double[] hyperbolicAnomaly)
Tries to convert the mean anomaly to the hyperbolic anomaly.
|
static boolean |
tryConvertMeanAnomalyToParabolicAnomaly(double meanAnomaly,
double eccentricity,
double[] parabolicAnomaly)
Tries to convert the mean anomaly to the parabolic anomaly.
|
static boolean |
tryConvertMeanAnomalyToTimeFromPeriapsis(double meanAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter,
double[] timeFromPeriapsis)
Tries to convert the mean anomaly to the time of flight from the corresponding periapsis passage in seconds.
|
static boolean |
tryConvertMeanAnomalyToTimeSincePreviousPeriapsis(double meanAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter,
double[] timeSincePreviousPeriapsis)
Tries to convert the mean anomaly to the time of flight since the previous periapsis passage in seconds.
|
static boolean |
tryConvertMeanAnomalyToTimeUntilNextPeriapsis(double meanAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter,
double[] timeUntilNextPeriapsis)
Tries to convert the mean anomaly to the time of flight until the next periapsis passage in seconds.
|
static boolean |
tryConvertMeanAnomalyToTrueAnomaly(double meanAnomaly,
double eccentricity,
double[] trueAnomaly)
Tries to convert the mean anomaly to the true anomaly.
|
static boolean |
tryConvertParabolicAnomalyToMeanAnomaly(double parabolicAnomaly,
double eccentricity,
double[] meanAnomaly)
Tries to convert the parabolic anomaly to the mean anomaly.
|
static boolean |
tryConvertParabolicAnomalyToTimeFromPeriapsis(double parabolicAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter,
double[] timeFromPeriapsis)
Tries to convert the parabolic anomaly to the time of flight from the corresponding periapsis passage in seconds.
|
static boolean |
tryConvertParabolicAnomalyToTrueAnomaly(double parabolicAnomaly,
double eccentricity,
double[] trueAnomaly)
Tries to convert the parabolic anomaly to the true anomaly.
|
static boolean |
tryConvertTimeFromPeriapsisToEccentricAnomaly(double timeFromPeriapsis,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter,
double[] eccentricAnomaly)
Tries to convert the time from periapsis passage to eccentric anomaly.
|
static boolean |
tryConvertTimeFromPeriapsisToHyperbolicAnomaly(double timeFromPeriapsis,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter,
double[] hyperbolicAnomaly)
Tries to convert the time from periapsis passage to hyperbolic anomaly.
|
static boolean |
tryConvertTimeFromPeriapsisToMeanAnomaly(double timeFromPeriapsis,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter,
double[] meanAnomaly)
Tries to convert the time from periapsis passage to mean anomaly.
|
static boolean |
tryConvertTimeFromPeriapsisToParabolicAnomaly(double timeFromPeriapsis,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter,
double[] parabolicAnomaly)
Tries to convert the time from periapsis passage to parabolic anomaly.
|
static boolean |
tryConvertTimeFromPeriapsisToTrueAnomaly(double timeFromPeriapsis,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter,
double[] trueAnomaly)
Tries to convert the time from periapsis passage to true anomaly.
|
static boolean |
tryConvertTrueAnomalyToEccentricAnomaly(double trueAnomaly,
double eccentricity,
double[] eccentricAnomaly)
Tries to convert the true anomaly to the eccentric anomaly.
|
static boolean |
tryConvertTrueAnomalyToHyperbolicAnomaly(double trueAnomaly,
double eccentricity,
double[] hyperbolicAnomaly)
Tries to convert the true anomaly to the hyperbolic anomaly.
|
static boolean |
tryConvertTrueAnomalyToMeanAnomaly(double trueAnomaly,
double eccentricity,
double[] meanAnomaly)
Tries to convert the true anomaly to the mean anomaly.
|
static boolean |
tryConvertTrueAnomalyToParabolicAnomaly(double trueAnomaly,
double eccentricity,
double[] parabolicAnomaly)
Tries to convert the true anomaly to the parabolic anomaly.
|
static boolean |
tryConvertTrueAnomalyToTimeFromPeriapsis(double trueAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter,
double[] timeFromPeriapsis)
True to convert the true anomaly to the time of flight from the corresponding periapsis passage in seconds.
|
static boolean |
tryConvertTrueAnomalyToTimeSincePreviousPeriapsis(double trueAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter,
double[] timeSincePreviousPeriapsis)
Tries to convert the true anomaly to the time of flight since the previous periapsis passage in seconds.
|
static boolean |
tryConvertTrueAnomalyToTimeUntilNextPeriapsis(double trueAnomaly,
double radiusOfPeriapsis,
double eccentricity,
double gravitationalParameter,
double[] timeUntilNextPeriapsis)
Tries to convert the true anomaly to the time of flight until the next periapsis passage in seconds.
|
@Nonnull public static Matrix3By3 perifocalToCartesianMatrix(double argumentOfPeriapsis, double inclination, double ascendingNodeRightAscension)
argumentOfPeriapsis
- The argument of periapsis (radians).inclination
- The inclination (radians).ascendingNodeRightAscension
- The right ascension of the ascending node (radians).public static boolean tryComputeEccentricity(double radiusOfPeriapsis, double inverseSemimajorAxis, @Nonnull double[] eccentricity)
radiusOfPeriapsis
and inverseSemimajorAxis
must have consistent units.radiusOfPeriapsis
- The radius of periapsis.inverseSemimajorAxis
- The inverse of the semimajor axis.eccentricity
- On input, an array with one element. On return, the array is populated with
the eccentricity of the orbit.false
if radiusOfPeriapsis
is negative or zero; otherwise true
.public static double computeEccentricity(double radiusOfPeriapsis, double inverseSemimajorAxis)
radiusOfPeriapsis
and inverseSemimajorAxis
must have consistent units.radiusOfPeriapsis
- The radius of periapsis.inverseSemimajorAxis
- The inverse of the semimajor axis.ArgumentOutOfRangeException
- Thrown when radiusOfPeriapsis
is negative or zero.public static boolean tryComputeSemilatusRectum(double radiusOfPeriapsis, double eccentricity, @Nonnull double[] semilatusRectum)
The result will be given in the same units as radiusOfPeriapsis
.
radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.semilatusRectum
- On input, an array with one element. On return, the array is populated with
the semilatus rectum of the orbit.false
if eccentricity
is negative or radiusOfPeriapsis
is negative or zero; otherwise true
.public static double computeSemilatusRectum(double radiusOfPeriapsis, double eccentricity)
The result will be given in the same units as radiusOfPeriapsis
.
radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown when eccentricity
is negative or radiusOfPeriapsis
is negative or zero.public static boolean tryComputeSemimajorAxis(double radiusOfPeriapsis, double eccentricity, @Nonnull double[] semimajorAxis)
The result will be given in the same units as radiusOfPeriapsis
.
radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.semimajorAxis
- On input, an array with one element. On return, the array is populated with
the semimajor axis of the orbit.false
if eccentricity
is negative or radiusOfPeriapsis
is negative or zero; otherwise true
.public static double computeSemimajorAxis(double radiusOfPeriapsis, double eccentricity)
The result will be given in the same units as radiusOfPeriapsis
.
radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown when eccentricity
is negative or radiusOfPeriapsis
is negative or zero.public static boolean tryComputeRadiusOfPeriapsis(double semilatusRectum, double eccentricity, @Nonnull double[] radiusOfPeriapsis)
The result will be given in the same units as semilatusRectum
.
semilatusRectum
- The semilatus rectum of the orbit (distance).eccentricity
- The eccentricity of the orbit.radiusOfPeriapsis
- On input, an array with one element. On return, the array is populated with
the radius of periapsis of the orbit.false
if eccentricity
is negative or semilatusRectum
is negative or zero; otherwise true
.public static double computeRadiusOfPeriapsis(double semilatusRectum, double eccentricity)
The result will be given in the same units as semilatusRectum
.
semilatusRectum
- The semilatus rectum of the orbit (distance).eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown when eccentricity
is negative or semilatusRectum
is negative or zero.public static boolean tryComputeRadiusOfApoapsis(double radiusOfPeriapsis, double eccentricity, @Nonnull double[] radiusOfApoapsis)
The result will be given in the same units as radiusOfPeriapsis
.
radiusOfPeriapsis
- The radius of periapsis of the orbit (distance).eccentricity
- The eccentricity of the orbit.radiusOfApoapsis
- On input, an array with one element. On return, the array is populated with
the radius of apoapsis of the orbit.false
if eccentricity
is negative or radiusOfPeriapsis
is negative or zero; otherwise true
.public static double computeRadiusOfApoapsis(double radiusOfPeriapsis, double eccentricity)
The result will be given in the same units as radiusOfPeriapsis
.
radiusOfPeriapsis
- The radius of periapsis of the orbit (distance).eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown when eccentricity
is negative or radiusOfPeriapsis
is negative or zero.public static boolean tryComputePeriod(double inverseSemimajorAxis, double gravitationalParameter, @Nonnull double[] period)
inverseSemimajorAxis
and gravitationalParameter
must have consistent units
and the units of the resulting period will correspond with the units of the input parameters.
inverseSemimajorAxis
- The inverse of the semimajor axis (distance).gravitationalParameter
- The gravitational parameter (distance cubed per time squared).period
- On input, an array with one element. On return, the array is populated with
the period of the orbit.false
if gravitationalParameter
is negative or zero; otherwise true
.public static double computePeriod(double inverseSemimajorAxis, double gravitationalParameter)
inverseSemimajorAxis
and gravitationalParameter
must have consistent units
and the units of the resulting period will correspond with the units of the input parameters.
inverseSemimajorAxis
- The inverse of the semimajor axis (distance).gravitationalParameter
- The gravitational parameter (distance cubed per time squared).ArgumentOutOfRangeException
- Thrown when gravitationalParameter
is negative or zero.public static boolean tryComputeMeanMotion(double radiusOfPeriapsis, double eccentricity, double gravitationalParameter, @Nonnull double[] meanMotion)
radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter.meanMotion
- On input, an array with one element. On return, the array is populated with
the mean motion of the orbit.false
if eccentricity
is negative or radiusOfPeriapsis
or gravitationalParameter
is negative or zero; otherwise true
.public static double computeMeanMotion(double radiusOfPeriapsis, double eccentricity, double gravitationalParameter)
radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter.ArgumentOutOfRangeException
- Thrown when eccentricity
is negative or radiusOfPeriapsis
or gravitationalParameter
is negative or zero.public static boolean tryConvertTrueAnomalyToEccentricAnomaly(double trueAnomaly, double eccentricity, @Nonnull double[] eccentricAnomaly)
trueAnomaly
- The true anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.eccentricAnomaly
- On input, an array with one element. On return, the array is populated with
the eccentric anomaly.false
if eccentricity
is negative or greater than or equal to one (indicating that the orbit is not closed); otherwise true
.public static double convertTrueAnomalyToEccentricAnomaly(double trueAnomaly, double eccentricity)
trueAnomaly
- The true anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown when eccentricity
is greater than or equal to one (indicating that the orbit is not closed), or if it is negative.public static boolean tryConvertEccentricAnomalyToTrueAnomaly(double eccentricAnomaly, double eccentricity, @Nonnull double[] trueAnomaly)
eccentricAnomaly
- The eccentric anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.trueAnomaly
- On input, an array with one element. On return, the array is populated with
the true anomaly.false
if eccentricity
is negative or greater than or equal to one (indicating that the orbit is not closed); otherwise true
.public static double convertEccentricAnomalyToTrueAnomaly(double eccentricAnomaly, double eccentricity)
eccentricAnomaly
- The eccentric anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown when eccentricity
is greater than or equal to one (indicating that the orbit is not closed), or if it is negative.public static boolean tryConvertTrueAnomalyToParabolicAnomaly(double trueAnomaly, double eccentricity, @Nonnull double[] parabolicAnomaly)
trueAnomaly
- The true anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.parabolicAnomaly
- On input, an array with one element. On return, the array is populated with
the parabolic anomaly.false
if eccentricity
is not equal to one (indicating that the orbit is not parabolic)
or trueAnomaly
is less than negative Math.PI
or greater than Math.PI
; otherwise true
.public static double convertTrueAnomalyToParabolicAnomaly(double trueAnomaly, double eccentricity)
trueAnomaly
- The true anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown when eccentricity
is not equal to one (indicating that the orbit is not parabolic), or if it is negative, or trueAnomaly
is less than negative Math.PI
or greater than Math.PI
.public static boolean tryConvertParabolicAnomalyToTrueAnomaly(double parabolicAnomaly, double eccentricity, @Nonnull double[] trueAnomaly)
parabolicAnomaly
- The parabolic anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.trueAnomaly
- On input, an array with one element. On return, the array is populated with
the true anomaly.false
if eccentricity
is not equal to one (indicating that the orbit is not parabolic).public static double convertParabolicAnomalyToTrueAnomaly(double parabolicAnomaly, double eccentricity)
parabolicAnomaly
- The parabolic anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown when eccentricity
is not equal to one (indicating that the orbit is not parabolic), or if it is negative.public static boolean tryConvertTrueAnomalyToHyperbolicAnomaly(double trueAnomaly, double eccentricity, @Nonnull double[] hyperbolicAnomaly)
trueAnomaly
- The true anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.hyperbolicAnomaly
- On input, an array with one element. On return, the array is populated with.
the hyperbolic anomaly.false
if eccentricity
is less than or equal to one (indicating that the orbit is not hyperbolic)
or trueAnomaly
is outside the bounds of the asymptotes of the hyperbola; otherwise true
.public static double convertTrueAnomalyToHyperbolicAnomaly(double trueAnomaly, double eccentricity)
trueAnomaly
- The true anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown when eccentricity
is less than or equal to one (indicating that the orbit is not hyperbolic), or if it is negative, or trueAnomaly
is outside the bounds of the asymptotes of the hyperbola.public static boolean tryConvertHyperbolicAnomalyToTrueAnomaly(double hyperbolicAnomaly, double eccentricity, @Nonnull double[] trueAnomaly)
hyperbolicAnomaly
- The hyperbolic anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.trueAnomaly
- On input, an array with one element. On return, the array is populated with
the true anomaly.false
if eccentricity
is less than or equal to one (indicating that the orbit is not hyperbolic).public static double convertHyperbolicAnomalyToTrueAnomaly(double hyperbolicAnomaly, double eccentricity)
hyperbolicAnomaly
- The hyperbolic anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown when eccentricity
is less than or equal to one (indicating that the orbit is not hyperbolic), or if it is negative.public static boolean tryConvertMeanAnomalyToEccentricAnomaly(double meanAnomaly, double eccentricity, @Nonnull double[] eccentricAnomaly)
meanAnomaly
- The mean anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.eccentricAnomaly
- On input, an array with one element. On return, the array is populated with
the eccentric anomaly.false
if eccentricity
is negative or greater than or equal to one (indicating that the orbit is not closed)
or if the iterative solution to Kepler's equation did not converge; otherwise true
.public static double convertMeanAnomalyToEccentricAnomaly(double meanAnomaly, double eccentricity)
meanAnomaly
- The true anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown when eccentricity
is greater than or equal to one (indicating that the orbit is not closed), or if it is negative.ArithmeticException
- Thrown when the iterative solution to Kepler's equation did not converge.public static boolean tryConvertMeanAnomalyToParabolicAnomaly(double meanAnomaly, double eccentricity, @Nonnull double[] parabolicAnomaly)
meanAnomaly
- The mean anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.parabolicAnomaly
- On input, an array with one element. On return, the array is populated with
the parabolic anomaly.false
if eccentricity
is not equal to one (indicating that the orbit is not parabolic); otherwise true
.public static double convertMeanAnomalyToParabolicAnomaly(double meanAnomaly, double eccentricity)
meanAnomaly
- The true anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown when eccentricity
is not equal to one (indicating that the orbit is not parabolic), or if it is negative.public static boolean tryConvertMeanAnomalyToHyperbolicAnomaly(double meanAnomaly, double eccentricity, @Nonnull double[] hyperbolicAnomaly)
meanAnomaly
- The mean anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.hyperbolicAnomaly
- On input, an array with one element. On return, the array is populated with
the hyperbolic anomaly.false
if eccentricity
is less than or equal to one (indicating that the orbit is not hyperbolic),
or if the iterative solution to Kepler's equation did not converge; otherwise true
.public static double convertMeanAnomalyToHyperbolicAnomaly(double meanAnomaly, double eccentricity)
meanAnomaly
- The true anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown when eccentricity
is less than or equal to one (indicating that the orbit is not hyperbolic), or if it is negative.ArithmeticException
- Thrown when the iterative solution to Kepler's equation did not converge.public static boolean tryConvertEccentricAnomalyToMeanAnomaly(double eccentricAnomaly, double eccentricity, @Nonnull double[] meanAnomaly)
eccentricAnomaly
- The eccentric anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.meanAnomaly
- On input, an array with one element. On return, the array is populated with
the mean anomaly.false
if eccentricity
is negative or greater than or equal to one (indicating that the orbit is not closed); otherwise true
.public static double convertEccentricAnomalyToMeanAnomaly(double eccentricAnomaly, double eccentricity)
eccentricAnomaly
- The eccentric anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown when eccentricity
is greater than or equal to one (indicating that the orbit is not closed), or if it is negative.public static boolean tryConvertParabolicAnomalyToMeanAnomaly(double parabolicAnomaly, double eccentricity, @Nonnull double[] meanAnomaly)
parabolicAnomaly
- The parabolic anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.meanAnomaly
- On input, an array with one element. On return, the array is populated with
the mean anomaly.false
if eccentricity
is not equal to one (indicating that the orbit is not parabolic); otherwise true
.public static double convertParabolicAnomalyToMeanAnomaly(double parabolicAnomaly, double eccentricity)
parabolicAnomaly
- The parabolic anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown when eccentricity
is not equal to one (indicating that the orbit is not parabolic), or if it is negative.public static boolean tryConvertHyperbolicAnomalyToMeanAnomaly(double hyperbolicAnomaly, double eccentricity, @Nonnull double[] meanAnomaly)
hyperbolicAnomaly
- The hyperbolic anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.meanAnomaly
- On input, an array with one element. On return, the array is populated with
the mean anomaly.false
if eccentricity
is less than or equal to one (indicating that the orbit is not hyperbolic); otherwise true
.public static double convertHyperbolicAnomalyToMeanAnomaly(double hyperbolicAnomaly, double eccentricity)
hyperbolicAnomaly
- The hyperbolic anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown when eccentricity
is less than or equal to one (indicating that the orbit is not hyperbolic), or if it is negative.public static boolean tryConvertTrueAnomalyToMeanAnomaly(double trueAnomaly, double eccentricity, @Nonnull double[] meanAnomaly)
trueAnomaly
- The true anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.meanAnomaly
- On input, an array with one element. On return, the array is populated with
the mean anomaly.false
if eccentricity
is negative
or if trueAnomaly
is not within the valid range for the type of orbit; otherwise true
.public static double convertTrueAnomalyToMeanAnomaly(double trueAnomaly, double eccentricity)
trueAnomaly
- The true anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown if eccentricity
is negative
or if trueAnomaly
is not within the valid range for the type of orbit.public static boolean tryConvertMeanAnomalyToTrueAnomaly(double meanAnomaly, double eccentricity, @Nonnull double[] trueAnomaly)
meanAnomaly
- The mean anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.trueAnomaly
- On input, an array with one element. On return, the array is populated with
the true anomaly.false
if eccentricity
is negative
or the iterative solution to Kepler's equation did not converge for elliptic or hyperbolic orbits; otherwise true
.public static double convertMeanAnomalyToTrueAnomaly(double meanAnomaly, double eccentricity)
meanAnomaly
- The true anomaly to convert (radians).eccentricity
- The eccentricity of the orbit.ArgumentOutOfRangeException
- Thrown when eccentricity
is negative.ArithmeticException
- Thrown when the iterative solution to Kepler's equation did not converge for elliptic or hyperbolic orbits.public static boolean tryConvertEccentricAnomalyToTimeFromPeriapsis(double eccentricAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter, @Nonnull double[] timeFromPeriapsis)
eccentricAnomaly
- The eccentric anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.timeFromPeriapsis
- On input, an array with one element. On return, the array is populated with
the time since the last periapsis passage.false
if eccentricity
is negative or greater than or equal to one
or radiusOfPeriapsis
or gravitationalParameter
is negative or zero; otherwise true
.public static double convertEccentricAnomalyToTimeFromPeriapsis(double eccentricAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter)
eccentricAnomaly
- The eccentric anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.ArgumentOutOfRangeException
- Thrown when eccentricity
is greater than or equal to one (indicating that the orbit is not closed), or if it is negative, or radiusOfPeriapsis
or gravitationalParameter
is negative or zero.public static boolean tryConvertParabolicAnomalyToTimeFromPeriapsis(double parabolicAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter, @Nonnull double[] timeFromPeriapsis)
parabolicAnomaly
- The parabolic anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.timeFromPeriapsis
- On input, an array with one element. On return, the array is populated with
the time since the last periapsis passage.false
if eccentricity
is not equal to one (indicating that the orbit is not parabolic)
or radiusOfPeriapsis
or gravitationalParameter
is negative or zero; otherwise true
.public static double convertParabolicAnomalyToTimeFromPeriapsis(double parabolicAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter)
parabolicAnomaly
- The parabolic anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.ArgumentOutOfRangeException
- Thrown when eccentricity
is not equal to one (indicating that the orbit is not parabolic), or if it is negative, or radiusOfPeriapsis
or gravitationalParameter
is negative or zero.public static boolean tryConvertHyperbolicAnomalyToTimeFromPeriapsis(double hyperbolicAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter, @Nonnull double[] timeFromPeriapsis)
hyperbolicAnomaly
- The hyperbolic anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.timeFromPeriapsis
- On input, an array with one element. On return, the array is populated with
the time since the last periapsis passage.false
if eccentricity
is less than or equal to one (indicating that the orbit is not hyperbolic)
or radiusOfPeriapsis
or gravitationalParameter
is negative or zero; otherwise true
.public static double convertHyperbolicAnomalyToTimeFromPeriapsis(double hyperbolicAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter)
hyperbolicAnomaly
- The hyperbolic anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.ArgumentOutOfRangeException
- Thrown when eccentricity
is less than or equal to one (indicating that the orbit is not hyperbolic), or if it is negative, or radiusOfPeriapsis
or gravitationalParameter
is negative or zero.public static boolean tryConvertMeanAnomalyToTimeUntilNextPeriapsis(double meanAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter, @Nonnull double[] timeUntilNextPeriapsis)
meanAnomaly
- The mean anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.timeUntilNextPeriapsis
- On input, an array with one element. On return, the array is populated with
the time until the next periapsis passage.false
if eccentricity
is negative
or radiusOfPeriapsis
or gravitationalParameter
is negative or zero
or if the orbit is open (parabolic or hyperbolic) and meanAnomaly
is positive or zero; otherwise true
.public static double convertMeanAnomalyToTimeUntilNextPeriapsis(double meanAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter)
meanAnomaly
- The mean anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.ArgumentOutOfRangeException
- Thrown when eccentricity
is negative or radiusOfPeriapsis
or gravitationalParameter
is negative or zero
or if the orbit is open (parabolic or hyperbolic) and meanAnomaly
is positive or zero.public static boolean tryConvertMeanAnomalyToTimeFromPeriapsis(double meanAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter, @Nonnull double[] timeFromPeriapsis)
meanAnomaly
- The mean anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.timeFromPeriapsis
- On input, an array with one element. On return, the array is populated with
the time since the last periapsis passage.false
if eccentricity
is negative or radiusOfPeriapsis
or gravitationalParameter
is negative or zero; otherwise true
.public static double convertMeanAnomalyToTimeFromPeriapsis(double meanAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter)
meanAnomaly
- The mean anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.ArgumentOutOfRangeException
- Thrown when eccentricity
is negative or radiusOfPeriapsis
or gravitationalParameter
is negative or zero.public static boolean tryConvertMeanAnomalyToTimeSincePreviousPeriapsis(double meanAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter, @Nonnull double[] timeSincePreviousPeriapsis)
meanAnomaly
- The mean anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.timeSincePreviousPeriapsis
- On input, an array with one element. On return, the array is populated with
the time since the previous periapsis passage.false
if eccentricity
is negative
or radiusOfPeriapsis
or gravitationalParameter
is negative or zero
or if the orbit is open (parabolic or hyperbolic) and meanAnomaly
is negative or zero; otherwise true
.public static double convertMeanAnomalyToTimeSincePreviousPeriapsis(double meanAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter)
meanAnomaly
- The mean anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.ArgumentOutOfRangeException
- Thrown when eccentricity
is negative or radiusOfPeriapsis
or gravitationalParameter
is negative or zero
or if the orbit is open (parabolic or hyperbolic) and meanAnomaly
is negative or zero.public static boolean tryConvertTrueAnomalyToTimeUntilNextPeriapsis(double trueAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter, @Nonnull double[] timeUntilNextPeriapsis)
trueAnomaly
- The true anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.timeUntilNextPeriapsis
- On input, an array with one element. On return, the array is populated with
the time until the next periapsis passage.false
if eccentricity
is negative
or radiusOfPeriapsis
or gravitationalParameter
is negative or zero
or if the orbit is open (parabolic or hyperbolic) and trueAnomaly
is positive or zero
or if trueAnomaly
is not within the valid range for the type of orbit; otherwise true
.public static double convertTrueAnomalyToTimeUntilNextPeriapsis(double trueAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter)
trueAnomaly
- The true anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.ArgumentOutOfRangeException
- Thrown when eccentricity
is negative or radiusOfPeriapsis
or gravitationalParameter
is negative or zero
or if the orbit is open (parabolic or hyperbolic) and trueAnomaly
is positive or zero
or if trueAnomaly
is not within the valid range for the type of orbit; otherwise true
.public static boolean tryConvertTrueAnomalyToTimeFromPeriapsis(double trueAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter, @Nonnull double[] timeFromPeriapsis)
trueAnomaly
- The true anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.timeFromPeriapsis
- On input, an array with one element. On return, the array is populated with
the time since the last periapsis passage.false
if eccentricity
is negative
or radiusOfPeriapsis
or gravitationalParameter
is negative or zero
or if trueAnomaly
is not within the valid range for the type of orbit; otherwise true
.public static double convertTrueAnomalyToTimeFromPeriapsis(double trueAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter)
trueAnomaly
- The true anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.ArgumentOutOfRangeException
- Thrown when eccentricity
is negative or radiusOfPeriapsis
or gravitationalParameter
is negative or zero
or if trueAnomaly
is not within the valid range for the type of orbit; otherwise true
.public static boolean tryConvertTrueAnomalyToTimeSincePreviousPeriapsis(double trueAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter, @Nonnull double[] timeSincePreviousPeriapsis)
trueAnomaly
- The true anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.timeSincePreviousPeriapsis
- On input, an array with one element. On return, the array is populated with
the time since the previous periapsis passage.false
if eccentricity
is negative
or radiusOfPeriapsis
or gravitationalParameter
is negative or zero
or if the orbit is open (parabolic or hyperbolic) and trueAnomaly
is negative or zero
or if trueAnomaly
is not within the valid range for the type of orbit; otherwise true
.public static double convertTrueAnomalyToTimeSincePreviousPeriapsis(double trueAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter)
trueAnomaly
- The true anomaly (radians).radiusOfPeriapsis
- The radius of periapsis.eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter of the central body being orbited.ArgumentOutOfRangeException
- Thrown when eccentricity
is negative or radiusOfPeriapsis
or gravitationalParameter
is negative or zero
or if the orbit is open (parabolic or hyperbolic) and trueAnomaly
is negative or zero
or if trueAnomaly
is not within the valid range for the type of orbit; otherwise true
.public static boolean tryConvertTimeFromPeriapsisToMeanAnomaly(double timeFromPeriapsis, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter, @Nonnull double[] meanAnomaly)
timeFromPeriapsis
- The time from periapsis passage (time).radiusOfPeriapsis
- The radius of periapsis (distance).eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter (distance cubed per time squared).meanAnomaly
- On input, an array with one element. On return, the array is populated with
the mean anomaly (radians).false
if eccentricity
is negative
or radiusOfPeriapsis
or gravitationalParameter
is negative or zero; otherwise true
.public static double convertTimeFromPeriapsisToMeanAnomaly(double timeFromPeriapsis, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter)
timeFromPeriapsis
- The time from periapsis passage (time).radiusOfPeriapsis
- The radius of periapsis (distance).eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter (distance cubed per time squared).ArgumentOutOfRangeException
- Thrown when eccentricity
is negative or radiusOfPeriapsis
or gravitationalParameter
is negative or zero; otherwise true
.public static boolean tryConvertTimeFromPeriapsisToTrueAnomaly(double timeFromPeriapsis, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter, @Nonnull double[] trueAnomaly)
timeFromPeriapsis
- The time from periapsis passage (time).radiusOfPeriapsis
- The radius of periapsis (distance).eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter (distance cubed per time squared).trueAnomaly
- On input, an array with one element. On return, the array is populated with
the true anomaly.false
if eccentricity
is negative
or radiusOfPeriapsis
or gravitationalParameter
is negative or zero
or the iterative solution to Kepler's equation did not converge for elliptic or hyperbolic orbits; otherwise true
.public static double convertTimeFromPeriapsisToTrueAnomaly(double timeFromPeriapsis, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter)
timeFromPeriapsis
- The time from periapsis passage (time).radiusOfPeriapsis
- The radius of periapsis (distance).eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter (distance cubed per time squared).ArgumentOutOfRangeException
- Thrown when eccentricity
is negative or radiusOfPeriapsis
or gravitationalParameter
is negative or zero.ArithmeticException
- Thrown when the iterative solution to Kepler's equation did not converge for elliptic or hyperbolic orbits.public static boolean tryConvertTimeFromPeriapsisToEccentricAnomaly(double timeFromPeriapsis, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter, @Nonnull double[] eccentricAnomaly)
timeFromPeriapsis
- The time from periapsis passage (time).radiusOfPeriapsis
- The radius of periapsis (distance).eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter (distance cubed per time squared).eccentricAnomaly
- On input, an array with one element. On return, the array is populated with
the eccentric anomaly.false
if eccentricity
is negative or greater than or equal to one (indicating that the orbit is not closed)
or radiusOfPeriapsis
or gravitationalParameter
is negative or zero
or the iterative solution to Kepler's equation did not converge; otherwise true
.public static double convertTimeFromPeriapsisToEccentricAnomaly(double timeFromPeriapsis, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter)
timeFromPeriapsis
- The time from periapsis passage (time).radiusOfPeriapsis
- The radius of periapsis (distance).eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter (distance cubed per time squared).ArgumentOutOfRangeException
- Thrown when eccentricity
is greater than or equal to one (indicating that the orbit is not closed), or if it is negative, or radiusOfPeriapsis
or gravitationalParameter
is negative or zero.ArithmeticException
- Thrown when the iterative solution to Kepler's equation did not converge for elliptic or hyperbolic orbits.public static boolean tryConvertTimeFromPeriapsisToParabolicAnomaly(double timeFromPeriapsis, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter, @Nonnull double[] parabolicAnomaly)
timeFromPeriapsis
- The time from periapsis passage (time).radiusOfPeriapsis
- The radius of periapsis (distance).eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter (distance cubed per time squared).parabolicAnomaly
- On input, an array with one element. On return, the array is populated with
the parabolic anomaly (radians).false
if eccentricity
is not equal to one (indicating that the orbit is not parabolic)
or radiusOfPeriapsis
or gravitationalParameter
is negative or zero; otherwise true
.public static double convertTimeFromPeriapsisToParabolicAnomaly(double timeFromPeriapsis, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter)
timeFromPeriapsis
- The time from periapsis passage (time).radiusOfPeriapsis
- The radius of periapsis (distance).eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter (distance cubed per time squared).ArgumentOutOfRangeException
- Thrown when eccentricity
is not equal to one (indicating that the orbit is not parabolic), or if it is negative, or radiusOfPeriapsis
or gravitationalParameter
is negative or zero.public static boolean tryConvertTimeFromPeriapsisToHyperbolicAnomaly(double timeFromPeriapsis, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter, @Nonnull double[] hyperbolicAnomaly)
timeFromPeriapsis
- The time from periapsis passage (time).radiusOfPeriapsis
- The radius of periapsis (distance).eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter (distance cubed per time squared).hyperbolicAnomaly
- On input, an array with one element. On return, the array is populated with
the hyperbolic anomaly (radians).false
if eccentricity
is less than or equal to one (indicating that the orbit is not hyperbolic)
or radiusOfPeriapsis
or gravitationalParameter
is negative or zero; otherwise true
.public static double convertTimeFromPeriapsisToHyperbolicAnomaly(double timeFromPeriapsis, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter)
timeFromPeriapsis
- The time from periapsis passage (time).radiusOfPeriapsis
- The radius of periapsis (distance).eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter (distance cubed per time squared).ArgumentOutOfRangeException
- Thrown when eccentricity
is less than or equal to one (indicating that the orbit is not hyperbolic), or if it is negative, or radiusOfPeriapsis
or gravitationalParameter
is negative or zero.ArithmeticException
- Thrown when the iterative solution to Kepler's equation did not converge.public static boolean tryComputeTimeOfFlight(double initialTrueAnomaly, double finalTrueAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter, @Nonnull double[] timeOfFlight)
The sign of the true anomaly indicates whether the position in orbit was measured before or after crossing periapsis.
initialTrueAnomaly
- The initial true anomaly (radians).finalTrueAnomaly
- The final true anomaly (radians).radiusOfPeriapsis
- The radius of periapsis (distance).eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter (distance cubed per time squared).timeOfFlight
- On input, an array with one element. On return, the array is populated with
the time of flight (time).true
if the time of flight could be calculated with the given elements; otherwise false
.public static double computeTimeOfFlight(double initialTrueAnomaly, double finalTrueAnomaly, double radiusOfPeriapsis, double eccentricity, double gravitationalParameter)
The sign of the true anomaly indicates whether the position in orbit was measured before or after crossing periapsis.
initialTrueAnomaly
- The initial true anomaly (radians).finalTrueAnomaly
- The final true anomaly (radians).radiusOfPeriapsis
- The radius of periapsis (distance).eccentricity
- The eccentricity of the orbit.gravitationalParameter
- The gravitational parameter (distance cubed per time squared).ArgumentOutOfRangeException
- Thrown when eccentricity
is negative or radiusOfPeriapsis
or gravitationalParameter
is negative or zero
or if initialTrueAnomaly
or initialTrueAnomaly
are not within the valid range for the type of orbit; otherwise true
.