Class Anomalies

java.lang.Object
gaiasky.util.elements.Anomalies

public class Anomalies extends Object
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final double
    The Constant TWO_PI.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static final double
    mean2ecc(KeplerSolver kepler, double mA, double ecc)
    /** Compute eccentric anomaly from eccentricity and mean anomaly (solving Kepler Equation).
    static final double
    reduce(double x)
    Reduce the given angle to the interval [0 2pi[.
    static final double
    true2ecc(double v, double ecc)
    Compute eccentric anomaly from eccentricity and true anomaly.
    static final double
    true2eccConstrained(double v, double ecc)
    Compute eccentric anomaly from eccentricity and true anomaly which is assumed to be between 0 and 2pi.
    Note that, in this version, no consistency checks are performed on the input.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

  • Constructor Details

    • Anomalies

      public Anomalies()
  • Method Details

    • reduce

      public static final double reduce(double x)
      Reduce the given angle to the interval [0 2pi[.
      Parameters:
      x - Angle (units: rad).
      Returns:
      the angle in the range of 0 through 2pi.
    • true2ecc

      public static final double true2ecc(double v, double ecc)
      Compute eccentric anomaly from eccentricity and true anomaly.
      Parameters:
      v - eccentric anomaly.
      ecc - eccentricity.
      Returns:
      the eccentric anomaly.
      Throws:
      IllegalArgumentException - if ecc is not in the interval [0 1[.
    • true2eccConstrained

      public static final double true2eccConstrained(double v, double ecc)
      Compute eccentric anomaly from eccentricity and true anomaly which is assumed to be between 0 and 2pi.
      Note that, in this version, no consistency checks are performed on the input.
      Parameters:
      v - eccentric anomaly.
      ecc - eccentricity.
      Returns:
      the eccentric anomaly in the range of 0 through 2pi.
    • mean2ecc

      public static final double mean2ecc(KeplerSolver kepler, double mA, double ecc)
      /** Compute eccentric anomaly from eccentricity and mean anomaly (solving Kepler Equation). It will use the values for error tolerance and number of iterations currently set in the kepler object.
      Parameters:
      kepler - Solver.
      mA - Mean anomaly.
      ecc - eccentricity.
      Returns:
      the eccentric anomaly.
      Throws:
      IllegalArgumentException - if ecc is not in the interval [0 1[.