Jump to content

ManEatingApe

Members
  • Posts

    520
  • Joined

  • Last visited

Community Answers

  1. ManEatingApe's post in Ejection angles for direct transfer, help me understand was marked as the answer   
    Your intuition is correct - the faster you burn, the less that Kerbin warps your orbit as you escape, so the closer your angle can be to prograde.

    This is why Dres's transfer angle is closer to prograde than Duna's transfer angle. The ejection angle is not about giving you time to make the burn; all maneuver node burns are assumed to be instantaneous. Instead it measures how much Kerbin bends your trajectory.

    In real life, escape trajectories are mathematically hyperbolae. (NOTE: Technically also parabolas and in KSP there is a big exception...but more on that in a bit).

    The eccentricity of a hyperbola is given by: e = vp2 / (rp × μ) - 1
    Where vp is your velocity at periapsis after your transfer burn, rp is the radius at which you made the burn and μ = GM
    is the standard gravitational parameter for Kerbin.
    The angle of the tangent to a hyperbola at infinity is related to sin-1(1 / e) and the angle relative to prograde is π/2 + sin-1(1 / e).
    Now we can see that the faster we go, the greater the eccentricity and the closer the angle from prograde becomes to 90 degrees.

    For example a parabola (barely escaping, eccentricity = 1) would have a angle to prograde of π/2 + sin-1(1) = π = 180 degrees
    If we could go infinitely fast the angle to prograde would be π/2 + sin-1(1 / ∞ ) = π/2 + sin-1(0) = π/2 = 90 degrees

    To see this visually here are some graphs of hyperbolae of increasing eccentricity showing the tangent line at infinity.






    In KSP however there is a big difference from reality. KSP uses patched conics, where beyond a certain radius the planet's gravity does not affect you at all. This is the planet's sphere of influence (SOI). This makes all orbits instances of the 2-body problem, which is easier to reason about mathematically. It also means that the formula for the tangent that I used earlier is wrong when applied to KSP.

    Instead of finding the tangent at infinity we need to find the tangent at the SOI radius rs (for Kerbin 84,159,286 meters). This can be calculated by:
    Semi-major axis is: a = rp / (1 - e)
    Cosine of the eccentric anomaly (E) is: cos(E) = (a - rs) / (e × a)
    Slope of the tangent at radius rs is: m = cos(E) × sqrt[ (1 - e2) / (1 - cos(E)2) ].
    Angle from prograde = 2π - tan-1(m)

    Interestingly, if you examine the source code for Alex Moon's solver, it approximates the tangent using the formula for the true anomaly (θ) at a given radius:
    rs = a × (1 - e2) / (1 + e × cos(θ))
    θ = cos-1[ (a × (1 - e2) - rs) / (e × rs) ]
    This is probably close enough.

    This MIT lectures notes has very nice details on interplanetary transfer orbits. The Wikipedia articles on eccentricity, hyperbolic trajectory, Kepler's equation, true anomaly and eccentric anomaly are also great reading.

    What's also fun is that KSP allows you to escape from a planet with an orbit that is mathematically an ellipse, by "chopping" off the top of the ellipse once you go out of SOI. In the Jool system, it's possible to transfer from Tylo to Laythe with such an orbit.
     
×
×
  • Create New...