A machine that measures itself
Assumes The coordinates the site already had.
The cheapest calibration there is needs no fixture, no datum, no coordinate machine and nothing brought to the bench. It needs one extra sensor.
The arrangement
A four-bar has one freedom. Put an encoder on the input crank and another on the output rocker.
One freedom and two readings means the machine is over-sensed: at every configuration the two readings are not independent, because the mechanism’s own closure relates them. Every pose therefore produces one scalar equation that the parameters must satisfy, and forty poses produce forty.
That is the whole idea, and its appeal is that the extra sensor is often already there. A machine with a servo on the input and a feedback encoder on the output has both; a machine with position sensing at each end for control purposes has both. Self-calibration is a use for data a machine is already producing.
The equation is Freudenstein’s
The relation between the two angles is exactly the one the applied field has carried since its own phase:
K₁ cos ψ − K₂ cos θ + K₃ = cos(θ − ψ)
with K₁ = g/a, K₂ = g/c and K₃ = (g² + a² + c² − b²)/2ac.
Each measured pose contributes one row with coefficients (cos ψᵢ, −cos θᵢ, 1) and right-hand side cos(θᵢ − ψᵢ). Forty poses give a forty-by-three linear system, and the least-squares solution is the machine’s three invariants.
No iteration, no initial guess, no local minima. The whole identification is one normal-equation solve on a matrix with three columns, and its condition number — which is a property of the poses alone, since the rows do not involve the parameters — comes out at 8.7577 for forty poses spread round the turn.
What it recovers
With exact encoders, the three invariants come back at 8.6 × 10⁻¹⁵ from the truth. That is the arithmetic and nothing else.
With encoders good to a tenth of a milliradian, the error is 5.3 × 10⁻⁴. With encoders good to a milliradian, 5.4 × 10⁻³. Linear in the encoder error with a constant of about 5.4, which is the amplification of this arrangement.
Those three invariants are a complete description of the machine’s shape. Grashof’s class, the transmission angle at every position, the velocity ratio, where the dead centres are, the coupler curve up to similarity — all of it follows, because all of it is a function of the ratios.
So a machine with two encoders knows what kind of machine it is, how well proportioned it is, and exactly what it computes, without anything being brought into the room.
What it cannot recover, ever
Its size.
An encoder reads an angle. Angles are dimensionless in the lengths, so the whole scale null-space argument applies with nothing changed: the three K’s are all that the readings contain, and the fourth parameter is not in them.
The library makes this concrete in an uncomfortable way. Ask the self-calibration for lengths and it needs to be told a ground length. At g = 4 it returns (4, 1, 3.5, 3) — the machine. At g = 1 it returns (1, 0.25, 0.875, 0.75) — a machine a quarter of the size, which fits every one of the forty readings identically.
A self-calibrating machine knows its shape and not its size, and no amount of self-sensing changes that, because every sensor on a one-freedom loop reads an angle.
Two encoders is redundant sensing, not two measurements
Worth being precise about why the arrangement works at all, because put a second sensor on it is not automatically informative.
A mechanism with one freedom has a one-dimensional configuration space. One sensor coordinatises it; a second sensor is then a function of the first, and the function is determined by the machine’s dimensions. Measuring both is measuring that function, and the function is the thing that carries the parameters.
Two sensors on a machine with two freedoms would carry nothing: the two readings would be independent coordinates and any pair of values would be consistent with any dimensions whatever. The information comes entirely from the excess of sensors over freedoms, which is why the term for it is redundant sensing.
That gives the general recipe. Sensors minus freedoms is the number of scalar equations per pose, and a machine with three sensors on one freedom gives two equations per pose rather than one. A platform with more actuators than freedoms is the same idea with the excess counted in legs.
An arrangement the site has already drawn
The four-bar with encoders at both ends is not an exotic instrument; it is the ordinary shape of a function generator in service.
A function generator exists to turn an input angle into an output angle according to some demanded rule. A machine built to do that has an input it is driven at and an output somebody cares about, and both are usually sensed — the input because it is driven, the output because it is the product.
So the equipment is there. What is missing is the arithmetic, and the arithmetic is three columns wide. That is the sense in which self-calibration here is free rather than cheap: no sensor is added, no fixture is built, and the only new thing is a solve that runs in microseconds on data the machine already has.
The one caution is that the machine has to move through well-spread poses to produce a well-conditioned system, and a machine in service may spend its life in a small part of its travel. A crowded pose set is a badly conditioned one whether it was chosen or arrived at by circumstance, and the condition number computed from the data is what catches it.
Why the linear form matters here
Elsewhere in this field an identification is a damped Gauss–Newton descent. Here it is a linear solve, and the difference is worth more in the self-calibrating case than anywhere else.
A self-calibrating machine is one that calibrates itself in service, without supervision, possibly every time it is switched on. That rules out anything with an initial guess, anything that can converge to the wrong basin, and anything that needs a human to look at the residual.
A three-column least squares has none of those failure modes. It has one answer, the answer is a closed-form expression in the data, and the only way for it to fail is for the design matrix to be rank-deficient — which happens when the poses are too few or too crowded, and is detectable by computing a determinant.
That is a genuine engineering advantage rather than an aesthetic one. The property that makes an identification safe to automate is linearity, and Freudenstein’s elimination happens to supply it for the one-freedom planar loop.
The condition number is about the poses only
An unusual and useful feature of this arrangement.
The design matrix’s rows are (cos ψᵢ, −cos θᵢ, 1). Both angles are measured, so the rows depend on the data and not on the parameters — which means the conditioning can be computed from the readings themselves, with no model at all.
That has a practical consequence. A machine self-calibrating in service can compute its own condition number from its own data and refuse to update its parameters when the poses it happened to visit were not well spread. It is a self-check with no external reference, and it costs a three-by-three determinant.
Compare that with a non-linear fit, whose conditioning depends on the parameter estimate and therefore on the answer being sought. The circularity there is harmless in practice and it is not nothing; here there is none.
The residual is a check on the encoders
One more thing the arrangement gives for free.
The system is over-determined by a factor of thirteen, so the residual is a real quantity. With perfect encoders it is zero. With encoders of a stated precision it settles at that precision, and a residual larger than the encoders’ specification means something else is wrong.
What “something else” can be is a short list and every item is useful. An encoder has slipped or been remounted. A pin has worked loose, so the mechanism is no longer the four-bar the equation describes. Or the mechanism has a clearance large enough to matter, in which case the two angles are related by a band rather than by a curve and the residual measures the band.
A machine with two encoders on one freedom has a permanent, free self-test, and the test is running whenever the machine is.
The condition number of eight point seven six
The number deserves a sentence, because it is unusually good and the reason is structural.
The design matrix’s three columns are cos ψ, −cos θ and 1 evaluated at the measured poses. Over a full turn, cos θ and cos ψ each sweep their full range and the constant column is a constant, so the three columns are about as unlike each other as three columns of that shape can be. Forty poses spread round the turn give 8.7577.
Compare with the four-bar’s own identification Jacobian in length space, whose condition number over the recovered directions is 5.2 — better, but on a different matrix in different units, so the two are not directly comparable. What is comparable is the stability: the linear system’s conditioning barely moves with the noise level, reading 8.7577, 8.7566 and 8.7464 at zero, a tenth of a milliradian and a milliradian.
That last row is the useful one. The conditioning is a property of where the machine went, and where the machine went is measured, so the number is known exactly rather than estimated. It is one of very few quantities in this field that carries no model uncertainty at all.
Where it does not extend
Two limits, and both are structural rather than practical.
It needs redundancy. A one-freedom loop with one sensor gives no equations at all — the reading is whatever the input is, and it constrains nothing. The whole method rests on having more sensors than freedoms, and a machine that does not is not self-calibrating in any amount.
And the linearity is a four-bar’s. A six-bar’s input–output relation does not eliminate into anything linear in a small set of coefficients, so a six-bar with two encoders is self-calibrating by an ordinary non-linear fit with all of that fit’s failure modes. A platform with more actuators than freedoms is the case where self-calibration is most used in practice and least like this one — the equations are the leg-length closures and there are many of them, and the fit is thoroughly non-linear.
So this essay’s arrangement is the pleasant special case rather than the general method. It is worth having as the special case because it shows exactly what self-calibration can and cannot do, with nothing hidden in an iteration.
Calibrating in service, and what changes
The arrangement’s real appeal is that it can run continuously rather than as an event, and running continuously changes what a calibration is for.
A calibration done once, at commissioning, produces a set of numbers that are correct on that day. A machine that self-calibrates every hour produces a sequence, and the sequence carries information the single measurement cannot: whether the machine’s shape is drifting, how fast, and in which parameter.
That is a genuinely different product. The three invariants moving by a thousandth over six months says something is wearing; a step change says something has been disturbed. Neither is visible in a one-off calibration however careful it was.
Nothing about the arithmetic changes — it is the same three-column solve on each batch of poses. What changes is that the answer becomes a time series, and a time series of a quantity known to a few parts in ten thousand is a monitoring instrument as well as a measurement.
The one thing it cannot monitor is the size, which does not move much anyway and would need a sensor that reads a length to see.
A machine that cannot check its own encoders
One limit of self-sensing that no amount of arithmetic reaches, and it is worth naming because the arrangement sounds self-sufficient.
The residual tests the two encoders against each other through the mechanism. It cannot test them against the world. Two encoders that are each wrong by the same scale factor — both reading in units 0.2% too large, because the same manufacturing error affected both — produce readings that satisfy the closure relation of a slightly different machine, exactly and with no residual.
What comes back is then the shape of a machine that does not exist, with a perfect self-test. The failure is invisible from inside, for the same reason the size is: the machine has no access to anything outside itself.
A self-calibrating machine is self-consistent rather than correct, and the two are different claims. The gap between them is closed by one external check, made once when the machine is assembled, of one encoder against one reference — which is the same shape of answer as the missing size, arriving for the same reason.
What it shares with the rest of the field
Three properties, and putting them together is the reason this essay sits where it does rather than at the end.
Its recoverable set is the same three invariants everything else in this field recovers from angle data. Its missing direction is the same scale direction. And its amplification — about 5.4 — is bigger than the 1.90 of an external protractor on thirty chosen poses, because the poses a machine visits in service are not chosen and the linear form in K-space weights the residual differently from the angle-space fit.
So self-calibration is not a different method with different properties. It is the same identification with the instrument moved inside the machine, and every result in this field applies to it unchanged. That is worth knowing before designing one: the questions to ask are the same questions, and they are all answered by the same three-by-three matrix.
What a machine has to do to be self-calibrating
Collecting the conditions, because add a sensor is not the whole of it and a designer deciding whether to build this needs the list.
More sensors than freedoms. One excess sensor gives one scalar equation per pose. That is the whole source of information and there is no substitute for it: a machine with exactly as many sensors as freedoms produces no equations, whatever it does.
A closed loop. The equation comes from the mechanism’s own closure, so an open chain with sensors at every joint produces nothing — its joint angles are independent and any set of them is consistent with any dimensions. That is why a serial arm cannot self-calibrate from joint sensing alone, and why a serial arm’s calibration always involves an external instrument or an added constraint such as touching a fixed point.
Travel that visits well-spread poses. A machine that spends its life in ten degrees of its travel produces a design matrix whose rows are nearly parallel, and the answer is dominated by the noise. Whether a machine in service satisfies this is a fact about its duty cycle rather than about its design, and it is checkable from the data.
And a mechanism the model describes. The equation is a four-bar’s. A machine with enough clearance for the loop to be a band rather than a curve does not satisfy it, and the residual will say so — which is useful and is not a calibration.
Four conditions, all checkable in advance except the third, which is checkable continuously.
The instrument is inside the boundary
One reason this arrangement belongs on this site rather than reading as instrumentation, and it is the same test the boundary essay applies to everything else.
Every input is readable. An encoder count is a number, the mechanism’s closure is geometry, and the three coefficients that come out are functions of link lengths. Nothing is a material property, nothing needs a coefficient somebody measured on a different machine, and every claim can be checked by anybody who has the two encoders’ outputs.
That is not true of most self-calibration in the wider literature, which frequently leans on models of the sensors themselves — eccentricity, quadrature error, interpolation nonlinearity — each of which is a property of a device rather than of a geometry. Those are real and they are outside what this site can assert.
So the arrangement here is the geometric core of self-calibration with the instrument modelling removed, and what is left is exactly what a mechanism’s own closure determines. That is a smaller claim than a commercial self-calibration makes and it is one that can be checked.
What to do about the size
The honest options are three and they are all cheap.
Measure one length once. A rule across the frame bar, on the day the machine is assembled, recorded. The machine then knows its shape from its own sensors for ever and its size from one number that does not change.
Or report the shape. Three invariants, and a note that the lengths quoted assume the drawing’s ground length. That is what the report on any angle-only calibration should say and it is exactly as true here.
Or add a sensor that reads a length. A linear encoder somewhere, a distance sensor, anything whose reading has a dimension. One is enough — the missing direction is one-dimensional — and after that the machine is fully self-calibrating including its size.
The one option that is not honest is to print four lengths and say nothing. A self-calibrating machine that reports its own dimensions is a very persuasive source of a number, and three of its four numbers are measurements.
About the same objects
Not linked from either essay — found by the objects both name.
- A calibration is a synthesis with more equations calibration · freudenstein equation · freudenstein invariants · least-squares
- Four indices, four answers calibration · identifiable · least-squares · noise amplification
- How many poses are enough calibration · identifiable · least-squares · noise amplification
- Two instruments disagree about the worst calibration · identifiable · least-squares · noise amplification
- A dimension is a measurement calibration · identifiable · least-squares
- A number that runs away calibration · identifiable · noise amplification
What links here
Essays that link to this one from their own argument.
- A platform that measures itself Several legs, one platform
- A wheel that cannot report its radius Wheels, and where they may not go
- An arm's parameters and its poses One path to the tool
- The direction no protractor can see Numbers that were measured
- What this field cannot measure Numbers that were measured
The objects this essay names
Each one links to every other essay that touches it.
CalibrationFreudenstein equationFreudenstein invariantsIdentifiableLeast-squaresNoise amplificationScale invarianceSelf-calibration