You are on page 1of 8

sunrise = 720 – 4*(longitude + ha) – eqtime

Here, longitude and hour angle are in degrees, and the equation of time is in
minutes.

The equation of time is defined as E = GHA (apparent Sun) - GHA (mean Sun). GHA is the Greenwich ho

Here's another equation for sunrise:


cos(ωo) = -tan(φ) * tan(δ)
In this equation:
ωo: is the hour angle in degrees at either sunrise (when negative value is taken) or sunset (when positive value is ta
φ: is the latitude of the observer on the Earth in degrees
δ: is the sun declination in degrees

To calculate the sunrise hour angle, you can:


1. Find the latitude and day of the year
2. Estimate the declination angle of the Sun
3. Multiply the tangents of latitude and declination angle
4. Find the cosecant inverse for the negative of the product
). GHA is the Greenwich hour angle.

nset (when positive value is taken)


The Theory:

Sunrise and Sunset times

The term sunrise time refers to the time when the sun first appears or when daylight has arrived. Similarly, we define
sunset time as the moment when the sun disappears below the horizon. For a given location having latitude ϕ and
nth day of the year, we can estimate the sunrise time using the hour angle for sunrise/sunset, ω.

where:

δ — The declination angle;


ϕ — The latitude of the desired location; and
z — The angle of the Sun below the horizon, equal to 90°90° for the exact time of the desired phenomenon.

We take this angle as it is for the sunset while we subtract it from 360° to find the sunrise. The declination angle is
the angle between the equator and the line joining centers of the Earth and the Sun. The angle of declination
varies with each day, n such that:
δ=arcsin(0.39872⋅sin(L))

where L is the true latitude of the Sun (its projected position on the Earth). Note that there are multiple ways to
calculate the Sun's declination.
In our case, we calculated it from L, with L being given by:

L=M+1.916sin(M)+0.02sin(2⋅M)+282.634 ​

L​=M+1.916sin(M)+0.02sin(2⋅M)+282.634

M is a measure of the Sun's mean anomaly, a quantity that expresses the discrepancy between the true elliptic orbit of
Earth and the ideal circular orbit with an identical period for a given moment of the year:

M=0.9856⋅t−3.289

The value of t depends on the day number (the number of days elapsed since the first of January) and the time of
the day:

The second part of both equations is an approximation of the local sunrise and sunset times. In the formula, λhour is

nothing but an expression of the latitude in hours. To find it, divide the value of the latitude in degrees by 15.

Once we have the hour (angle for sunrise), ω, we can calculate the local time of the sunrise and sunset by applying
the following formula:

T=15ω+RA−(0.06571⋅t)−6.622

where RA is the Sun's right ascension, that we found with:


RA=1/151⋅(arctan(0.91764⋅tan(L))+(L mod 90°)- (arctan(0.91764*tan(L)) mod 900 ))

Back to business: we need to adjust the times we calculated, taking into account the local latitude and the time zone. To
do so, we subtract the former and add the latter:

Tlocal=T−λh+tz
​ ​

While the above methodology is correct, it does not consider atmospheric refraction. This effect occurs due to
the sunlight refracting through the atmosphere and making the sun appear higher above the horizon than its
actual position. A small angle is included in the sunrise and sunset formula to take this phenomenon into account.
Therefore, the corrected sunset and sunrise equation is:

where a is the altitude angle having the value of 0.83°.

You might also like