Exemple #1
0
 /// <summary>
 /// Construct kepler orbit from base parameters
 /// </summary>
 /// <param name="parent">Parent body</param>
 /// <param name="a">semi-major axis length</param>
 /// <param name="e">eccentricity</param>
 /// <param name="ma">mean anomaly</param>
 /// <param name="i">inclination</param>
 /// <param name="w">perifocus</param>
 /// <param name="omega">ascending node</param>
 public KeplerOrbit(KeplerBody parent, double a, double e, double ma, double i, double w, double omega)
 {
     this.parent          = parent;
     this.semiMajorLength = a;
     this.eccentricity    = e;
     this.meanAnomaly     = ma;
     this.inclination     = i;
     this.perifocus       = w;
     this.ascendingNode   = omega;
 }
Exemple #2
0
 /// <summary>
 /// Construct kepler orbit from orbital parameters object
 /// </summary>
 /// <param name="parent"></param>
 /// <param name="parameters"></param>
 public KeplerOrbit(KeplerBody parent, KeplerOrbitalParameters parameters) : this(
         parent,
         parameters.semiMajorLength,
         parameters.eccentricity,
         parameters.meanAnomaly,
         parameters.inclinationInRad,
         parameters.perifocusInRad,
         parameters.ascendingNodeInRad
         )
 {
 }