[1][2][3] This horizontal coordinate defines the Sun's relative direction along the local horizon, whereas the solar zenith angle (or its complementary angle solar elevation) defines the Sun's apparent altitude.
There are several conventions for the solar azimuth; however, it is traditionally defined as the angle between a line due south and the shadow cast by a vertical rod on Earth.
This is the definition used by NREL in their solar position calculators[4] and is also the convention used in the formulas presented here.
[6] A 2021 publication presents a method that uses a solar azimuth formula based on the subsolar point and the atan2 function, as defined in Fortran 90, that gives an unambiguous solution without the need for circumstantial treatment.
The method first calculates the declination of the Sun and equation of time using equations from The Astronomical Almanac,[8] then it gives the x-, y- and z-components of the unit vector pointing toward the Sun, through vector analysis rather than spherical trigonometry, as follows: where It can be shown that
With the above mathematical setup, the solar zenith angle and solar azimuth angle are simply where If one prefers North-Clockwise Convention, or East-Counterclockwise Convention, the formulas are Finally, the values of
at 1-hour step for an entire year can be presented in a 3D plot of "wreath of analemmas" as a graphic depiction of all possible positions of the Sun in terms of solar zenith angle and solar azimuth angle for any given location.