Beispiel #1
0
 public static double semimajorAxis(Orbit orbit)
 {
     throw new System.NotImplementedException();
 }
Beispiel #2
0
 public static double timeFromPeriapsis(Orbit orbit)
 {
     throw new System.NotImplementedException();
 }
Beispiel #3
0
        public static double timeFromPeriapsis(Orbit orbit)
        {
            double ea = eccentricAnomaly(orbit);

            return Math.Pow(orbit.semimajorAxis, 1.5) / orbit.mainBody.gravParameter.sqrt() * (ea - orbit.eccentricity * Math.Sin(ea));
        }
Beispiel #4
0
 private static double eccentricAnomaly(Orbit orbit)
 {
     return 2 * Math.Atan(((1 - orbit.eccentricity) / (1 + orbit.eccentricity)).sqrt() * Math.Tan(orbit.trueAnomaly / 2));
 }
Beispiel #5
0
 public static double semimajorAxis(Orbit orbit)
 {
     return orbit.parameter / (1 - orbit.eccentricity.sqr());
 }