Skip to main content
`Ctrl`+`K`

# Galactic

class astropy.coordinates.Galactic(*args, copy=True, representation_type=None, differential_type=None, **kwargs)

  Bases: `BaseCoordinateFrame`

  A coordinate or frame in the Galactic coordinate system.

  This frame is used in a variety of Galactic contexts because it has as its x-y plane the plane of the Milky Way. The positive x direction (i.e., the l=0, b=0 direction) points to the center of the Milky Way and the z-axis points toward the North Galactic Pole (following the IAU’s 1958 definition [1]). However, unlike the `Galactocentric` frame, the origin of this frame in 3D space is the solar system barycenter, not the center of the Milky Way.

  Parameters:
    data `BaseRepresentation` subclass instance

      A representation object or `None` to have no data (or use the coordinate component arguments, see below).

    l `Angle`, optional, keyword-only

      The Galactic longitude for this object (`b` must also be given and `representation` must be None).

    b `Angle`, optional, keyword-only

      The Galactic latitude for this object (`l` must also be given and `representation` must be None).

    distance `Quantity` [:ref: ‘length’], optional, keyword-only

      The Distance for this object along the line-of-sight.

    pm_l_cosb `Quantity` [:ref: ‘angular speed’], optional, keyword-only

      The proper motion in Galactic longitude (including the `cos(b)` term) for this object (`pm_b` must also be given).

    pm_b `Quantity` [:ref: ‘angular speed’], optional, keyword-only

      The proper motion in Galactic latitude for this object (`pm_l_cosb` must also be given).

    radial_velocity `Quantity` [:ref: ‘speed’], optional, keyword-only

      The radial velocity of this object.

    representation_type `BaseRepresentation` subclass, `python:str`, optional

      A representation class or string name of a representation class. This sets the expected input representation class, thereby changing the expected keyword arguments for the data passed in. For example, passing `representation_type='cartesian'` will make the classes expect position data with cartesian names, i.e. `x, y, z` in most cases unless overridden via `frame_specific_representation_info`. To see this frame’s names, check out `<this frame>().representation_info`.

    differential_type `BaseDifferential` subclass, `python:str`, `python:dict`, optional

      A differential class or dictionary of differential classes (currently only a velocity differential with key ‘s’ is supported). This sets the expected input differential class, thereby changing the expected keyword arguments of the data passed in. For example, passing `differential_type='cartesian'` will make the classes expect velocity data with the argument names `v_x, v_y, v_z` unless overridden via `frame_specific_representation_info`. To see this frame’s names, check out `<this frame>().representation_info`.

    copy bool, optional

      If `True` (default), make copies of the input coordinate arrays. Can only be passed in as a keyword argument.

  Notes

  [1]

  Blaauw, A.; Gum, C. S.; Pawsey, J. L.; Westerhout, G. (1960), “The new I.A.U. system of galactic coordinates (1958 revision),” MNRAS, Vol 121, pp.123.

  Attributes Summary

  `default_differential` | Default representation for differential data (e.g., velocity)
  `default_representation` | Default representation for position data
  `frame_attributes` |
  `frame_specific_representation_info` | Mapping for frame-specific component names
  `name` |

  Attributes Documentation

  default_differential

    Default representation for differential data (e.g., velocity)

  default_representation

    Default representation for position data

  frame_attributes = {}
  frame_specific_representation_info

    Mapping for frame-specific component names

  name = 'galactic'