Skip to content

Latest commit

 

History

History
20 lines (12 loc) · 1.27 KB

bary-state.md

File metadata and controls

20 lines (12 loc) · 1.27 KB

//astronomy/io.github.cosinekitty.astronomy/baryState

baryState

fun baryState(body: Body, time: Time): StateVector

Calculates barycentric position and velocity vectors for the given body.

Given a body and a time, calculates the barycentric position and velocity vectors for the center of that body at that time. The vectors are expressed in J2000 mean equator coordinates (EQJ).

Return

The barycentric position and velocity vectors of the body.

Parameters

body The celestial body whose barycentric state vector is to be calculated. Supported values are Body.Sun, Body.Moon, Body.EMB, Body.SSB, and all planets: Body.Mercury, Body.Venus, Body.Earth, Body.Mars, Body.Jupiter, Body.Saturn, Body.Uranus, Body.Neptune, Body.Pluto.
time The date and time for which to calculate position and velocity.