Position velocity to heliocentirc osculating elements palPv2el
-1 = illegal PMASS
-2 = illegal JFORMR
-3 = position/velocity out of range
The PV 6-vector is with respect to the mean equator and equinox of epoch J2000. The orbital elements produced are with respect to the J2000 ecliptic and mean equinox.
The mass, PMASS, is important only for the larger planets. For most purposes (e.g. asteroids) use 0D0. Values less than zero are illegal.
Three different element-format options are supported:
Option JFORM=1, suitable for the major planets:
EPOCH = epoch of elements (TT MJD) ORBINC = inclination i (radians) ANODE = longitude of the ascending node, big omega (radians) PERIH = longitude of perihelion, curly pi (radians) AORQ = mean distance, a (AU) E = eccentricity, e AORL = mean longitude L (radians) DM = daily motion (radians)
Option JFORM=2, suitable for minor planets:
EPOCH = epoch of elements (TT MJD) ORBINC = inclination i (radians) ANODE = longitude of the ascending node, big omega (radians) PERIH = argument of perihelion, little omega (radians) AORQ = mean distance, a (AU) E = eccentricity, e AORL = mean anomaly M (radians)
Option JFORM=3, suitable for comets:
EPOCH = epoch of perihelion (TT MJD) ORBINC = inclination i (radians) ANODE = longitude of the ascending node, big omega (radians) PERIH = argument of perihelion, little omega (radians) AORQ = perihelion distance, q (AU) E = eccentricity, e
It may not be possible to generate elements in the form requested through JFORMR. The caller is notified of the form of elements actually returned by means of the JFORM argument:
JFORMR JFORM meaning
1 1 OK - elements are in the requested format 1 2 never happens 1 3 orbit not elliptical
2 1 never happens 2 2 OK - elements are in the requested format 2 3 orbit not elliptical
3 1 never happens 3 2 never happens 3 3 OK - elements are in the requested format
The arguments returned for each value of JFORM (cf Note 5: JFORM may not be the same as JFORMR) are as follows:
JFORM 1 2 3 EPOCH t0 t0 T ORBINC i i i ANODE Omega Omega Omega PERIH curly pi omega omega AORQ a a q E e e e AORL L M - DM n - -
where:
t0 is the epoch of the elements (MJD, TT) T " epoch of perihelion (MJD, TT) i " inclination (radians)
Omega " longitude of the ascending node (radians) curly pi " longitude of perihelion (radians) omega
" argument of perihelion (radians) a " mean distance (AU) q " perihelion distance (AU) e "
eccentricity L " longitude (radians, 0-2pi) M " mean anomaly (radians, 0-2pi) n " daily motion
(radians)
means no value is set
At very small inclinations, the longitude of the ascending node ANODE becomes indeterminate and under some circumstances may be set arbitrarily to zero. Similarly, if the orbit is close to circular, the true anomaly becomes indeterminate and under some circumstances may be set arbitrarily to zero. In such cases, the other elements are automatically adjusted to compensate, and so the elements remain a valid description of the orbit.
The osculating epoch for the returned elements is the argument DATE.
Reference: Sterne, Theodore E., " An Introduction to Celestial Mechanics" , Interscience Publishers,
1960