Moon Calendar 2022 - a bit off.
A lunar calendar for 2026 displays each day as a small moon phase, arranged by month on a grid, with a red circle animating to highlight today’s date on click. Phases are computed from a reference new moon using a fixed lunar period and mapped via `d3.geoOrthographic` and `d3.geoPath`. The visualization uses `d3.timeDays` for daily data, `d3.scalePoint` for months, and D3 transitions for the click interaction.
AI-generated descriptiona bit off. close enough for hippies, but not witches.
forked from Moon Calendar 2020 which is based on Moon Phase Calculators.
click anywhere to circle today's date.
calculates based on a known new moon date of 1970-01-07+20:35.
uses a lunarPeriod of 2551443000 milliseconds
wich is 29.530590278 days;
or 29 days 12 hours 44 minutes 3 seconds.
wikipedia suggests slightly different numbers but it seems to work pretty good.
2021, at least, visually checks out against a quick look at this calendar.
upon closer inspection, it is off.
the last full moon of the year is 2021-12-18+21:37:58. But this calcs it to be the 20th.
the first is 2021-01-28+12:18:35. But this calcs it to be the 29th.
most seem to be a day or two behind.
setting the "known new moon" to the last of 2020 tightened it up but it's still off.
two issues: the "now date" is calced from 00:00, morning_of, not night_of
and the lunar interval might be a little long?