Simple models

Determining the relative position of the sun from any location on Earth at any time of the year involves a series of calculations, many of which are approximations.  The first step to understanding these is to summarize a few basic quantities.

Declination of the Sun (\delta) - This is the angle between the Earth’s axis of rotation and the plane normal to a line connecting the centers of the Earth and Sun.

A simple approximation for the declination (in degrees) is:

\delta =\frac{23.45\pi }{180}\sin \left ( 2\pi \frac{\left ( 284+n\right ) }{365}\right ) ,  where n is the day of year.

Hour Angle (\omega) – This is the angle of the Sun in it’s apparent orbit through the sky.  By convention it is defined to zero at solar noon (when Sun reaches its highest point in the sky each day).  Since it takes approximately 24 hours for the Earth to rotate each day, the hour angle changes by 15 degrees each hour (360/24).

Solar vs. Standard Time – While local time is syncronous across a single time zone, solar time is defined as the relative position of the sun to an observation point.  Therefore, solar time will vary by longitude across the time zone at a given local time.  What is known as the “Equation of Time” is used to calculate the difference between solar and local time as a function of location and time of year.

The equation of time (E_{qt}) can be approximated with a series of equations depending on the day of the year:

For n=1 to 106: E_{qt}=-14.2\sin \left ( \frac{\pi \left ( n+7 \right )}{111} \right )

For n=107 to 166 E_{qt}=4.0\sin \left ( \frac{\pi \left ( n-106 \right )}{59} \right )

For n =167 to 246 E_{qt}=-6.5\sin \left ( \frac{\pi \left ( n-166 \right )}{80} \right )

For n = 247 to 365 E_{qt}=16.4\sin \left ( \frac{\pi \left ( n-247 \right )}{113} \right )

Using this approximation the solar time (T_{solar}) in hours is calculated as:

T_{solar}=T_{local}+\frac{E_{qt}}{60}+\frac{Long_{sm}-Long_{local}}{15}, where Long_{sm} is the longitude of the standard meridian of the observers time zone (degrees) and Long_{local} is the longitude of the observer (degrees).

The hour angle (radians) can be calculated as a function of solar time as:

\omega =\pi \frac{12-T_{solar}}{12} .

The cosine of the solar zenith angle can then be calculated as:

\cos \left ( Z \right )=\sin\left ( \lambda \right )\sin \left ( \delta \right )+\cos \left ( \lambda \right )\cos \left ( \delta \right )\cos \left ( \omega \right ) , where \lambda is the latitude of the observer.