astrometry_to_phase_space#
- pygaia.astrometry.vectorastrometry.astrometry_to_phase_space(phi, theta, parallax, muphistar, mutheta, vrad)#
From the input astrometric parameters calculate the phase space coordinates. The output phase space coordinates represent barycentric (i.e. centred on the Sun) positions and velocities.
- Parameters:
phi (float or float array) – The longitude-like angle of the position of the source (radians).
theta (float or float array) – The latitude-like angle of the position of the source (radians).
parallax (float or float array) – The parallax of the source (in mas or muas, see notes)
muphistar (float or float array) – The proper motion in the longitude-like angle, multiplied by cos(theta) (mas/yr or muas/yr, see notes)
mutheta (float or float array) – The proper motion in the latitude-like angle (mas/yr or muas/yr, see notes)
vrad (float or float array) – The radial velocity (km/s)
- Returns:
x (float or float array) – The x component of the barycentric position vector (in pc or kpc).
y (float or float array) – The y component of the barycentric position vector (in pc or kpc).
z (float or float array) – The z component of the barycentric position vector (in pc or kpc).
vx (float or float array) – The x component of the barycentric velocity vector (in km/s).
vy (float or float array) – The y component of the barycentric velocity vector (in km/s).
vz (float or float array) – The z component of the barycentric velocity vector (in km/s).
- Raises:
ValueError – If any of the input parallaxes is non-positive.
Notes
This function has no mechanism to deal with units. The code is set up such that for input astrometry with parallaxes and proper motions in mas and mas/yr, and radial velocities in km/s, the phase space coordinates are in pc and km/s. For input astrometry with parallaxes and proper motions in muas and muas/yr, and radial velocities in km/s, the phase space coordinates are in kpc and km/s. Only positive parallaxes are accepted, an exception is thrown if this condition is not met.
The doppler factor \(k=1/(1-v_mathrm{rad}/c)\) is not used in the calculations. This is not a problem for sources moving at typical velocities of Galactic stars.
This function should not be used when the parallaxes have relative uncertainties larger than about 20 per cent (see http://arxiv.org/abs/1507.02105 for example). For astrometric data with relatively large parallax errors you should consider doing your analysis in the data space and use forward modelling of some kind.