[Previous]
[Next]
NAME:
KeplerOrbit
PURPOSE:
Calculate positions and velocities for a simple Kepler orbit
(of body m2 relative to body m1)
CATEGORY:
smei/gen/idl/ephem
CALLING SEQUENCE:
Out = KeplerOrbit(T, elements=OrbitElements)
INPUTS:
T array; type: standard time structure
times (UT)
elements=OrbitElements
array[4]; type: float
OrbitElement[0] Semi-major axis
OrbitElement[1] Eccentricity
OrbitElement[2] Argument of perihelion
=angle(ascending node-perihelion)
OrbitElement[3] Time of perihelion passage in days since 2000, Jan 1.5 (njd)
OPTIONAL INPUT PARAMETERS:
plane=OrbitPlane
array[2]; type: float
OrbitElement[0] Longitude ascending node
OrbitElement[1] Inclination of orbital plane
m1=m1 scalar; type: float: default: 1 (solar mass)
mass of primary body in units of the solar mass
m2=m2 scalar; type: float: default: 0 (ignored)
mass of secondary body in units of the solar mass
OUTPUTS:
R array[3,*]; type: float
longitude (deg/rad), latitude (deg/rad) and distance (AU)
the angular units depend on the setting of /degrees
OPTIONAL OUTPUT PARAMETERS:
velocity=velocity
array[3,*]; type: float
velocity, tangential velocity and radial velocity (AU/day)
in orbital plane
angularvelocity=angularvelocity
longitude (deg/rad), latitude (deg/rad) and magnitude (AU/day)
of velocity vector
INCLUDE:
@compile_opt.pro ; On error, return to caller
EXTERNAL:
EqKepler
CALLS: ***
EulerRotate, InitVar, TimeGet, ToRadians, destroyvar, nrZBrent
CALLED BY:
HOSOrbit, RemoteView_BodyLoc, UlyssesOrbit
PROCEDURE:
Standard Kepler orbit stuff
MODIFICATION HISTORY:
SEP-1998, Paul Hick (UCSD/CASS)
SEP-1999, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
modified to work with time structures
[Previous]
[Next]
NAME:
KILL_WILD
PURPOSE:
To set wild values to a predetermined value
CATEGORY:
Utils
CALLING SEQUENCE:
clean = kill_wild(dirty, minval, maxval, replace)
INPUTS:
dirty An array which may have wild points in it.
minval The value below which a point is considered wild
maxval The value above which a point is considered wild
replace The value to use in place of the wild values.
OUTPUTS:
clean A copy of dirty with the bad values replaced.
MODIFICATION HISTORY:
Original: 2/7/03; SJT