What survives

Perpendicular is a pairing

On a horizon, the vanishing point of a direction and the vanishing point of the direction at right angles to it are joined by a map that is its own inverse. Such a map has two degrees of freedom rather than three, so two pairs determine it — and its two imaginary fixed points are the focal length and the centre of the picture, handed back from two rectangles on one floor with nothing assumed.

Worth reading first: A line is a space of its own · The two points a picture hides · Recovering the camera from the picture it drew.

Two directions in the ground plane are at right angles. Each has a vanishing point on the horizon. So there is a rule taking a point of the horizon to another point of the horizon, and the rule is symmetric: apply it twice and the direction is back where it started.

A map that is its own inverse is called an involution, and it is not a curiosity. It is a two-parameter object where a general map of a line has three, and the missing parameter is worth a piece of machinery.

Perpendicularity pairs the horizon with itselfEach arc joins the vanishing point of a horizontal direction to the vanishing point of the direction at right angles to it. The pairing is its own inverse, which makes it an **involution** — a two-parameter object, so **two pairs determine it** and a third is predicted. The two black arcs are the input; the coloured one is predicted and lands 1.1e-13 px from where the camera puts it. The involution's fixed points are 318.00 ± 622.40i — imaginary, which is why nothing on a horizon is its own perpendicular — and those two numbers are the centre of the picture and the focal length.the horizonthe centre, 318focal 622.396 pxtrue 622.396 px
Fig. 1 The pairing, drawn as arcs across the horizon. Two of the arcs are given and the third is predicted, landing a tenth of a millionth of a millionth of a pixel from where the camera puts it.

Two pairs, not three

A line is a space of its own counts a projectivity’s freedom at three, so three pairs determine one. An involution is the subset with trace zero, which is one condition, leaving two.

So two pairs determine an involution, and a third pair is then a prediction rather than an input.

That is the whole of the operational content. A pair of perpendicular directions is a rectangle lying on the floor; two rectangles, at different angles, are two pairs; and two pairs are enough.

Two rectangles on one floor, and no assumption about the centreEvery route this site has had to a focal length needed three mutually perpendicular directions, or two and an assumed centre of the picture. Two rectangles lying flat on one floor at different angles give two pairs of perpendicular directions, an involution takes exactly two pairs, and its imaginary fixed points hand back both numbers at once: focal 622.3965 px against 622.3965, a gap of 1.1e-13, and the centre at 318.0000 against 318.0, a gap of 5.7e-14. The camera here is deliberately off-centre so that recovering the centre is a measurement rather than a coincidence.horizonthe centre, recoveredcorrect from 14 cm, at 160 mm widefocal 622.40 px · centre off by 5.7e-14 px
Fig. 2 Two rectangles on one floor, at twelve degrees and fifty-seven. Nothing else is given — no third direction, no vertical, and no assumption about where the centre of the picture is.

What the fixed points are

An involution’s fixed points come from a quadratic whose discriminant is negative — always, for this one, and the negativity is the geometry rather than an accident. A real fixed point would be a direction that is its own perpendicular, and there is none.

So the two fixed points are complex conjugates, at px±ifp_x \pm i f along the horizon.

The real part is where the centre of the picture falls on the horizon. The imaginary part is the focal length. Measured on a camera whose principal point was deliberately put off-centre so that recovering it would be a measurement: the focal length comes back to eleven decimal places and the centre to twelve.

Two rectangles on one floor, and no assumption about the centreEvery route this site has had to a focal length needed three mutually perpendicular directions, or two and an assumed centre of the picture. Two rectangles lying flat on one floor at different angles give two pairs of perpendicular directions, an involution takes exactly two pairs, and its imaginary fixed points hand back both numbers at once: focal 622.3965 px against 622.3965, a gap of 0.0e+0, and the centre at 318.0000 against 318.0, a gap of 0.0e+0. The camera here is deliberately off-centre so that recovering the centre is a measurement rather than a coincidence.horizonthe centre, recoveredcorrect from 14 cm, at 160 mm widefocal 622.40 px · centre off by 0.0e+0 px
Fig. 3 Two different rectangles on the same floor, giving the same two numbers. What is being fitted here is a two-parameter map, and the two parameters are the two numbers.

Those two points are not new to this site. They are the imaged circular points, which the two points a picture hides computes by intersecting the vanishing line with the image of the absolute conic, and which the whole metric upgrade of a plane consists of.

Two points, and everything metric followsThe imaged circular points are where the horizon meets the image of any circle in the plane, and they are a conjugate pair — the first coordinate here is 169.5 − 446.0i. A rectification built from them and nothing else returns the world's angles to 2.2e-13° and its length ratios to 5.6e-15, and no length at all.horizonthe horizon does not cut the circle — the pair is complexrectified from the two points aloneangles: 2.2e-13°ratios: 5.6e-15length: —circle of radius 1.05 ma dash is a quantity two points cannot buy
Fig. 4 The same two points reached the other way: as the intersection of a plane’s vanishing line with the image of the absolute conic. Two routes, one pair of points.
One conic, and the focal length falls out of itThe image of the absolute conic for a camera with square pixels is a circle of radius f about the principal point. Two vanishing points of perpendicular directions must be conjugate with respect to it, and solving that for f gives 812.769 px — the same number the orthocentre construction gives, and 1.1e-13% from the focal length the camera was built with.horizonprincipal pointv_zorthocentre: 812.7691 px · vᵀωu = 0: 812.7691 pxconjugacy residual 5.9e-10 in focal-length unitscorrect from 19 cm, at 160 mm wide46° across
Fig. 5 And the conic they are the intersection with. For a square-pixel camera it is a circle of radius f about the principal point, which is why the two numbers fall out of the fixed points in exactly that arrangement.

Arriving at them from a map of one line rather than from a conic in the plane is not a new theorem. It is a cheaper route, and cheap enough to change what is possible.

Written out

The relation itself is one line and it is worth seeing, because everything above is a reading of it.

Two directions are perpendicular exactly when their vanishing points v\mathbf{v} and u\mathbf{u} satisfy

(vp)(up)+f2=0(\mathbf{v} - \mathbf{p})\cdot(\mathbf{u} - \mathbf{p}) + f^{2} = 0

with p\mathbf{p} the principal point. For a level camera both points lie on a horizontal horizon that carries p\mathbf{p}, so the vertical components vanish and it collapses to

(xpx)(xpx)=f2(x - p_x)(x' - p_x) = -f^{2}

which is a Möbius map of the horizon’s own coordinate with xx' a reciprocal of xx. Its matrix has trace zero by inspection, which is the involution; its fixed points solve (xpx)2=f2(x-p_x)^2 = -f^2, which is the pair; and the minus sign is the reason the pair is imaginary.

The minus sign is not a convention. One conic calibrates the camera makes the same point about the same sign from the conic’s side: it is a refusal, and a positive right-hand side means no camera produces this picture from a rectangular object at all.

How loose the test has to be before perspective preserves measureThe count of systems the table calls measure-preserving, against the tolerance. It sits at 7 across nine decades and then steps to 9 when the tolerance passes 15.6% — the drift a real pinhole picture actually produces. The exclusion in the table above is a statement about that boundary, and this is where the boundary is.02.5057.50-8-6-4-20log₁₀ of the tolerance on midpoint driftsystems counted as preserving measureperspective admitted at 15.6%the exclusion, sweptthe boundary is measured, not chosen
Fig. 6 What that refusal looks like when it fires. The relation either has a solution or it does not, and the case with none is a statement about the drawing rather than about the arithmetic.

The third pair is a check, not an input

Two pairs settle the map, so a third rectangle on the same floor is spare — and spare is exactly what a measurement wants.

Fitted from two and predicted onto a third, the pairing lands a tenth of a millionth of a millionth of a pixel from where the camera puts it. That is the arithmetic floor, and it is a genuine round trip: the third rectangle’s orientation never entered the fit.

Perpendicularity pairs the horizon with itselfEach arc joins the vanishing point of a horizontal direction to the vanishing point of the direction at right angles to it. The pairing is its own inverse, which makes it an **involution** — a two-parameter object, so **two pairs determine it** and a third is predicted. The two black arcs are the input; the coloured one is predicted and lands 1.1e-13 px from where the camera puts it. The involution's fixed points are 318.00 ± 622.40i — imaginary, which is why nothing on a horizon is its own perpendicular — and those two numbers are the centre of the picture and the focal length.the horizonthe centre, 318focal 622.396 pxtrue 622.396 px
Fig. 7 The prediction made at a different third angle. The two input arcs are unchanged and the predicted one moves with the question, which is what distinguishes a prediction from a fit with a spare parameter.
Perpendicularity pairs the horizon with itselfEach arc joins the vanishing point of a horizontal direction to the vanishing point of the direction at right angles to it. The pairing is its own inverse, which makes it an **involution** — a two-parameter object, so **two pairs determine it** and a third is predicted. The two black arcs are the input; the coloured one is predicted and lands 1.1e-13 px from where the camera puts it. The involution's fixed points are 318.00 ± 622.40i — imaginary, which is why nothing on a horizon is its own perpendicular — and those two numbers are the centre of the picture and the focal length.the horizonthe centre, 318focal 622.396 pxtrue 622.396 px
Fig. 8 And with the two inputs changed instead. Any two pairs give the same involution, so which two rectangles were used is not a choice that affects the answer — only its conditioning.

On a real picture that spare rectangle is the whole of the quality control. A third pair that lands where the first two put it says the two rectangles really were rectangles and really were coplanar; a third pair that lands somewhere else says one of those was false, and says it without needing to know which.

What the cheap route buys

Every route this site has had to a focal length has needed one of two things.

Three mutually perpendicular directions — the orthocentre construction of recovering the camera, which is exact and needs a box.

A box drawn from a known camera, and the camera recovered from the drawingThree vanishing points found from the twelve drawn edges alone give back the focal length to 4e-15 relative.recovered principal pointused to drawrecoveredgapfocal length853.90853.904e-15principal x345.0345.02e-12angle44.0°44.0°correct from 20 cm, at 160 mm wide44° across
Fig. 9 The three-direction route. Three vanishing points, a triangle, an orthocentre, and a focal length to one part in ten to the fifteenth — and a box in the scene to read them off.

Or two directions and an assumed principal point — the two-vanishing-point relation, which needs only a rectangle and needs to be told where the centre of the picture is.

The same cube turned 24° — a three-point constructionNothing about the construction changed. The number of vanishing points inside any finite distance is 3, and 1 of them fall on the canvas.horizon3 vanishing points at a finite distance2564 px · 8129 px · 531 px
Fig. 10 The two-point case. Two vanishing points on the horizon, and one equation with two unknowns in it until the centre is supplied.

The involution is the third route and it needs neither. Two rectangles lying flat on one floor, at different angles, give both numbers together — no vertical anywhere in the scene, and nothing assumed about the frame.

That matters because assuming the centre is the standing weakness of the second route. The principal point is not the centre measures what a shifted or cropped frame costs, and it is per cents rather than parts per million.

The cost of assuming the principal pointThe two-vanishing-point route to a focal length needs a principal point supplied, and every textbook supplies the middle of the frame. On a shifted or cropped picture that is wrong, and f² = −(v₁ − p)·(v₂ − p) turns the error into a product of two large numbers: 1.6% at 150 px of shift. The three-point recovery does not assume it and has no such error.00.50011.50050100150how far the principal point really is from the middle of the frame (px)error in the focal length, from assuming it is not (%)unshifted: the assumption is truea 44° lens1.55% at 150 px of shift
Fig. 11 The price of the assumption the involution does not make. A frame that has been shifted or cropped has its centre somewhere else, and a focal length computed as though it had not is confidently wrong.
Level, tilted, shiftedTilting the camera up to fit the building in makes the verticals converge by 4.55°. Shifting the lens up instead moves the principal point 95 px off centre, frames the same view, and leaves the verticals parallel to 0e+0° — because the picture plane never tilts.level — the top is cut off0.00° of spreadtilted 13°4.55° of spreadshifted 95 px0.00° of spreada shift moves every point by exactly the shift95.0 px, and no direction at all
Fig. 12 The arrangement that produces the shift. A rising front moves the principal point without tilting the picture plane, so the verticals stay parallel and the centre of the picture is nowhere near the centre of the frame.

The condition, and it is a real one

The two numbers can be read straight off the horizon only when the camera is level — when the principal point lies on the horizon at all.

That is not a technicality and it is the honest limit of the cheap route. Tilt the camera by a degree and the recovered focal length is a tenth of a pixel out; by nine degrees and it is eight pixels out.

The level camera is a condition, and this is what it costsReading the focal length off the horizon's involution assumes the principal point lies on the horizon, which is true when the camera is level and false as soon as it is not. Tilted by one degree the recovered focal length is out by 0.1 px; by 9.0° it is out by 7.8 px. The general statement — the imaged circular points of a plane are two constraints on the image of the absolute conic, whichever plane it is — survives; what does not survive is reading the two numbers straight off the line.0246802468tilt of the camera (degrees)error in the recovered focal length (px)exact when level8 px out at 9.0°
Fig. 13 The cost of the condition, swept. Exact at zero and growing smoothly with the tilt, which is what says the error is the tilt rather than the arithmetic.
Four figures of the same height, camera level at 1.62 mThe horizon cuts every one of them at 91.0% of its height — the eye height over the figure height — however far away it is.horizon = eye level, 1.62 m91.01%correct from 26 cm, at 160 mm widespread 0
Fig. 14 The condition in its usual form. The horizon is at eye level when the picture plane is vertical, and the site has an essay about that alone because the “if” is left out everywhere it is taught.

What survives the tilt is the general statement rather than the shortcut. The involution still exists on any plane’s vanishing line, and its fixed points are still that plane’s imaged circular points. What stops being true is that the two parameters of the involution are the focal length and the horizontal position of the centre; on a tilted camera they are two combinations of three unknowns, and one plane no longer separates them.

Projective, affine, metric — what each stage buysThe photograph fixes the plane only up to a projectivity: the midpoint of a receding side lands 0.3970 of the way along. Supplying the plane's vanishing line buys the midpoint back exactly and nothing else. Supplying the image of one circle buys the last three numbers, at which point the right angle is 90.000° and two equal sides measure 1.000000. The cross-ratio is 1.333333 in all three, because it was never lost.projectiveaffinemetricmidpointtwo equal sidesa right anglecross-ratioprojective1.333333333affine0.5000001.333333333metric0.5000001.00000090.000°1.333333333— means the stage does not determine it at allcross-ratio 1.333333 throughout
Fig. 15 Which is exactly the stratification’s own account of it. One plane’s circular points buy the metric structure of that plane; the camera has three unknowns and one plane supplies two constraints.

Why an involution and not just a map

There is a temptation to skip the word. Perpendicularity gives a correspondence between points of the horizon; fit a general projectivity to it from three pairs and read off whatever comes out.

That would work and it would waste a rectangle. Worse, it would hide the structure: the fitted map would come back with trace zero every time and nothing would say why, and a fit with a parameter that is always the same value is a fit that has been asked the wrong question.

One number, three kinds, and the drawing office supplies one of eachNormalise a map of a line to determinant one and its whole classification is in its trace. Advancing by one bay gives trace² = 4.000000000 — **parabolic**, one fixed point counted twice, and that point is the vanishing point. Doubling a world distance gives 4.5000 — **hyperbolic**, two fixed points and a multiplier a straightedge can read. Pairing perpendicular directions on a horizon gives 0.000000000 — **elliptic**, and its two fixed points are complex conjugates, which is the algebra saying that no direction on a horizon is its own perpendicular. Nothing here was constructed to make the point; all three are operations this site performs elsewhere.one more bay4.0000parabolicdistance × 3.05.2953hyperbolicperpendicular pairing0.0000elliptictrace² ÷ determinant, and the kind it decides4 — the parabolic lineabove 4 hyperbolic, below 4 ellipticexactly 4 is parabolic
Fig. 16 The classification the trace decides, with this map as its third entry. Trace zero is not a coincidence of the fit; it is what “applying it twice does nothing” means.

The word also imports a fact that would otherwise have to be rediscovered: an involution of a line is determined by two pairs, and its two fixed points are harmonically separated by every pair. So each rectangle’s two vanishing points are harmonic with the imaged circular points, which is a straightedge statement about a drawing and a construction a draughtsman could actually perform.

Halving a receding rectangle two waysThe diagonals cross at the image of the rectangle's centre, 8e-14 px from it — the construction is exact at every camera because it uses only which lines meet where, and that is what a projection keeps. Halving the drawn side with a ruler instead lands 22.7 px from the image of the side's midpoint.the diagonals against a ruler, at 3.2 mthe diagonals — exactthe ruler — 22.7 px outcorrect from 23 cm, at 160 mm wideharmonic set -1.000000 · 8e-14 px
Fig. 17 The harmonic relation, constructed rather than computed. Three points and a straightedge give the fourth, with no measurement anywhere.

A wall works too, and says something else

Nothing above needed the plane to be the floor. Any plane has a vanishing line, any two perpendicular directions in it have vanishing points on that line, and the pairing is an involution.

A rectangle on a wall therefore gives a pair on the wall’s own vanishing line, and two rectangles on one wall give that wall’s imaged circular points.

The picture plane tilted 14°Pointing the camera up tilts the picture plane with it, and three things happen at once: the verticals converge — 3.59° between the outer two — the horizon drops 213 px below the middle of the frame, and the vertical vanishing point arrives at 3425 px from the principal point. They are one fact: the product of those two offsets is f².correct from 20 cm, at 160 mm wideverticals converge 3.59° · horizon 213 px off centre
Fig. 18 A plane that is not the ground, with its own vanishing line. The construction does not care which plane it is; what changes is where the line falls in the picture.

What is new is what happens when the two planes are different. Each plane contributes two constraints on the image of the absolute conic, and the conic has three unknowns for a square-pixel camera, so one plane is short by one and two planes are over-determined by one. Two rectangles on the floor and one on a wall is therefore a complete calibration with a check left over, and it needs no vertical edge anywhere — which is worth knowing because the vertical is the direction a photograph most often has nothing straight along.

A façade, flattened out of the photographFour corners of a rectangle of known proportions fix the homography. Three lengths it was never given come back to 4e-16 relative — so every measurement on that plane is available, in units of the rectangle's own width.the picturethe same plane, rectifieddoor — 0.5068 widths (true 0.5068)sill — 0.3026 widths (true 0.3026)diagonal — 1.1766 widths (true 1.1766)worst error 4e-16 relativethe probes were not used to build the map
Fig. 19 And what each plane’s own circular points buy for that plane: a rectification that returns angles and ratios of lengths exactly, and refuses to name a length.
The three vanishing points of one box, drawn to scale with the boxThe picture is the small rectangle. Two of the three vanishing points fall well outside it, which is why they are computed rather than located by eye.orthocentrethe pictureVP₁VP₂VP₃focal length from the triangle — 853.9 pxspread 1e-14% across three routes
Fig. 20 The alternative that needs the vertical. Three mutually perpendicular bundles and a triangle — more information, more assumptions about what is in the scene.

What this does not say

It says nothing about accuracy on a real picture. Every vanishing point here is exact because the drawing was made from a camera; on a photograph a vanishing point is fitted from edges that are nearly parallel, and the fit’s conditioning is the whole difficulty. Two rectangles at nearly the same angle give two nearly identical pairs and an involution that is nearly undetermined, exactly as two nearly parallel lines give a badly conditioned intersection.

What one pixel of click error costs, against distanceA 1.83 m object at 3 m is measured to 0.28% per pixel; the same object at 201 m to 18.2% per pixel. The whole object shrinks toward the horizon, so a pixel buys more world.05101550100150200distance from the camera (metres)error in the recovered height, per pixel of click error (%)6 m — 0.55%25 m — 2.27%60 m — 5.43%120 m — 10.84%one pixel, on a 690 px picturelinear in distance
Fig. 21 The general form of that worry. A construction can be exact and multiply a pixel of reading error without bound, and the amplification is a property of the arrangement.

It says nothing about non-square pixels. The identification of the imaginary part with the focal length assumes one focal length rather than two, and the pixel that is not square is what happens when that assumption is wrong.

And it does not replace the box. Three orthogonal directions give three constraints and settle all three camera unknowns; two rectangles on one plane give two, and the third — the height of the centre in the frame — comes from the levelness assumption rather than from the picture. Trading an assumption about the centre for an assumption about the camera being level is a trade rather than a saving, and which one is safer depends on the picture.

The three routes, side by side

It is worth putting the three next to each other, because what they need is more interesting than what they give.

The orthocentre route wants three mutually perpendicular bundles of edges. It gives the focal length and both coordinates of the principal point, over-determined, with a spread that measures how far the object is from being rectangular. It needs a box.

The conic route wants pairs of perpendicular directions, any number of them, in any planes, and solves a linear system for the image of the absolute conic. It is the general statement and the other two are cases of it.

The involution route wants two pairs in one plane and a level camera. It gives the focal length and the horizontal position of the centre, exactly, and says nothing about the vertical position because nothing in one plane’s vanishing line can.

A box drawn from a known camera, and the camera recovered from the drawingThree vanishing points found from the twelve drawn edges alone give back the focal length to 4e-15 relative.recovered principal pointused to drawrecoveredgapfocal length853.90853.904e-15principal x345.0345.02e-12angle44.0°44.0°correct from 20 cm, at 160 mm wide44° across
Fig. 22 The first route’s own quality measure. Three pairs give three focal lengths, and their spread is how far the drawn object is from being a rectangular box — a number the other two routes have no equivalent of.

All three return the same numbers on the same picture, which is the check that keeps them honest, and none of them is preferable in general. What decides is what the photograph happens to contain: a box, several planes, or one floor with two rugs on it.

One more pairing, on a different line

The involution here lives on a horizon and pairs directions at right angles. There is a second one in this collection’s machinery that lives on a pencil rather than on a range, and noticing that the two are the same kind of object is worth a paragraph.

Take a conic in a picture and a point. The lines through the point are a pencil — a projective line’s worth of them — and the conic pairs each line with another: the line and its conjugate, meeting the conic in a pair harmonic with the given point. That pairing is symmetric, so it is an involution of the pencil, and its two fixed lines are the tangents from the point.

The polar of a point, with a straightedge onlyTwo secants through the point cut the conic at four places. The other two diagonal points of the quadrangle they make are joined, and that line is the polar — agreeing with the matrix product to 2.0e-13. No length, no angle, no midpoint: only joins and crossings, which is why the whole construction survives the projection that made this picture.the pointone point, one conicconstructed and computed agree to 2e-13
Fig. 23 The construction that produces it. A point, a conic, and the polar line, built with a straightedge and no measurement, whose relation to the pencil through the point is exactly an involution.

When the point is inside the conic the tangents are imaginary, the involution has no real fixed line, and nothing in the pencil is its own conjugate — which is word for word the situation on the horizon, with a different conic and a different line.

The eight-point rule, on the floorSeven tenths along the real diagonal is on the circle to 2e-15 m. Seven tenths along the drawn one misses it by 54 mm on a circle 2.5 m across, and the drawn one is the only diagonal on the paper.the ruler's markthe plan's markcorrect from 19 cm, at 160 mm wide46° across
Fig. 24 And the practical descendant of that pairing: conjugate diameters of a drawn ellipse, which are what the drawing office’s four-centre constructions are trying and failing to respect.

So the two involutions this collection now uses are the same object twice: a symmetric pairing on a one-dimensional projective space, determined by two pairs, carrying its meaning in a pair of fixed elements that are imaginary exactly when the pairing has no self-conjugate member.

The transferable form

When a correspondence is symmetric, it has one fewer parameter than a general one — so it needs one fewer measurement, and its fixed set carries the meaning.

Symmetry is usually noticed and then not used. Here it is the difference between needing three rectangles and needing two, and between reading two numbers off a fitted map and reading them off a pair of conjugate roots that were already the objects the metric upgrade is made of.

The same move is available wherever a relation pairs things rather than ordering them: reflection in a mirror is an involution of the plane and this site’s own census finds it at a ratio of exactly minus one; conjugate diameters of a conic are an involution on the pencil of directions; and the pole–polar correspondence is an involution on the whole plane. Each of them costs one parameter fewer than the general map it sits inside, and each of them keeps its meaning in a fixed set rather than in a formula.

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.

Absolute conicCamera calibrationCircular pointsdegrees of freedomDemonstrationFixed pointFocal recoveryHorizonInvolutionPrincipal pointProjective lineProjectivityVanishing point