# Discrepancies in the equations for converting Horizontal coordinates to Equatorial coordinates

Hello I am trying to convert my Horizontal coordinate system dataset into Equatorial coordinate system. However, it seems that all the information from the internet is different.

I will use symbols as following

θ : (Observer's) Longitude (I am not going to use it now, but required to get LST)

φ : (Observer's) Latitude

A : azimuth

a : altitude (or zenith)

α : R.A.

δ : declination

h : hour angle (Not going to use it now, but required to calculate R.A.)

t : LST (Local Sidereal Time, required to calculate R.A.)

Also, I will just write down formula for the declination because I think I am stuck with this.

First, from Wikipedia,

https://en.wikipedia.org/wiki/Astronomical_coordinate_systems

sin(δ)=sin(φ)sin(a)-cos(φ)cos(a)cos(A)


Next, from the University of St. Andrews (I guess this is one of the British institution?)

http://star-www.st-and.ac.uk/~fv/webnotes/chapter7.htm

sin(δ)=sin(a)sin(φ)+cos(a)cos(φ)cos(A)


From an YouTube page, (Watch from 5:45)

sin(δ)=sin(φ)cos(a)+cos(φ)cos(a)cos(A)


I think I just have to use arcsine to get declination, however, they all suggests me different formula. The more frustrating is that they don't seem to match with example dataset which I have. Can anyone tell me what would be the correct formula? Or am I missing something like definition in domain?

According to the old nomenclature, the azimuth $$A_s$$ was defined starting from the South towards the West, from 0º to 360º (SWNE direction).

If $$a$$ = altitude, (not zenith angular distance = $$z$$) and $$H$$ = hour angle, then the relationships were:

\left. \begin{aligned}\ sin \delta &= \sin a \sin \phi - \cos a \cos \phi \cos A_s \\ \sin H \cos \delta &= \cos a \sin A_s \\ \cos H \cos \delta &=\sin a \cos \phi + \cos a \sin \phi \cos A_s \end{aligned} \right \}

$$\phi$$ is the observer's latitude

Subsequently, the International Astronomical Union (IAU) changed the definition: Azimuth $$A_n$$ is now defined from the North towards the Est, from 0º to 360º, (NESW direction)

$$A_s=A_n+\pi$$

Now, the current relationships are:

\left. \begin{aligned} \sin \delta &= \sin a \sin \phi + \cos a \cos \phi \cos A_n \\ \sin H \cos \delta &= -\cos a \sin A_n \\ \cos H \cos \delta &=\sin a \cos \phi - \cos a \sin \phi \cos A_n \end{aligned} \right \}

If you prefer the latter expressions as a function of zenith angle $$z$$ instead of altitude $$a$$ :

$$a=\dfrac{\pi}2 - z$$

\left. \begin{aligned} \sin \delta &= \cos z \sin \phi + \sin z \cos \phi \cos A_n \\ \sin H \cos \delta &= -\sin z \sin A_n \\ \cos H \cos \delta &=\cos z \cos \phi - \sin z \sin \phi \cos A_n \end{aligned} \right \}

This can be read on the IAU page:

Description: In a horizontal coordinate system, azimuth refers to the direction (along the horizon) at which the object is found. It is measured in degrees starting from the north and towards the east. Azimuth values cover a full circle from 0 deg. to 360 deg. In other words, if you draw an imaginary arc on the celestial sphere from the object to the horizon and perpendicular to the horizon, the azimuth will tell you the location of the point where this arc meets the horizon. An object located directly north would have 0 deg. azimuth, an object directly east would have 90 deg. azimuth and so on. In older textbooks used in multiple countries, the convention was to start measuring the azimuth from the south towards the west. Thus, azimuth values in those textbooks would be shifted by 180 deg.

The link is: GLOSSARY TERM: AZIMUTH

Best regards.