Series

Compute — the series

16 essays on one idea, from the one that introduces it to the one that assumes the rest.
  1. What the machine draws, against where the polynomial vanishes. Two objects, found two ways. The thin line is the set where x^4 + 2x^2y^2 + y^4 − 1.2x^2 + 1.2y^2 is zero, walked over a grid with no mechanism involved. The marks are where the compiled machine's tracing point went, one per converged solve, over the 147 positions of its working arc. The machine's constraint set never mentions the polynomial, so evaluating it at each traced point is an independent check: the worst value over the whole arc is 3.7e-13. The arc is 1.30 radians of the driving angle and not the whole turn, and past that arc it draws something else.

    A demand that is an equation

    Every field on this site is handed its demand geometrically — three positions, a sampled path, a ratio at each angle — and hands back a mechanism that is right at those places and approximately right between them. This one is handed a polynomial, and the mechanism that comes back satisfies it everywhere it moves.

    part 1 · computing
  2. Two routes to the same number, along one sweep. The polynomial x^4 + 2x^2y^2 + y^4 − 1.2x^2 + 1.2y^2 evaluated at the tip of the arm as the second angle goes right round, by two routes that share nothing: once by putting the tip's coordinates into the polynomial, and once by adding up 5 cosines of whole-number combinations of the two angles. The two curves are drawn on top of each other and the worst gap between them is 8.9e-15. Where the line crosses zero is where the machine may stand: 2 crossings at this α, which is how many assemblies the compiled machine has at this driving angle.

    Every curve is a sum of cosines

    Put the two angles of a two-link arm into any polynomial in x and y and what comes out is a constant plus a finite sum of cosines of whole-number combinations of them. Nine curves, three hundred random angle pairs each, and the two routes agree to 1.8 × 10⁻¹⁴.

    part 2 · computing
  3. What each curve costs, in cosines. Every polynomial in the two arm angles is a constant plus a sum of terms A cos(mα + nβ + φ) with whole-number m and n, and the number of those terms is what a machine has to build. The count is not the degree and not the monomial count: a circle costs one term, a general line two, and a lemniscate — degree four — costs five, fewer than the cubic above it, because its symmetry cancels frequency pairs the cubic keeps. Each row's expansion was checked against a direct evaluation of its own polynomial at random angles, worst disagreement 1.8e-14.

    A circle costs one term

    A line expands to two cosines, a circle to one, a general conic to six. A lemniscate is degree four and costs five; a general cubic is degree three and costs eight. What a curve costs is not its degree — it is how many frequency pairs its own symmetry fails to cancel.

    part 2 · computing
  4. the reflector, solved. A rhombus whose far vertex is held on a line through the pivot. One side is the input, the line is the mirror, and the other side comes out reflected in it — which is where negation, doubling and addition all come from. The relation it satisfies is (μ, θ) ↦ 2μ − θ, and across a sweep of 41 positions the worst departure from it is 1.3e-13 radians. Every joint here is the output of a Newton–Raphson solve on the bar lengths; nothing is placed by the formula the picture is about.

    Four bars that add two angles

    A rhombus on two links from one pivot points along the bisector of their angle, exactly, because a rhombus has equal sides. Hold its far vertex on a line and it reflects instead. From those two facts come negation, doubling and addition — and every whole-number combination of two angles a compiled machine needs.

    part 3 · computing
  5. How much of a compiled machine is computing anything. Each machine's bars split two ways: the ones that build an angle — reflectors, means, rigid offsets, the arm — and the ones that carry a direction from where it was computed to where it is needed. On the smallest machines the arithmetic is nearly all of it. By the quintic the carrying is 80 per cent, and it goes on rising, because the arithmetic grows with the number of terms and the carrying grows with the number of pairs of them. That is the answer to why a universality construction is enormous, and it is not about the algebra being hard.

    A parallelogram carries an angle, and only so far

    A direction computed at the frame is no use where it is needed. A parallelogram carries one from point to point — but only between two points a fixed distance apart, and that single proviso is what makes a compiled machine quadratic in the number of terms and turns most of it into transport.

    part 3 · computing
  6. What it costs to multiply an angle. Multiplying an angle by n is done by doubling and adding — 2k is one reflector applied to k, and 2k+1 is one addition of k's result and the original — so the cost follows the binary expansion of n and not n itself. Eight costs three doublings; seven costs six gadgets, twice as much, for a smaller number. The other line is what a chain of n−1 additions would cost. The difference matters because the highest multiple a curve of degree d needs is d, so the arithmetic in a compiled machine grows like d log d while the carrying grows like d⁴ — which is why the arithmetic is not what makes these machines large.

    Doubling is cheaper than adding

    Multiplying an angle by eight costs three gadgets and multiplying it by seven costs six. The cost of an integer multiple follows the binary expansion of the integer and not its size — which is why the arithmetic in a compiled machine grows like d log d while everything else grows like the fourth power.

    part 4 · computing
  7. The machine compiled from a rectangular hyperbola. xy − 0.5, compiled: 20 bars and 20 joints, painted by what each part is for. The two-link arm at the pivot carries the tracing point; the reflectors and means build each term's angle; the rigid offsets fix the constant φₖ and the amplitude; the translators carry those directions out along the summing chain, whose last vertex is held on a line. That last constraint is the equation. Every joint drawn is the output of a Newton–Raphson solve on 36 equations, converged to 4.2e-16, and the polynomial at the tracing point is 2.2e-16.

    The machine, compiled

    Twenty bars, twenty joints, and one degree of freedom. Every position is a converged solve on thirty-five equations, none of which mentions the polynomial — and the polynomial at the tracing point reads 1.3 × 10⁻¹⁴ across the whole working arc.

    part 4 · computing
  8. Every curve in the catalogue, compiled and counted. The bar count is not a formula: it is the number of bar constraints the compiled mechanism actually carries, asked of the object rather than predicted. A line costs five bars and a quintic four hundred and thirteen, which is the field's central number — exactness is paid for in size. The all-revolute column replaces the one prismatic pair that closes the chain with a Peaucellier cell, which costs seven bars whatever the curve, so it is more than half the machine on a line and a rounding error on a quintic. The last column is the polynomial evaluated at the traced point, worst over each machine's working arc.

    Five bars for a line, four hundred for a quintic

    Nine curves compiled and counted: a line at five bars, a circle at eleven, a lemniscate at fifty, a general quintic at four hundred and thirteen. The growth is a fourth power of the degree, and three quarters of the largest machine is not computing anything at all.

    part 5 · computing
  9. One linkage, two curves. The same bars, the same lengths, the same driving angle — assembled two ways. One trace is where the polynomial vanishes and the other is not: the worst value of xy − 0.5 along the second is 8.7e-1, against 4.7e-14 along the first. Every position on both was solved to 9.5e-14. Nothing about the second linkage is defective; one of its parallelograms is a crossed one, so a direction is being carried wrongly, and the machine is faithfully computing a different function.

    The proof drew more than the curve

    Sixteen ways to assemble one linkage. Eight of them close. Four put the tracing point on the curve and four put it somewhere else — at a closure residual of 9.6 × 10⁻¹⁵, which is the same floor the right ones reach. No tolerance on the closure could ever have told them apart.

    part 5 · computing
  10. A brace is one redundant equation, on purpose. The compiled machine, counted and measured, with and without 4 braces. The count says the braced machine has -3 degrees of freedom — it cannot move — and the rank of the constraint Jacobian says it has 1, the same as before. Every brace contributes exactly one equation the others already imply, which is what overconstraint is, and here it is being added deliberately: the redundancy is what removes the assemblies the count knows nothing about. This is Grübler being wrong for the useful reason rather than the embarrassing one.

    A bar between two midpoints

    In a parallelogram the midpoints of two opposite sides are exactly one side apart, and in the crossed assembly they are not. One bar between them admits the first and refuses the second — and it is one redundant equation per parallelogram, added on purpose, on a site whose constraint field is otherwise about overconstraint arriving by accident.

    part 6 · computing
  11. What a singularity does, and what it does not do. The reflector driven straight through the configuration at which its two placements merge — here θ = 0.800, where the rhombus flattens onto its own mirror. Two numbers are plotted. The closure residual is how well the bars are satisfied, and it does not move: 8.3e-14 on both sides. The departure is how far the output is from the angle the gadget is supposed to produce, and it goes from the floor to order one at 0.800. Nothing breaks. The gadget goes on being a perfectly good linkage and stops being the function it was built to be.

    Where the machine stops being the function

    Drive a reflector through the angle at which its rhombus flattens and it comes out computing something else. Nothing breaks: every bar is the length it was, the closure residual stays at 8 × 10⁻¹⁴, and the machine goes on turning. That is why every compiled machine in this field works over an arc and not a turn — the quintic's over a tenth of a radian.

    part 6 · computing
  12. Exactness is not bought with links. Five straight-line mechanisms, each measured over its own working arc — walked out to its dead centres and back a tenth — and each plotted at its own bar count. Watt's four bars are wrong by 9.0 per cent of the stroke and Chebyshev's by 12.4; Peaucellier's seven are exact. There is nothing in between, and adding bars to an approximation does not walk down the axis: the compiled machine is exact for the same reason Peaucellier is — an exact algebraic relation — and its extra bars buy generality rather than accuracy.

    Exact costs more than close

    Watt's four bars are wrong by nine per cent of their stroke and Chebyshev's by twelve. Peaucellier's seven are exact to 4 × 10⁻¹⁶, and a compiled machine is exact to 4.8 × 10⁻¹⁴ in five. There is nothing in between — adding bars to an approximation does not walk down the axis, and the four-bar in every beam engine ever built is on the wrong end of it.

    part 7 · computing
  13. Bars against terms, over the whole catalogue. One mark per compiled machine. The bar count rises much faster than the term count, and the reason is the summing chain: term k has to have its direction carried to the k−1th vertex of the chain, one parallelogram per hop, so the carrying costs a translator for every pair of terms. Nine curves, from five bars to four hundred and thirteen, on a term count that goes from one to eighteen.

    What universality is worth

    The linkage exists, it is four hundred and thirteen bars, and it draws ten degrees of its curve. All three are true and only the first is in the theorem — which is the ordinary shape of a result about what exists, and the reason it was worth building one to find out.

    part 7 · computing
  14. A rectangular hyperbola, compiled from a multiple of its equation. The machine compiled from p · (1 + x² + y²) for a rectangular hyperbola, with the translators — the parallelograms that carry a direction from where it is produced to where it is needed — in their own colour. The factor 1 + x² + y² is at least one at every real point, so every equation here vanishes on exactly the same curve. The machines do not agree: 20 bars at p, 75 bars at p · (1 + x² + y²), 144 bars at p · (1 + x² + y²)². This one solves 29 positions over an arc of 0.508 radians, and at every one of them the original polynomial reads 4.93e-14.

    The price is on the equation

    A line costs five bars. The same line, written as its own equation multiplied by a factor that is never zero, costs fifty — and the machine compiled from the longer equation draws the same line just as exactly. Every cost this field quotes belongs to a polynomial and not to a curve, and the cheapest equation of a given curve is a quantity nobody here has.

    part 8 · computing
  15. Two circles, one term. The curve r² = 1.44 together with r² = 2.56, whose squared radii sum to 4.00 — four times the square of the arm's link length. Their product equation expands to 1 term, which is what either circle costs on its own, so the second circle is free. The machine compiled from it has 17 bars against 11 for the single circle, runs over 5.200 radians against 1.560, and stays on the outer component throughout: its radius varies by 4.15e-13 over 240 solved positions. A mechanism moves continuously and the two circles are disjoint, so no assembly of it reaches both.

    Two circles for the price of one

    Search every multiple of a curve's equation by a polynomial of degree two and the cheapest is the curve's own equation, on four curves and by exhaustion. On the circle a second multiplier ties — and what it describes is two concentric circles, whose squared radii sum to four times the arm's link length squared, at exactly the cost of one.

    part 9 · computing
  16. The machine compiled from a rectangular hyperbola. xy − 0.5, compiled: 20 bars and 20 joints, painted by what each part is for. The two-link arm at the pivot carries the tracing point; the reflectors and means build each term's angle; the rigid offsets fix the constant φₖ and the amplitude; the translators carry those directions out along the summing chain, whose last vertex is held on a line. That last constraint is the equation. Every joint drawn is the output of a Newton–Raphson solve on 36 equations, converged to 4.2e-16, and the polynomial at the tracing point is 2.2e-16.

    A compiled machine and its own scale

    A linkage compiled from a polynomial has bars whose lengths are the polynomial's coefficients and joints whose angles are its phases. Scale it and every coefficient scales — so the machine computes the same polynomial multiplied by a constant, which is a different polynomial with the same roots.

    part 14 · computing

All series