Light and mirrors

The floor that is not a plane

A shadow on a flat floor is a homology, so four marks determine the whole map and the rest of the outline comes back exactly. Dish the floor and the same four marks mispredict the rest by 5.67 mm; ridge it and 9.07 mm; put a step in it — two planes, each of them exactly a homology — and 74.95 mm. The receiver's shape is what breaks the projective description, and it breaks it worst where the surface is flattest.

Worth reading first: A shadow can be un-cast · When the picture surface is not flat.

A shadow on a flat floor is an exact record of the thing that cast it. The map from the occluder’s plane to the floor is a projection from a point between two planes, so it is a plane projectivity — a homology, as the census of this site’s maps found — and four correspondences determine it completely. Given four marks whose positions on the occluder are known, every other point of the outline comes back.

That sentence has a clause in it doing all the work, and this essay is about what the clause costs when it fails. Both surfaces have to be planes.

What the receiving surface costs a four-point fitThe same lamp and the same occluder, cast onto four surfaces. Four marks of the shadow are matched to four known points of the occluder, the map they determine exactly is built, and the other sixty-eight points are predicted by it. On the plane the prediction is right to 3e-13 mm; on the others it is not, and the fit is still exact at the four everywhere — 2e-13 mm — which is what makes the rest a prediction rather than a residual.a flat floor3e-13 mma homology — four points determine ita dished floor5.67 mmnot a homologya ridged floor9.07 mmnot a homologya floor with a step74.95 mmnot a homologyworst error of the predicted pointsexact at the four fitted, on every surface
Fig. 1 The same lamp and the same occluder cast onto four surfaces. Four marks of each shadow are matched to four known points of the occluder, the map they determine exactly is built, and the other sixty-eight points are predicted by it. The plane’s prediction is right to 3e-13 mm; the others are not, and the fit is exact at the four everywhere — 2e-13 mm — which is what makes the rest a prediction rather than a residual.

What is being measured, and what would have been easy to measure instead

There is a way of asking this question that returns zero for every surface, and this site has already published it once.

Un-casting a shadow by running each shadow point back through the known lamp returns the occluder exactly, whatever the receiver does. Of course it does: it is the same ray, traversed backwards. A figure built that way prints 0.000 mm at every curvature, its slider moves the caption and not the picture, and the essay it sits in appears to be about nothing.

That was live on this site for two phases and was found by a sweep asking whether every slider reached the geometry. What is measured here instead is the question a reader with a photograph actually faces:

Fit the map from four marks whose positions are known, and see where it puts the marks it was not given.

On a plane that prediction is exact, because the map really is a homography and four correspondences really do determine one. On anything else the four still fit perfectly — a homography through four points always exists — and everything between them is wrong.

The outline, the shadow, and the outline againA point light is a centre of projection, so the map from the occluder's plane to the floor is a plane projectivity and has an inverse. Running each shadow point back through the lamp returns the outline to 4e-16 m — the recovered curve is drawn over the original and cannot be seen apart from it.the outline, its shadow, and the outline recovered from itcorrect from 20 cm, at 160 mm widerecovered to 4e-16 m
Fig. 2 The flat case, for the baseline. Running the shadow back through the lamp returns the outline to 4e-16 m: the recovered curve is drawn over the original and cannot be seen apart from it.
Un-casting a shadow off a curved floorFitting the map from four marks and predicting the rest: exact at the four, and wrong by up to 6.64 mm everywhere else. A shadow on a plane is a homography and can be inverted from four points; a shadow on anything else is not, and the four points still fit perfectly.the floor is dished — four points fitted, the rest predictedcorrect from 20 cm, at 160 mm widefour points fitted · worst 6.64 mm
Fig. 3 And the dished case, asked the honest way. Four marks fitted, the rest predicted: exact at the four and out by up to 6.64 mm everywhere else.

Four floors, one lamp

The four surfaces are chosen because they fail differently, not because they are a spread of severity.

A plane is the case every homology argument on this site assumes.

A dish — height k(x2+z2)k(x^2+z^2) — curves the same way in both directions. 5.67 mm.

A ridge — height kx2kx^2 — curves one way and is flat the other, so it is developable: it can be unrolled onto a plane without stretching. 9.07 mm, which is worse than the dish.

A step — two horizontal planes at different heights — is flat everywhere except along one line. 74.95 mm, an order of magnitude worse than either curve.

A shadow cast onto a flat floorThe section shows what the ray diagram is: straight lines from the lamp, through the occluder's plane, down to whatever is there to receive them. Nothing about the light or the occluder changes between the four surfaces — only where the rays stop. Fitting the shadow's map from four marks and predicting the other sixty-eight leaves 0.00 mm of error on this one, against 2e-13 mm at the four fitted marks.the lampthe occluder's planea flat floora vertical section — the rays are straightfour points fitted · worst prediction 0.00 mm
Fig. 4 The flat floor in section: straight rays from the lamp, through the occluder’s plane, down to the receiver. The four-mark fit predicts the other sixty-eight points to 0.00 mm.
A shadow cast onto a dished floorThe section shows what the ray diagram is: straight lines from the lamp, through the occluder's plane, down to whatever is there to receive them. Nothing about the light or the occluder changes between the four surfaces — only where the rays stop. Fitting the shadow's map from four marks and predicting the other sixty-eight leaves 5.67 mm of error on this one, against 1e-13 mm at the four fitted marks.the lampthe occluder's planea dished floora vertical section — the rays are straightfour points fitted · worst prediction 5.67 mm
Fig. 5 The dish. Nothing about the lamp or the occluder has changed — only where the rays stop. 5.67 mm of misprediction, against 1e-13 mm at the four fitted marks.

The developable surface is not a special case, and the step is worse than the curve

Two of those results are worth arguing about, because both are places a reader can reasonably expect the geometry to be kinder than it is.

The ridge is developable, and that does not help. A developable surface can be flattened without distortion, so the temptation is to say the shadow on it is “really” a plane shadow rolled up. It is — the map from the occluder to the unrolled ridge is a homography. What a photograph records is the shadow in place, and the map to the surface as it sits in space is not, because the unrolling is not a projective map of anything. The 9.07 mm is that distinction, priced.

A shadow cast onto a ridged floorThe section shows what the ray diagram is: straight lines from the lamp, through the occluder's plane, down to whatever is there to receive them. Nothing about the light or the occluder changes between the four surfaces — only where the rays stop. Fitting the shadow's map from four marks and predicting the other sixty-eight leaves 9.07 mm of error on this one, against 6e-14 mm at the four fitted marks.the lampthe occluder's planea ridged floora vertical section — the rays are straightfour points fitted · worst prediction 9.07 mm
Fig. 6 The ridge, which curves in one direction only. Developable, unrollable, and 9.07 mm out — worse than the dish, because the fit’s four marks straddle a fold the map has no term for.

The step is two planes and is the worst of the four. Each half of it is exactly a homology of the occluder, with its own exact four-point determination. What there is not is a single map covering both, and the fitted homography — forced to compromise between marks on the upper half and marks on the lower — is wrong on both.

That is the general lesson and it is not about curvature at all. Piecewise projective is not projective, and a surface that is flat almost everywhere can be further from admitting a homography than one that is curved everywhere.

A shadow cast onto a floor with a stepThe section shows what the ray diagram is: straight lines from the lamp, through the occluder's plane, down to whatever is there to receive them. Nothing about the light or the occluder changes between the four surfaces — only where the rays stop. Fitting the shadow's map from four marks and predicting the other sixty-eight leaves 74.95 mm of error on this one, against 8e-14 mm at the four fitted marks.the lampthe occluder's planea floor with a stepa vertical section — the rays are straightfour points fitted · worst prediction 74.95 mm
Fig. 7 The step: two planes, one lamp, and 74.95 mm of misprediction — thirteen times the dish’s, on a surface with no curvature anywhere except along a single line.
One map, applied across the creaseA homography fitted to four marks of the shadow that all lie on the floor, then run backwards over the whole shadow to recover the card. Where the shadow is on the floor it returns the card to 6e-16 m. Where the shadow has climbed the wall it returns an outline up to 78.9 cm away from the card — not because the map is inaccurate but because it is the wrong map, and nothing in the picture of the shadow says where one stops and the other starts.recovered from the shadow — up to 78.9 cm out on the wallcorrect from 16 cm, at 160 mm widefloor 6e-16 m · wall 78.9 cm
Fig. 8 The same failure taken to its limit, in the essay next door. A map fitted to four marks on the floor, applied to the part of the shadow that has climbed the wall: 6e-16 m where it was fitted, and up to 78.9 cm where it was not.

What the number means, and what it does not

The millimetres above are the worst error of the prediction, over sixty-eight points, for one lamp and one occluder at one scale. Three things about them are worth pinning down before they are quoted anywhere.

They scale with the scene. Doubling everything doubles them. The dimensionless version is the error as a fraction of the outline’s own extent, which is the form breadth-02 settled on for the vault — 529.4 mm there, 7.7% of the marks’ own spread — and it is the form to use when comparing surfaces of different sizes.

They depend on which four marks are chosen. A different four gives a different map and a different prediction, exact at its own four. What does not change is that no four make the prediction exact: the surface admits no homography at all, so there is nothing for a lucky choice to find.

And they are not a tolerance. A residual of 5.67 mm from a fit would mean the model is nearly right. This is a prediction from an exactly-determined map, so the number says the map is not the map, and refining the fit cannot reduce it.

The vault refuses the projective descriptionThe same design and the same eye, cast onto a flat floor and onto a barrel vault of radius 4.0 m. The best homography fitted to the floor's marks misses by 1.4e-15 m; fitted to the vault's it misses by 529.4 mm, which is 7.7% of the marks' own extent, and no choice of four marks helps.barrel vaulteye · 1.62 mon the floor1e-12 mmon the vault529.4 mmworst miss of the best homography, log scalevault radius 4.0 m7.7% of the extent, against 4e-14%
Fig. 9 The claim in its strongest form, from the phase that established it. The same design and the same eye, on a flat floor and on a barrel vault: the best homography misses the floor’s marks by 1.4e-15 m and the vault’s by 529.4 mm — 7.7% of the marks’ own extent — and no choice of four helps.

There is no threshold

The slider on the un-casting figure runs the floor’s curvature from flat to sharply dished, and the shape of the resulting curve settles a question a reader is entitled to ask: is there an amount of curvature small enough to ignore?

There is not, in the sense that matters. The misprediction is proportional to the curvature over the whole range — 2.28 mm at 0.02, 4.49 at 0.04, 6.64 at 0.06, 12.82 at 0.12, 14.80 at 0.14 — with the constant of proportionality drifting only from about 114 to 106 mm per unit as the dish deepens.

So the answer to “how flat does the floor need to be” is not a threshold but a conversion: however flat the measurement needs, divided by about a hundred. A floor dished by a centimetre over the region a shadow covers costs roughly a millimetre of recovered outline, and there is no regime in which the homology starts holding.

That is the same shape as the rolled print’s behaviour, and the phrasing that essay used is the right one here too: any curvature at all breaks the theorem, and the only question is by how much relative to whatever precision the measurement needs.

Why no homography exists at all

The stronger statement — not that the fitted map is wrong, but that no map of that kind exists — has a one-line argument, and it is the argument breadth-02 found for the vault.

A homography takes lines to lines. Take four points lying on a straight line in the occluder’s plane; their shadows on a plane receiver are four points on a straight line, because a projectivity between planes preserves collinearity. Cast the same four onto a curved receiver and their shadows lie on a curve — the intersection of the plane containing the lamp and the line with the receiving surface, which for a quadric receiver is a conic.

Four points on a conic are not four points on a line, and no homography can take a line to a conic. So the map from the occluder’s plane to a curved receiver is not a homography, and the failure is not a matter of degree: it is a failure of the class.

Which also says why the four-point fit behaves the way it does. It is not approximating a nearby homography badly; it is fitting a homography to data that does not come from one, and the fit is exact at the four points it is given because four points can always be matched, by anything.

What the fit is doing when it compromises

Worth one paragraph on where the error lands, because it is not uniform and the pattern is informative.

The prediction is exact at the four marks, small near them, and worst at the points furthest from all four — which, for four marks spread evenly around a closed outline, is between them rather than beyond them. The error is a smooth function over the outline with four zeros in it, and it grows with the departure of the surface from the plane through the four contact regions rather than with the curvature at any one place.

That is why the step is so much worse than either curve. Its departure from any single plane is a fixed offset over half the region, so the four fitted marks cannot be placed to make it small: whichever four are chosen, one part of the outline is on the wrong plane by the full height of the step.

The same theorem, met in three fields

This is the third time the site has arrived at one statement from a different direction, and putting the three together is the point of having fields at all.

Rephotography. Photograph a photograph and the composite map is a homography, because a projection composed with a projection through a plane is a projection. Roll the print and four marks mispredict the other sixteen by 30.5 px.

The vault. Cast an anamorph onto a barrel vault instead of a floor and no homography fits at all — 529.4 mm against 1.4e-15 m.

And the shadow. Cast onto a dished, ridged or stepped floor and the same collapse, at 5.67, 9.07 and 74.95 mm.

Three fields, three phases, one clause: the middle surface has to be a plane. Nothing about light, printing or anamorphosis enters any of the three arguments, which is why they are one argument.

A print, photographed again — flat and rolledFour marks fix a homography; the other 16 are predicted by it. On a flat print they land where it says to 1e-13 px. Rolled to 1/R = 0.90 per metre the same four predict the same 16 to 30.5 px, because a composition of projections is a projection only if the middle surface is a plane.an anchorcorrect from 19 cm, at 160 mm wideflat 1e-13 px · rolled 30.5 px
Fig. 10 The foundations field’s version. A print stood in the world and photographed again: flat, the four marks predict the other sixteen to 1e-13 px; rolled to 1/R = 0.90 per metre they mispredict by 30.5 px.
Four constructions, three of them the same mapA shadow, a floor anamorph, a mirror and a rectification, each decomposed into its fixed points and lines. Three are central collineations with a line of fixed points; the fourth is not, and that is the difference between changing a picture and changing where it is seen from.constructionfixed structurea shadow, ground to floorhomology · ratio 0.6719a floor anamorphhomology · ratio -1.4815a mirror in a vertical planehomology · ratio -1.0000a rectificationgeneral · three fixed points3 of 4 are centrala line of fixed points is what they share
Fig. 11 And the census that names what is being lost. A shadow, a floor anamorph and a mirror are homologies — a line of fixed points, a centre off it, one ratio. A curved receiver has no such structure to decompose, because the map it produces is not a collineation at all.

What still works when the floor is not flat

The negative result is narrow, and being precise about how narrow it is matters for anyone trying to use a shadow as a measurement.

Knowing the surface is enough. If the floor’s shape is known, every shadow point can be un-cast through the lamp exactly — the same ray, backwards — and the occluder comes back to arithmetic noise on any surface at all. What has been lost is not the recovery; it is the ability to do the recovery from four correspondences and nothing else.

Straightness survives on each planar piece. A straight edge’s shadow is straight wherever the receiver is flat, and bends only where the receiver does. So the shadow’s own shape is evidence about the floor, which is the observation a raking light in a survey photograph is used for.

And the lamp’s position is still recoverable, from shadow tips on any part of the floor whose shape is known — the lamp comes out of the picture by intersecting drawn lines, and those lines are straight in the picture whether or not the floor is.

The outline, the shadow, and the outline againThe inverse is run through a lamp displaced by 60 mm. The recovered outline is 23.23 mm from the truth, and the error is exactly linear in the displacement — a shadow is an exact record of its occluder up to how well the light is known.the inverse is run through a lamp 60 mm out of placecorrect from 20 cm, at 160 mm wide23.23 mm out
Fig. 12 The other thing the recovery is sensitive to, for comparison: a lamp misplaced by 60 mm moves the recovered outline by 23.23 mm, exactly linearly. Being wrong about the light is a proportional error; being wrong about the surface is a structural one.
A shadow cast onto a ridged floorThe section shows what the ray diagram is: straight lines from the lamp, through the occluder's plane, down to whatever is there to receive them. Nothing about the light or the occluder changes between the four surfaces — only where the rays stop. Fitting the shadow's map from four marks and predicting the other sixty-eight leaves 14.58 mm of error on this one, against 2e-13 mm at the four fitted marks.the lampthe occluder's planea ridged floora vertical section — the rays are straightfour points fitted · worst prediction 14.58 mm
Fig. 13 The ridge at a deeper curvature. Nothing about the failure changes character — the prediction is exact at the four fitted marks and further out everywhere else, in proportion.

The rule, stated for use

Compressed to what a reader would actually apply:

Four correspondences determine a shadow’s map only between two planes. Both surfaces, not one. The occluder can be a flat stencil and the floor a bowl, and the four-point method fails.

A curved receiver needs its shape, not more marks. Adding a fifth and sixth correspondence improves nothing structural — it converts an exact fit into a least-squares one, whose residual then reports the surface rather than the measurement.

And a stepped floor is a harder case than a curved one, which is the counter-intuitive half and the one worth remembering on site: the surface that looks flattest in a photograph can be the one that most thoroughly breaks the recovery.

Why the flat case is the one everybody has met

Worth a paragraph, because the flat case’s ubiquity is a fact about rooms rather than about geometry.

Floors are flat, walls are flat, tables are flat, and paper is flat. Nearly every shadow anybody has reasoned about lands on a plane, so the homology is a fair model of ordinary experience, and the four-point determination is genuinely useful — it is how a shadow can be used to measure, and it needs no camera calibration at all.

The cases where it fails are the ones the eye finds interesting: shadows across a stair, across a folded cloth, into a bowl, over a rutted road at sunset. Those are exactly the situations in which a shadow stops being a copy of the object and starts being a picture of the surface, and the numbers above say the transition is not gentle. A step of a few centimetres in the floor costs more than dishing the whole floor by the same amount.

What the receiving surface costs a four-point fitThe same lamp and the same occluder, cast onto four surfaces. Four marks of the shadow are matched to four known points of the occluder, the map they determine exactly is built, and the other sixty-eight points are predicted by it. On the plane the prediction is right to 3e-13 mm; on the others it is not, and the fit is still exact at the four everywhere — 2e-13 mm — which is what makes the rest a prediction rather than a residual.a flat floor3e-13 mma homology — four points determine ita dished floor11.06 mmnot a homologya ridged floor17.20 mmnot a homologya floor with a step257.09 mmnot a homologyworst error of the predicted pointsexact at the four fitted, on every surface
Fig. 14 The same four surfaces at twice the deformation. The plane stays at arithmetic noise, and the ordering of the other three does not change — the step is not worst because it is deepest.
A box and its shadow, both projections from a pointThe rays from the lamp to the corners are the same construction as the rays from the eye to the corners — one operation, two centres.correct from 26 cm, at 160 mm wide34° across
Fig. 15 And the identification the whole field rests on, unaffected by any of this: the rays from the lamp to a box’s corners are the rays from an eye to the same corners. A shadow is a projection; what this essay measures is which pairs of surfaces let that projection be written as a map of the plane.

What links here

Computed from the collection, not written here: the essays that point at this one.

Shares its objects with

Essays that name at least two of the same things, and that neither author linked.

Named objects

A flat tag is an object no other essay names yet.

Central collineationDemonstrationHomographyPicture planePlanar homologyProjective mapReceiving surfaceRectificationResidualShadow projection