Help Shape the Future of Space Exploration

Join The Planetary Society Now  arrow.png

Join our eNewsletter for updates & action alerts

    Please leave this field empty

Headshot of Emily Lakdawalla

Figuring out orbital positions from orbital elements

Posted by Emily Lakdawalla

16-02-2012 17:03 CST

Topics: explaining science

A few times a year I find myself confronting a table full of numbers describing the orbits of things in the solar system, and cursing at myself because I've forgotten, again, what all these numbers mean and how to manipulate them to get the particular numbers I want. In particular, despite the fact that determining perihelion and aphelion distances from semimajor axis length and eccentricity could hardly be easier, I still always draw a blank. So I'm sitting down now to write a blog entry that will tell me what these numbers mean and how to use them to get the numbers I want! I'm posting it because I figure it'll be useful for some of you, too. In the following post, I'll show you why I was interested in getting these numbers today.

Here we go. The shape of an elliptical orbit is described by two parameters:

  • semi-major axis, a: one half of the ellipse's long axis
  • eccentricity, e: 0 for circular orbits; between 0 and 1 for ellipses
A Keplerian ellipse
A Keplerian ellipse

To compute other numbers describing the shape of the orbit, here's what you do:

  • Periapsis distance = a(1-e)
  • Apoapsis distance = a(1+e)
  • Orbital period = 2π√(a3/GM)
  • Orbital period (solar orbit, in years, with a in AU) = a1.5
    (and recall that 1 AU = 149.60×106 km)

To figure out where an object currently is in space requires a few more pieces of information, including inclination, longitude of ascending node, et cetera.

Keplerian orbital elements

Lasunncty via Wikimedia Commons

Keplerian orbital elements
In this diagram, an orbital plane (yellow) intersects a reference plane (gray). For objects in solar orbit, the reference plane is usually the plane of the ecliptic. The intersection is called the line of nodes, as it connects the center of mass with the ascending and descending nodes. The Vernal Point, (♈) is the heliocentric longitude of 0, the angular position of Earth's northern vernal equinox. Heliocentric longitudes count up in a prograde direction (counterclockwise, when viewed from the north side of the ecliptic plane).

But because of the particular way in which orbital parameters are usually reported, it's actually quite difficult to use these elements to determine a body's current position in space in a way that makes intuitive geometrical sense to me. (I'm a geologist, dangit, not an orbital mechanic!) It's much faster and easier to make JPL's HORIZONS system crunch the numbers. (It makes me feel slightly better that when I asked this question on Twitter, all three Kuiper belt astronomers who follow me said they use HORIZONS too.) You can use HORIZONS via a telnet or email interface but if you don't have too many things to calculate it's easiest just to use the web interface. So:

  • Go to
  • Change the Target Body to the one you're interested in (click "change" and search on the name or number or provisional designation)
  • Change Observer Location to "@sun"
  • Go to Table Settings and check "Helio eclip. lon & lat" (or set the list to "18,20" to get heliocentric lat/lon and range)
  • Click Generate Ephemeris and look for "hEcl-Lon" and "hEcl-Lat," which are in degrees, and "delta," which is the range in AU.

Note: It defaults to a one-month time span with a time step of one day, so the output table will have about thirty entries in it, starting today. The time span permits you to choose a wide range of dates (for most Kuiper belt objects, I find it to cover 1600 to 2200), and the time step chooser permits you to pick calendar years and calendar months as well as increments of days, hours, minutes, or seconds.

HORIZONS can also be used to find the distance between Earth and any of these objects, too, obviously; and you can have it spit the results directly to a text file, which is very handy!

The JPL HORIZONS web interface
The JPL HORIZONS web interface
See other posts from February 2012


Or read more blog entries about: explaining science


David Sims: 01/28/2013 12:06 CST

Aspiring astronomers, even amateurs, should know how to reduce orbital elements and a time to a rectangular position vector in heliocentric ecliptic coordinates. And they should know how for objects in both elliptical and hyperbolic orbits.

David Sims: 01/28/2013 12:13 CST

HYPERBOLIC ORBITS. Let's say you want to find the heliocentric position and the sun-relative velocity of a comet in a hyperbolic orbit. The Keplerian orbital elements for a hyperbolic orbit. [ a, e, i, Ω, ω, T ] @ time = t Notes: a1 Sun's gravitational parameter, GM๏. GM๏ = 1.32712440018e20 m³ sec⁻² Conversion between astronomical units and meters. 1 AU = 1.49597870691e11 meters Hyperbolic mean motion, m, of the comet in radians per day. m = (86400 sec/day) √[GM๏/(−a)³] Choose time of observation, t, and convert it to Julian Date. (For example, 1 January 2014 at 12h GMT is JD 2456659.0) Hyperbolic mean anomaly, M, of the comet at time t. M = m (t−T) Eccentric anomaly, u, of the comet. u₀ = 0 Repeat over index j f₀ = e sinh u(j) − u(j) − M f₁ = e cosh u(j) − 1 f₂ = e sinh u(j) f₃ = e cosh u(j) d₁ = −f₀ / f₁ d₂ = −f₀ / [ f₁ + ½ d₁ f₂ ] d₃ = −f₀ / [ f₁ + ½ d₁ f₂ + ⅙ d₂² f₃ ] u(j+1) = u(j) + d₃ Until |u(j+1)−u(j)| < 1e-12 u = u(j+1) True anomaly, θ, of the comet. θ' = arccos { (e − cosh u) / (e cosh u − 1) } if u>0 then θ = θ' if u=0 then θ = 0 if u0 and y>0 then Q=0 if x>0 and y0 then Q=π λ' = arctan(y/x) + Q Heliocentric longitude, λ, in degrees. λ = (180/π) λ' Heliocentric latitude, β', in radians. β' = arcsin(z/r) Heliocentric latitude, β, in degrees. β = (180/π) β' The sun-relative velocity of a hyperbolic comet in ecliptic coordinates. Canonical velocity vector of the comet. Vx''' = −(a/r) √[GM๏/(−a)] sinh u Vy''' = +(a/r) √[GM๏/(−a)] √(e²−1) cosh u Vz''' = 0 Rotate the canonical velocity by the argument of the perihelion. Vx'' = Vx''' cos ω − Vy''' sin ω Vy'' = Vx''' sin ω + Vy''' cos ω Vz'' = Vz''' Rotate the double-primed vector by the inclination. Vx' = Vx'' Vy' = Vy'' cos i Vz' = Vy'' sin i Rotate the single-primed vector by the longitude of ascending node to get the sun-relative velocity of the comet in ecliptic coordinates. Vx = Vx' cos Ω − Vy' sin Ω Vy = Vx' sin Ω + Vy' cos Ω Vz = Vz' The state vector of the comet, in heliocentric ecliptic coordinates, at time t. [ x, y, z, Vx, Vy, Vz ]

David Sims: 01/28/2013 12:18 CST

What a mess. I see we have a formatting problem here. Rather than I repeat that mess for elliptical orbits, I'll use a link.

David Sims: 01/28/2013 12:18 CST

David Sims: 01/28/2013 12:29 CST

Calculator program written for the Casio fx-9860gii, fx-9750gii, or Prizm. User inputs calendar date and time (GMT), and the Keplerian elements of an object in orbit around the sun: semimajor axis, eccentricity, inclination to ecliptic, longitude of ascending node, argument of perihelion, and Julian Date of perihelion passage. Output is heliocentric distance (AU), geocentric distance (AU), geocentric right ascension (hours), geocentric declination (degrees). The object's orbit can be either hyperbolic or elliptical.

Anonymous: 01/28/2013 12:29 CST

Leave a Comment:

You must be logged in to submit a comment. Log in now.
Facebook Twitter Email RSS AddThis

Blog Search

Planetary Defense

An asteroid or comet headed for Earth is the only large-scale natural disaster we can prevent. Working together to fund our Shoemaker NEO Grants for astronomers, we can help save the world.


Featured Images

SpaceX CRS-8 landed booster
SES-10 static test fire
More Images

Featured Video

Class 9: Saturn, Uranus, and Neptune

Watch Now

Space in Images

Pretty pictures and
awe-inspiring science.

See More

Join The Planetary Society

Let’s explore the cosmos together!

Become a Member

Connect With Us

Facebook, Twitter, YouTube and more…
Continue the conversation with our online community!