Toolyard

Moon Phases, Tides and Eclipses Simulator

Equations in this simulation

E = 360° × age ÷ 29.53, k = (1 − cos E) ÷ 2
ageMoon age (days since new moon)one synodic month, new moon to new moon, is 29.53 days: longer than the 27.32-day orbit because the Earth has moved round the Sun meanwhile
Eelongationthe angle between the Moon and the Sun seen from the Earth: 0° new, 90° first quarter, 180° full
kfraction of the Moon's disk lithalf the Moon is always lit by the Sun; the phase is how much of that half faces us

With the current values:

A = (M ÷ M_E) × (R_E ÷ d)³ × R_E
Aheight of the equilibrium tide0.36 m for the Moon, 0.16 m for the Sun: the Sun is 27 million times heavier but 390 times farther away, and the tide falls with the cube of distance
ddistance to the Moonbetween 356,500 km (perigee) and 406,700 km (apogee); a perigee spring tide is a king tide

With the current values:

η = A_m P₂(cos ψ_m) + A_s P₂(cos ψ_s), P₂(x) = (3x² − 1) ÷ 2
ψangle from the gauge to the point under the Moon (or Sun)high water when the Moon is overhead or underfoot (ψ = 0° or 180°), low water when it is on the horizon
φLatitude of the tide gauge φ (°)the Moon and Sun are taken to stay over the equator, so the tide shrinks toward the poles
ηtide height at the gaugethe equilibrium tide, the shape the ocean would take if it could follow the Moon instantly

With the current values:

β = 5.14° × sin(u)
uangle of the Moon past its ascending nodethe Moon's orbit is tilted 5.14°, so most new and full moons pass above or below the Sun or the Earth's shadow
βheight of the Moon above the Earth's orbital plane, as an anglea solar eclipse needs |β| below about 1.5° at new moon, a lunar one below about 1.0° at full moon; the nodes face the Sun twice in each 346.6-day eclipse year

With the current values:

d = a (1 − e cos M), θ = 2 arctan(R_M ÷ (d − R_E))
eeccentricity of the Moon's orbit0.0549, with a = 384,400 km and the perigee coming round every 27.55 days
θangular size of the Moonabout 0.53°, the same as the Sun: closer than average the Moon covers the Sun completely (total eclipse), farther it leaves a ring (annular)

With the current values:

How to use the Moon phases and tides simulator

  1. The Sun lights the Earth and Moon from the right. As the Moon goes round, the half of it facing the Sun is always lit, but we see a different share of that half: the phase. The icon on the chart shows the Moon as it looks from the northern hemisphere; set the Moon age directly or let it play.
  2. The blue shell is the ocean, its bulges hugely exaggerated: one toward the Moon and one on the far side. The red dot is a tide gauge turning with the Earth through both bulges each day, giving two high tides. The chart plots the tide there for the next month: big spring tides at new and full moon, when the Sun's bulges line up with the Moon's, and small neap tides at the quarters.
  3. Untick the elliptical orbit to see how much of the change comes from the Moon's distance, and move the node angle to bring a new or full moon close to the Earth's orbital plane, where it can make an eclipse: the Moon turns red in a lunar eclipse and its shadow falls on the Earth in a solar one. The next eclipse is predicted under the picture.

Frequently asked questions

Why does the Moon have phases?

The Moon shines by reflected sunlight, so one half is always lit. As it orbits the Earth over 29.5 days, we see that lit half from different angles: none of it at new moon, when the Moon is between us and the Sun, half of it at the quarters, and all of it at full moon, when the Earth is between. The Earth's shadow has nothing to do with the phases; it only falls on the Moon during a lunar eclipse.

Why are there two high tides a day?

The Moon's gravity pulls harder on the near side of the Earth than on its center, and harder on the center than on the far side. Relative to the center, the near ocean is pulled toward the Moon and the far ocean is left behind, so there are two bulges. The Earth turns under them in about 24 hours 50 minutes, the extra 50 minutes because the Moon has moved along its orbit.

What are spring and neap tides?

Spring tides, the largest, come about twice a month near new and full moon, when the Sun's smaller tide (46% of the Moon's) lines up with the Moon's and adds to it. Neap tides come at the quarter moons, when the two are at right angles and partly cancel. "Spring" has nothing to do with the season. In real harbors the biggest tides usually lag a day or two behind the moon phase.

Why is there not an eclipse every month?

The Moon's orbit is tilted 5.1° to the Earth's, so at most new moons the Moon passes above or below the Sun, and at most full moons above or below the Earth's shadow. Eclipses happen only when a new or full moon falls near one of the two points where the orbits cross, the nodes. The Sun lines up with the nodes about every 173 days, giving two or three eclipse seasons a year.

It says WebGL is turned off.

The 3D view needs WebGL, which every current browser has. It can be switched off by hardware acceleration being disabled in the browser settings, or by a very old graphics driver. Turn hardware acceleration on, or try another browser.

Is anything uploaded?

No. The simulation is drawn by your own browser with WebGL; nothing is sent anywhere, and it keeps working offline once the page has loaded.

More science simulations

Related calculators and tools

Guides