Exemplo n.º 1
0
        public double SynodicPeriod(KSPOrbitModule.IOrbit other)
        {
            int sign = (Vector3d.Dot(OrbitNormal, other.OrbitNormal) > 0 ? 1 : -1); //detect relative retrograde motion

            return(Math.Abs(1.0 /
                            (1.0 / Period - sign * 1.0 / other.Period))); //period after which the phase angle repeats
        }
Exemplo n.º 2
0
 public double TimeOfDescendingNode(KSPOrbitModule.IOrbit b, double ut) =>
 TimeOfTrueAnomaly(DescendingNodeTrueAnomaly(b), ut);
Exemplo n.º 3
0
 public double DescendingNodeTrueAnomaly(KSPOrbitModule.IOrbit b) =>
 DirectBindingMath.ClampRadians2Pi(AscendingNodeTrueAnomaly(b) + Math.PI);
Exemplo n.º 4
0
        public double AscendingNodeTrueAnomaly(KSPOrbitModule.IOrbit b)
        {
            Vector3d vectorToAn = Vector3d.Cross(OrbitNormal, b.OrbitNormal);

            return(TrueAnomalyFromVector(vectorToAn));
        }