Expand description
Set of common functions used by spv-rs exposed if you want to used them for your own calculations.
Functions§
- a_to_au
- Takes a in as (arcseconds) and parllax in mas (milliarcsecond) and outputs a in au.
- apogee
- Calculates r max or the maximum distance between the primary and companion boides in a twobody system also known as apogee (suffix may change depending on what object it reffers to). Output is just the x coordinate in the ellipses plane in au.
- apparent_
mag_ to_ absolute_ mag - au_to_m
- Simple function motsly used by
spv-rsto convert au to meters (used for semi major-axis in most cases but can be used for other stuff too). - declination_
total - Calculates total declination in degrees with declination_degree, declination_min and declination_s in degrees, minutes and seconds respectively.
- eccentric_
anomaly - Calculates the eccentric anomaly in degrees
- eccentricity
- If you for some reason had these parameters and not e then here ya go.
- flattening
- Flattening is another way to defining eccentricity for an ellipse.
- flight_
path_ angle - Calculates the flight path angle for the companion body in degrees
- linear_
eccentricity - Distance between one foci and the center of the ellipse in au.
- mean_
motion - Mean motion or n
- parallax_
to_ parsec - Parallax to parsec convert function where the parallax parameter is in mas (milliarcseconds).
- perigee
- Calculates r min or the minimum distance between the primary and companion boides in a twobody system also known as perigee (suffix may change depending on what object it reffers to). Output is just the x coordinate in the ellipses plane in au.
- period
- If you dind’t have the period already
- radius
- Calculates the total radius for a twobody system
- relative_
apogee - Calculates r max or the maximum distance between the primary and companion boides in a twobody system also known as apogee (suffix may change depending on what object it reffers to). Output is 3-dimensional vector that represents the coordinates for apogee rotated to be relative to the earth/sun plane in meters.
- relative_
perigee - Calculates r min or the minimum distance between the primary and companion boides in a twobody system also known as perigee (suffix may change depending on what object it reffers to). Output is 3-dimensional vector that represents the coordinates for perigee rotated to be relative to the earth/sun plane in meters.
- right_
ascension_ total - Calculates total right ascension in degrees with right_ascension_h, right_ascension_min and right_ascension_s in hours, minutes and seconds respectively.
- semi_
major_ axis - If you for some reason had these parameters and not a then here ya go
- semi_
minor_ axis - Calculates the semi minor axis for a twobody system and returns it in meters.
- semi_
parameter - Calculates the semi parameter for a twobody system and returns it in meters.
- specific_
angular_ momentum_ coordinates - Calculates the specific angular momentum coordinates
- specific_
angular_ momentum_ value - Calculates the specific angular momentum value
- specific_
mechanical_ energy - Specific mechanical energy (used by other equation but exposed here if you need it)
- standard_
gravitational_ parameter - Calculates the stadard gravitational parameter
- temperature
- true_
anomaly - Calculates the true anomaly in degrees