# About the formula for taking in count of the observer altitude in sunrise/sunset formula

I'm new here and searched for solution but did not found one. I have found algorithms in order to calculate sunrise and sunset times for an observer on the surface of Earth with explanations of derivations of these formulae, but I want to improve it by including the altitude of the observer. I found an article in Wikipedia.

Could one explain to me, from where is this "2.076 degrees" in the formula $-2.076^{\mathrm{o}} \sqrt{\mathrm{elevation\:of\:observer\:in\:meters}}/60^{\mathrm{o}}$ derived and calculated?

• I don't think you're going to easily track this down. The equation you're referencing appears to me to be an approximation to account for decreased refraction based on increased height. It is likely a functional fit to a computational model and not something derived from pure math/physics on paper. Your best bet is to try and find a citation for this equation and track down the original source and see how they came up with it. – zephyr Jan 4 '17 at 16:28
• A google image search for "altitude correction for horizon" (no quotes) may or may not be helpful (let me know if it's not). – user21 Jan 13 '17 at 15:19
• I believe the altitude should only play a role if you are elevated wrt your local horizon. For example, if you are standing on a skyscraper. – imanorc Apr 4 '17 at 20:45

To calculate that angle, let's measure all distances relative to Earth radius, and say you are at altitude $x$ above the surface. Draw a straight line to the horizon, where that line makes a right angle to the radius of the Earth (it is tangent to the horizon at that point).
So now you have a right triangle with hypotenuse $1+x$, and a side of length $1$, so the angle between the direction you are looking, and the direction to the center of Earth, has a sine of $1/(1+x)$. That means the downward angle we want is however much less that angle is from a right angle. Let's call the downward angle we want $y$, so that $y \ll 1$ if measured in radians, and then what we have from the above is $\sin(\pi/2 - y) = 1/(1+x)$.
Using a trigonometric identity then says $\cos(y) = 1/(1+x)$. But since $x$ and $y$ are $\ll 1$, $\cos(y)$ is close to $1 - y^2/2$ and $1/(1+x)$ is close to $1-x$, so we can say $y$ is close to the $\sqrt{2x}$. That's where the formula comes from, the rest is just unit conversion from radians to degrees and from the radius of the Earth to the altitude in meters.