<p>Let’s start with an easy example and say the orbit of the planet with radius <span class="math-container">$r_p$</span> around the sun with radius <span class="math-container">$r_s$</span> is circular, the orbit of the moon around the planet is circular, the inclination of the moon's orbit is 90 degrees from the planet's orbital plane, and the orbital period of the moon is 1/360th the orbital period of the planet. Let's call the vector from the sun to the planet <span class="math-container">$v_1$</span> (with length <span class="math-container">$d_1$</span>), the vector from the planet to the moon <span class="math-container">$v_2$</span> (with length <span class="math-container">$d_2$</span>), and the vector from the sun to the moon <span class="math-container">$v_3$</span>.  Let’s assume the moon is so small we don’t have to worry about orbital passes in which there is a solar eclipse visible from one side of the moon, but not from the other.</p>
<p>Every consecutive time the moon ascends through the planet's orbital plane, the angle <span class="math-container">$\theta$</span> between <span class="math-container">$v_1$</span> and <span class="math-container">$v_2$</span> will increase by 1 degree.  A little trigonometry (does everyone remember SohCahToa?) will give us the angle between <span class="math-container">$v_1$</span> and <span class="math-container">$v_3$</span> as <span class="math-container">$\phi = \arctan (d_2 \sin\theta/(d_1+d_2 \cos\theta)$</span>.  So from the perspective of the moon, the angle between the sun and the planet in the sky will be <span class="math-container">$\alpha=\theta-\phi$</span>.  The planet will be at least partially eclipsing the sun in the lunar sky whenever <span class="math-container">$\alpha&lt;\beta_p+\beta_s$</span> where <span class="math-container">$\beta_p= \arctan(r_p/d_2)$</span> is the half angle of the planet in the lunar sky, and <span class="math-container">$\beta_s= \arctan(r_s/\sqrt{(d_1+d_2 \cos\theta)^2+(d_2 \sin\theta)^2}$</span> is the half angle of the sun in the lunar sky.</p>
<p>Here is a diagram looking at the planet's orbital plane when the moon passes through the plane:</p>
<p><a href="https://i.sstatic.net/OXdYj.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/OXdYj.png" alt="enter image description here" /></a></p>
<p>Clear as mud?  Let’s do an example with Jupiter (which we will now assume has a circular orbit) and our Sun!  Jupiter’s orbit is 4333 days, so our moon’s orbital period should be 4333/360 =~12 days.  Kepler’s third law says the ratio of the cube of the SMA (semi-major axis) to the square of the orbital period is constant for moons about a body, and we know Jupiter’s moon Callisto has a SMA of 1.883e6km and an orbital period of 16.69 days, so we have the equation <span class="math-container">$d_2^3/12^2=(1.882e6)^3/16.69^2$</span>.  Solving yields <span class="math-container">$d_2=1.51e6km$</span> is how far our moon is from Jupiter.  Jupiter has a radius of <span class="math-container">$r_p=6.9911e5$</span>km so the half solid angle of Jupiter from our moon is <span class="math-container">$\beta_p = \arctan(6.9911e5/1.51e6)=0.5radians$</span> or 28.6 degrees.  The solid angle of the sun from our moon will average about <span class="math-container">$\beta_r = \arctan(6.957e6/7.8e8)=0.00892radians$</span> or 0.551 degrees, but it varies a bit in the third significant digit.</p>
<p>Plug it all into the above equations and you get an orbit without an eclipse, followed by 59 orbits with an eclipse and then another orbit without an eclipse.  Here is the matlab code for posterity:</p>
<pre><code>theta = 0:1:359;
d1=7.8e8;
rs=6.957e6;
d2=1.51e6;
rp = 6.9911e5;
phi = atan(d2*sin((pi/180)*theta)./(d1+d2*cos((pi/180)*theta)));
bp = atan(rp/d2);
bs = atan(rs./sqrt((d1+d2*cos(pi/180*theta)).^2+(d2*sin(pi/180*theta)).^2));
alpha =pi/180*theta-phi;
sum(alpha&lt;bp+bs)*2-1
</code></pre>
<p>Notes:</p>
<ol>
<li><p>This was an easy example because I got to choose all the orbital geometries.  Want to make it harder? Choose a planetary orbital period that isn’t an integer multiple of the lunar orbital period. Want to make it harder? Choose an inclination less than 90 degrees so that some eclipses occur when the moon is outside the planetary orbital plane. Want to make it harder?  Choose highly elliptical orbits for both the planet and the moon, so that <span class="math-container">$d_1$</span> and <span class="math-container">$d_2$</span> both vary as separate functions of time.  Want to make it harder?  Specify a large moon so that some eclipses can only be seen from some points on the moon, but not others.</p>
</li>
<li><p>I provided the solution for partial eclipses.  If you want the solution only for full eclipses, use this equation: <span class="math-container">$\alpha&lt;\beta_p-\beta_s$</span> instead of this equation: <span class="math-container">$\alpha&lt;\beta_p+\beta_s$</span> above.</p>
</li>
<li><p>I did not provide a closed analytical solution for the general problem of counting consecutive solar eclipses from a moon given the orbital elements for the planet and moon and the radii of the sun and planet.  However, in describing the solution for a particular class of orbits, I think I've clearly detailed the calculation method that could extend to any particular orbit. The key is in understanding that even though a moon's orbital plane is fixed in an PCI (Planet Centered Inertial) coordinate system, it appears to precess in a sun-centered, planet-fixed coordinate system. A similar example of this phenomenon is the four seasons here on earth due to the Earth's axial tilt.  The Earth's axial tilt is nearly constant, but from our perspective here on Earth, it appears to precess.</p>
</li>
<li><p>Classical orbital mechanics is disgustingly hard and unforgivingly unintuitive. It's much easier to use Satellite Toolkit or Universe Sandbox to plug in your initial orbits, propagate them, and count the eclipses as others suggest.</p>
</li>
</ol>

CC BY-SA 4.0
2020-11-03T01:35:13.770Z
2020-11-03T18:39:27.857Z
2020-11-03T18:39:27.857Z
Connor Garcia
<p>Simulate the orbits (Kepler's laws) and calculate the geometry:  is the planet between the moon and the sun?</p>
<p>The answer depends greatly on the size and mass of the planet, the distance and shape of the moon's orbit, and to some extent on the orbit of the planet and the size of the sun.</p>
<p>There isn't a simple a+b=c type formula.</p>

CC BY-SA 4.0
2020-11-02T05:04:52.930Z
If the orbits are circular, the moon small and time long, in this case there may be a simple double integral that gives a real answer and meaningful answer.
uhoh
CC BY-SA 4.0
2020-11-02T05:06:28.530Z
-1 because this is only a comment and not a helpful nor useful Stack Exchange answer.
uhoh
CC BY-SA 4.0
2020-11-02T09:32:46.487Z
I think this is the only type of answer that can be given to this question. You need to run the simulation given the specific figures you have for your sample planetary system. The question doesn't allow for any more specific answer.
Rory Alsop
CC BY-SA 4.0
2020-11-03T11:46:44.173Z
@RoryAlsop and yet a second answer has since been posted! If I have time this weekend I'll try to see if I can write it as a double integral and get an analytical solution.  It isn't that hard I don't think.
uhoh
CC BY-SA 4.0
2020-11-03T14:47:52.993Z
@uhoh circular orbits with a relatively small moon and long time would be a good enough approximation :)
Astavie
CC BY-SA 4.0
2020-11-03T18:41:05.620Z
@uhoh I would be very interested in a double integral solution, especially to bounce it off of my answer to see if we get the same result!
Connor Garcia
CC BY-SA 4.0
2020-11-01T16:39:20.830Z
2020-11-01T16:39:20.830Z
James K
<p>Say you have a moon around a gas giant which goes around a star. If the moon has an inclination of around 0° relative to the gas giant's orbit, the gas giant will eclipse the star every orbit of the moon. However, if the inclination is somewhat larger than 0°, not every orbit of the moon will contain a planetary eclipse. How would you calculate the amount of moon orbits in a row with a planetary eclipse?</p>

<natural-satellites><gas-giants><mathematics><eclipse-non-earth-related>
How to calculate the frequency of a gas giant eclipsing the sun from a moon?
Astavie
# How to calculate the frequency of a gas giant eclipsing the sun from a moon?

(Asked by: username_0 on 2020-11-01)

Say you have a moon around a gas giant which goes around a star. If the moon has an inclination of around 0° relative to the gas giant's orbit, the gas giant will eclipse the star every orbit of the moon. However, if the inclination is somewhat larger than 0°, not every orbit of the moon will contain a planetary eclipse. How would you calculate the amount of moon orbits in a row with a planetary eclipse?

**Tags:** natural-satellites, gas-giants, mathematics, eclipse-non-earth-related

---

## 2 answers

### Answer by username_1 on 2020-11-03. Score: 4

Let’s start with an easy example and say the orbit of the planet with radius $r_p$ around the sun with radius $r_s$ is circular, the orbit of the moon around the planet is circular, the inclination of the moon's orbit is 90 degrees from the planet's orbital plane, and the orbital period of the moon is 1/360th the orbital period of the planet. Let's call the vector from the sun to the planet $v_1$ (with length $d_1$), the vector from the planet to the moon $v_2$ (with length $d_2$), and the vector from the sun to the moon $v_3$.  Let’s assume the moon is so small we don’t have to worry about orbital passes in which there is a solar eclipse visible from one side of the moon, but not from the other.
Every consecutive time the moon ascends through the planet's orbital plane, the angle $\theta$ between $v_1$ and $v_2$ will increase by 1 degree.  A little trigonometry (does everyone remember SohCahToa?) will give us the angle between $v_1$ and $v_3$ as $\phi = \arctan (d_2 \sin\theta/(d_1+d_2 \cos\theta)$.  So from the perspective of the moon, the angle between the sun and the planet in the sky will be $\alpha=\theta-\phi$.  The planet will be at least partially eclipsing the sun in the lunar sky whenever $\alpha<\beta_p+\beta_s$ where $\beta_p= \arctan(r_p/d_2)$ is the half angle of the planet in the lunar sky, and $\beta_s= \arctan(r_s/\sqrt{(d_1+d_2 \cos\theta)^2+(d_2 \sin\theta)^2}$ is the half angle of the sun in the lunar sky.
Here is a diagram looking at the planet's orbital plane when the moon passes through the plane:

Clear as mud?  Let’s do an example with Jupiter (which we will now assume has a circular orbit) and our Sun!  Jupiter’s orbit is 4333 days, so our moon’s orbital period should be 4333/360 =~12 days.  Kepler’s third law says the ratio of the cube of the SMA (semi-major axis) to the square of the orbital period is constant for moons about a body, and we know Jupiter’s moon Callisto has a SMA of 1.883e6km and an orbital period of 16.69 days, so we have the equation $d_2^3/12^2=(1.882e6)^3/16.69^2$.  Solving yields $d_2=1.51e6km$ is how far our moon is from Jupiter.  Jupiter has a radius of $r_p=6.9911e5$km so the half solid angle of Jupiter from our moon is $\beta_p = \arctan(6.9911e5/1.51e6)=0.5radians$ or 28.6 degrees.  The solid angle of the sun from our moon will average about $\beta_r = \arctan(6.957e6/7.8e8)=0.00892radians$ or 0.551 degrees, but it varies a bit in the third significant digit.
Plug it all into the above equations and you get an orbit without an eclipse, followed by 59 orbits with an eclipse and then another orbit without an eclipse.  Here is the matlab code for posterity:
theta = 0:1:359;
d1=7.8e8;
rs=6.957e6;
d2=1.51e6;
rp = 6.9911e5;
phi = atan(d2*sin((pi/180)*theta)./(d1+d2*cos((pi/180)*theta)));
bp = atan(rp/d2);
bs = atan(rs./sqrt((d1+d2*cos(pi/180*theta)).^2+(d2*sin(pi/180*theta)).^2));
alpha =pi/180*theta-phi;
sum(alpha
Notes:

This was an easy example because I got to choose all the orbital geometries.  Want to make it harder? Choose a planetary orbital period that isn’t an integer multiple of the lunar orbital period. Want to make it harder? Choose an inclination less than 90 degrees so that some eclipses occur when the moon is outside the planetary orbital plane. Want to make it harder?  Choose highly elliptical orbits for both the planet and the moon, so that $d_1$ and $d_2$ both vary as separate functions of time.  Want to make it harder?  Specify a large moon so that some eclipses can only be seen from some points on the moon, but not others.

I provided the solution for partial eclipses.  If you want the solution only for full eclipses, use this equation: $\alpha<\beta_p-\beta_s$ instead of this equation: $\alpha<\beta_p+\beta_s$ above.

I did not provide a closed analytical solution for the general problem of counting consecutive solar eclipses from a moon given the orbital elements for the planet and moon and the radii of the sun and planet.  However, in describing the solution for a particular class of orbits, I think I've clearly detailed the calculation method that could extend to any particular orbit. The key is in understanding that even though a moon's orbital plane is fixed in an PCI (Planet Centered Inertial) coordinate system, it appears to precess in a sun-centered, planet-fixed coordinate system. A similar example of this phenomenon is the four seasons here on earth due to the Earth's axial tilt.  The Earth's axial tilt is nearly constant, but from our perspective here on Earth, it appears to precess.

Classical orbital mechanics is disgustingly hard and unforgivingly unintuitive. It's much easier to use Satellite Toolkit or Universe Sandbox to plug in your initial orbits, propagate them, and count the eclipses as others suggest.


---

### Answer by username_2 on 2020-11-01. Score: 1

Simulate the orbits (Kepler's laws) and calculate the geometry: is the planet between the moon and the sun?

The answer depends greatly on the size and mass of the planet, the distance and shape of the moon's orbit, and to some extent on the orbit of the planet and the size of the sun.

There isn't a simple a+b=c type formula.

> **Comments:**
> **username_3**: If the orbits are circular, the moon small and time long, in this case there may be a simple double integral that gives a real answer and meaningful answer.  
> **username_3**: -1 because this is only a comment and not a helpful nor useful Stack Exchange answer.  
> **username_4**: I think this is the only type of answer that can be given to this question. You need to run the simulation given the specific figures you have for your sample planetary system. The question doesn't allow for any more specific answer.  
> **username_3**: @RoryAlsop and yet a second answer has since been posted! If I have time this weekend I'll try to see if I can write it as a double integral and get an analytical solution.  It isn't that hard I don't think.  
> **username_0**: @uhoh circular orbits with a relatively small moon and long time would be a good enough approximation :)  
> **username_1**: @uhoh I would be very interested in a double integral solution, especially to bounce it off of my answer to see if we get the same result!  

---

