HTML/JS: Equatorial to galactic coordinates

Converter

The converter uses degree decimal values for right ascension and declination.
Right ascension (dd)Declination (dd)
Galactic latitude (b)Galactic longitude (l)
Equatorial to Galactic coordinate converter

Fromula

To convert from equatorial to galactic coordinates,

\small
\begin{equation}
\sin(b) = \sin(\delta_\text{NGP})\sin(\delta) + \cos(\delta_\text{NGP})\cos(\delta)\cos(\alpha - \alpha_\text{NGP})
\end{equation}
\small
\begin{equation}
\tan(l_\text{NCP} - l) = \frac{\cos(\delta)\sin(\alpha - \alpha_\text{NGP})}{\sin(\delta)\cos(\delta_\text{NGP}) - \cos(\delta)\sin(\delta_\text{NGP})\cos(\alpha - \alpha_\text{NGP})}
\end{equation}

According to IAU, the values of $l_\text{NCP}$, $\delta_\text{NGP}$, and $\alpha_\text{NGP}$ are $122.9320^\circ$, $27.1284^\circ$, and $192.8595^\circ$ respectively.

Equatorial coordinates

  1. Indepdendant of the observer’s location and time of observation.
  2. Earth centeric, the equator of Earth is the fundamental plane for the equatorial coordinate system.
  3. Primary direction is towards the vernal equinox.
  4. It is a right-handed coordinate system, positive towards North and East direction.

Galactic coordinates

  1. Independant of the observer’s location and time of observation.
  2. Heliocenteric, the galactic plane is the fundamental plane for the galactic coordinate system.
  3. Primary direction is towards the center of Milky Way galaxy.
  4. It is a right-handed coordinate system, positive towards North and East direction.

See more

For python codes to convert equatorial to galactic coordinates, see the post “How to interconvert celestial coordinate systems?#Equatorial_Galactic”.

See also, “Galactic to Equatorial coordinate converter”

Your thoughts