Lunar Solver

Finds where a lunar image sits on the Moon: which part of the surface it shows, its scale, its orientation and whether it is mirrored. It then labels the craters, maria and mountains in view and shows lunar latitude and longitude under the cursor. It works on full discs, on close-ups with no limb in the frame, and on images with no capture date.

Original work for SetiAstro Suite Pro by Franklin Marek. A star plate solve matches an image against a star catalogue. The Moon has no catalogue to match, so the Lunar Solver predicts what the Moon looked like at the capture time and matches the image against that prediction. The prediction is rendered from NASA's laser-altimeter terrain, with real shading and cast shadows, and the Moon's measured surface brightness.
Workflow
Open a lunar image (stacked, sharpened or not) and make it the active view. Open Lunar Solver from Analysis → Astrometry. Check the capture time: it is read from the image if possible. Solve. The labels appear on the preview, the solution is stored with the image, and Create Annotated Image opens a labelled copy as a new view.

Capture time

The capture time sets the libration (which edge of the Moon is tipped toward us) and where the Sun is. It is read, in this order, from:

The time box is always in UTC. An hour or two of error barely matters: the Sun moves about half a degree per hour on the Moon.

No date? Check Date unknown. The solver then needs no Sun angle at all. After band-pass filtering, a photo of the Moon is a mix of three fixed maps (the albedo times each component of the surface's tilt), and the mix itself is the Sun's direction. With a limb in frame, every rotation, both mirror states and a grid of librations are compared around the limb at once; otherwise surface features suggest placements. Each candidate is scored by how much of the photo the three maps explain, and the libration and Sun angle come out of the winning fit. The result reports the libration, the Sun's colongitude and the phase. The colongitude is measured well when the field shows the terminator; otherwise it is marked approximate. The very first blind solve also builds a search index (about 15 MB, kept with the reference maps), which adds about half a minute once.

Observing site

The Moon is close enough that where you stand on Earth shifts its libration by up to about 1°. The site is taken from What's In My Sky the first time and can be edited here; longitude is east-positive. Without a site the Earth's centre is used, and the fit corrects the libration when the image shows that it is off (most visibly near the limb).

Image scale

Fields smaller than about 200 km hold too few surface features for the feature search to find them. With the image's scale known (arcseconds per pixel), the solver instead tries every rotation and both mirror states at every position on the near side and keeps the placement the Sun-free maps explain best. The scale is read from the image's FITS header when it has one (a WCS, a pixel-scale keyword, or the pixel size and focal length), otherwise it is taken from your last solve: uncheck Image scale if this image came from a different telescope or camera. The scale is only used when the ordinary search fails, so a wrong value costs time, never a wrong answer. This search takes about half a minute. Fields under about 140 km are too small even for it and are not searched this way.

How it solves

A result is accepted only when it clearly beats the mirrored and next-best placements, uses at least 40 surface matches, and fits tightly. An undated result must also explain at least 20 % of the photo, and two and a half times more than any other placement. Otherwise the solver says it failed and changes nothing. It never returns a placement it isn't sure of.

Results

FieldMeaning
FitNumber of surface matches and their RMS residual in pixels. Under about 1 px is typical.
ConfidenceHow much of the band-passed photo the Moon's albedo and slope maps explain at this placement, under the best-fitting Sun. 50–90 % is typical for a sharp image. After an undated solve, the runner-up is the best other placement the search found, usually a few percent.
ScaleArcseconds per pixel (dated solves) and kilometres per pixel at the centre of the disc.
Lunar northDirection of the Moon's north pole in the image, clockwise from up.
MirroredYes when the image is a mirror image of the sky, for example from a star diagonal.
LibrationThe point on the Moon directly facing you (sub-Earth point).
SunColongitude and the sub-solar point. After a blind solve of a field far from the terminator it is marked approximate.
PhaseWaxing or waning, crescent, quarter or gibbous, the fraction of the disc lit, and the phase angle (Sun–Moon–observer).
Frame centreSelenographic latitude and longitude at the centre of the image.

The solution is stored with the image as LUN* header keywords (centre, radius, rotation, mirror, observer distance, the body-to-sky matrix and the Sun vector). Saving keeps them: in the header of a FITS file, and in the metadata SASpro embeds in TIFF, PNG, JPEG and XISF files, so reopening the file brings the solution back (WebP files keep no metadata). Other tools, such as 3D Projection's lunar relief, reuse it without solving again. SASpro's own geometry tools carry it along: flips, 90° and free rotations, rescaling, canvas resizing and crops (rotated ones too) move the solution with the pixels, and Undo restores the old one. A keystone (perspective) crop cannot be followed and removes it; so does resizing the image in another program. Solve again after either.

Labels and coordinates

Names come from the IAU's approved lunar nomenclature: 1,615 named craters, the maria, mountains, valleys and rilles, and 7,064 lettered craters such as Copernicus A. Crater rims are drawn as they really appear, foreshortened toward the limb. Smallest feature sets how wide a feature must be in the image to get a label. Rilles, ridges and crater chains are off by default, because their listed size is their length and they crowd a full-disc view. Lettered craters and features on the unlit side are off by default too. The preview also skips craters smaller than about 9 screen pixels, and any label that would overlap a bigger feature's label. The annotated image also skips overlapping labels, but has no screen-size limit beyond Smallest feature. Move the mouse over the preview to read latitude, longitude and the name of the feature under the cursor.

Spacecraft landing sites are marked with a pink target and the mission's name and year: the Apollo, Surveyor, Luna and Lunokhod, Chang'e, Chandrayaan-3, SLIM, Intuitive Machines and Blue Ghost landers. Hover over one for the country and kind of mission. Positions are measured from Lunar Reconnaissance Orbiter images, to within tens of metres, except Luna 9 and Luna 13, which have never been found from orbit: theirs are the positions announced at the time and may be tens of kilometres off.

Reference data

On first use the solver downloads about 50 MB once:

The IAU feature names ship with SASpro (USGS Gazetteer of Planetary Nomenclature).

Detailed maps. A small, sharp field (finer than about 1.2 km per pixel) that cannot be confirmed on the 1.9 km maps is matched again on maps of its own area at 64 pixels per degree, about 0.47 km per pixel: LOLA LDEM_64 terrain and the same Clementine albedo. Each area is downloaded the first time a solve needs it (about 12 MB for a 4° band of latitude) and kept, so nothing is fetched twice. To solve small fields without an internet connection, for example at a dark site, press Download for Offline Use in the Detailed maps box at the bottom right while you are online: it fetches the whole near side, about 690 MB. Cancel at any time; what has been downloaded is kept and the button continues from there.

Limits. The everyday reference maps resolve about 2 km and the detailed maps about 0.5 km. Very small, very high-magnification fields with little structure may not solve, and neither may a stretch of featureless mare. Earthshine-lit night sides are not modelled.

Credits

Lunar Solver is original SASpro work by Franklin Marek: the ephemeris-driven reference renderer (LOLA relief, Clementine albedo, lunar-Lambert shading and cast shadows), the perspective Moon model with terrain heights and libration correction, the limb, feature and patch matching, the lighting-independent search for undated images, and the IAU label overlay. It builds on published work:

Shading under unknown lighting: Lunar photometry: Data: