Orbit.__init__(vxvv=None, ro=None, vo=None, zo=None, solarmotion=None, radec=False, uvw=False, lb=False)[source]




Initialize an Orbit instance


vxvv - initial conditions (must all have the same phase-space dimension); can be either

  1. astropy (>v3.0) SkyCoord with arbitrary shape, including velocities (note that this turns on physical output even if ro and vo are not given)

  2. array of arbitrary shape (shape,phasedim) (shape of the orbits, followed by the phase-space dimension of the orbit); shape information is retained and used in outputs; elements can be either

    1. in Galactocentric cylindrical coordinates with phase-space coordinates arranged as [R,vR,vT(,z,vz,phi)]; needs to be in internal units (for Quantity input; see ‘list’ option below)

    2. [ra,dec,d,mu_ra, mu_dec,vlos] in [deg,deg,kpc,mas/yr,mas/yr,km/s] (ICRS; mu_ra = mu_ra * cos dec); (for Quantity input, see ‘list’ option below);

    1. [ra,dec,d,U,V,W] in [deg,deg,kpc,km/s,km/s,kms]; (for Quantity input; see ‘list’ option below); ICRS frame

    2. (l,b,d,mu_l, mu_b, vlos) in [deg,deg,kpc,mas/yr,mas/yr,km/s) (mu_l = mu_l * cos b); (for Quantity input; see ‘list’ option below)

    3. [l,b,d,U,V,W] in [deg,deg,kpc,km/s,km/s,kms]; (for Quantity input; see ‘list’ option below)

    1. and 6) also work when leaving out b and mu_b/W

  3. lists of initial conditions, entries can be

    1. individual Orbit instances (of single objects)

    2. regular or Quanitty arrays arranged as in section 2) above (so things like [R,vR,vT,z,vz,phi], where R, vR, … can be arbitrary shape Quantity arrays)

    3. list of Quantities (so things like [R1,vR1,..,], where R1, vR1, … are scalar Quantities

    4. None: assumed to be the Sun; if None occurs in a list it is assumed to be the Sun and all other items in the list are assumed to be [ra,dec,…]; cannot be combined with Quantity lists (2 and 3 above)

    5. lists of scalar phase-space coordinates arranged as in b) (so things like [R,vR,…] where R,vR are scalars in internal units


ro - distance from vantage point to GC (kpc; can be Quantity)

vo - circular velocity at ro (km/s; can be Quantity)

zo - offset toward the NGP of the Sun wrt the plane (kpc; can be Quantity; default = 20.8 pc from Bennett & Bovy 2019)

solarmotion - ‘hogg’ or ‘dehnen’, or ‘schoenrich’, or value in [-U,V,W]; can be Quantity




2018-10-13 - Written - Mathew Bub (UofT)

2019-01-01 - Better handling of unit/coordinate-conversion parameters and consistency checks - Bovy (UofT)

2019-02-01 - Handle array of SkyCoords in a faster way by making use of the fact that array of SkyCoords is processed correctly by Orbit

2019-02-18 - Don’t support radec, lb, or uvw keywords to avoid slow coordinate transformations that would require ugly code to fix - Bovy (UofT)

2019-03-19 - Allow array vxvv and arbitrary shapes - Bovy (UofT)