<p>You seem to be referring to the computation of $m$ in equation (15) for the extinction as the light from the source passes through the atmosphere. The author intends to say that $m\approx \frac{1}{\sin(\alpha_s)}$, where $\alpha_s$ is the altitude of the source (in radian), so restricted to the range $0$ to $ \pi/2$. (Note this is not the inverse of the sine function as the author says but the reciprocal of the sine function)  The altitude is the angle measured from the horizon to the source, which is $=\pi/2-\theta$ where $\theta$ is as in figure 2. Note this blows up when $\alpha_s=0$ ($\theta=\pi/2$) because in the simple approximation being used the path length through the atmosphere in infinite.</p>

<p>The approximation being used here is that of a flat Earth, and $m$ is the number of equivalent atmosphere heights that the light path travellels through</p>

CC BY-SA 3.0
2015-08-08T15:13:42.240Z
2015-08-09T07:58:18.583Z
2015-08-09T07:58:18.583Z
Conrad Turner
<p>I am trying to code up the following article <a href="http://dl.acm.org/citation.cfm?id=2349512" rel="nofollow noreferrer">http://dl.acm.org/citation.cfm?id=2349512</a> (<a href="http://www.cs.bilkent.edu.tr/~cagatay/Modeling_Daytime_and_Night_Lighting_V6.pdf" rel="nofollow noreferrer">alternative free access version</a>) to calculate the light reflected from the moon to a given point on earth at a given time. However I occasionally get a gross error when calculating the distance of the light path through the atmosphere (Figure 2. of the article.)</p>

<p><a href="https://i.sstatic.net/9GxqA.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/9GxqA.png" alt="enter image description here"></a></p>

<p>The approximation given is to take the inverse sine of right ascension in radians, however whenever RA approaches pi, the number blows out to 8e15. Can you suggest a better method?</p>

CC BY-SA 3.0
2015-08-08T13:57:20.453Z
http://dl.acm.org/citation.cfm?id=2349512 My mistake! I should've been clearer, I'm using 1/sin(pi) so my problem is definitely division by zero. How I fix that, I'm not sure?
person157
CC BY-SA 3.0
2015-08-08T15:03:40.623Z
You will not get much help if you expect people to access papers behind a paywall to discover what your question actually is.
Conrad Turner
<the-moon><distances>
Calculate Atmospheric Extinction Using Source Altitude Angle
person157
# Calculate Atmospheric Extinction Using Source Altitude Angle

(Asked by: username_0 on 2015-08-07)

I am trying to code up the following article <http://dl.acm.org/citation.cfm?id=2349512> ([alternative free access version](http://www.cs.bilkent.edu.tr/~cagatay/Modeling_Daytime_and_Night_Lighting_V6.pdf)) to calculate the light reflected from the moon to a given point on earth at a given time. However I occasionally get a gross error when calculating the distance of the light path through the atmosphere (Figure 2. of the article.)

[![enter image description here](https://i.sstatic.net/9GxqA.png)](https://i.sstatic.net/9GxqA.png)

The approximation given is to take the inverse sine of right ascension in radians, however whenever RA approaches pi, the number blows out to 8e15. Can you suggest a better method?

**Tags:** the-moon, distances
> **Comments:**
> **username_0**: http://dl.acm.org/citation.cfm?id=2349512 My mistake! I should've been clearer, I'm using 1/sin(pi) so my problem is definitely division by zero. How I fix that, I'm not sure?  
> **username_1**: You will not get much help if you expect people to access papers behind a paywall to discover what your question actually is.  

---

## 1 answers

### Answer by username_1 on 2015-08-08. Score: 1 | Accepted answer

You seem to be referring to the computation of $m$ in equation (15) for the extinction as the light from the source passes through the atmosphere. The author intends to say that $m\approx \frac{1}{\sin(\alpha\_s)}$, where $\alpha\_s$ is the altitude of the source (in radian), so restricted to the range $0$ to $ \pi/2$. (Note this is not the inverse of the sine function as the author says but the reciprocal of the sine function) The altitude is the angle measured from the horizon to the source, which is $=\pi/2-\theta$ where $\theta$ is as in figure 2. Note this blows up when $\alpha\_s=0$ ($\theta=\pi/2$) because in the simple approximation being used the path length through the atmosphere in infinite.

The approximation being used here is that of a flat Earth, and $m$ is the number of equivalent atmosphere heights that the light path travellels through


---

