The answer that depends on the machine

An inner product with no fixed sign

‖QᵀQ − I‖ is how this site turns "orthogonal" into a number, and across ten partitionings it moves by 2.4%. The entries it is built from are not so lucky: 125 of the 1,128 off-diagonal pairs take both signs, and one of them takes five different values including zero.

Worth reading first: Orthogonal is a number · The same program, twice.

Orthogonal is a number is the essay this collection is built on. Its argument is that orthogonal should stop being an adjective: measure ‖QᵀQ − I‖, print it beside the figure, and two algorithms that are the same algebra written in a different order stop being equally good and start returning 10⁻¹⁵ and 1.

The measurement is an inner product of two columns whose true value is zero — which the vector that hides it puts at κ = 7.4·10¹⁵, the worst end of the census. So the obvious question, asked of the site’s own instrument: what does it do when the reduction computing it is divided differently?

An inner product whose sign is a property of the thread countTwo columns of a 48 × 48 orthogonal factor from a Householder QR of a matrix with κ = 10^8. Their inner product is zero in exact arithmetic and its terms cancel completely, so its summation condition number is 1.09·10¹⁷. The dots are its computed value at ten partition counts, in units of 2.78·10⁻¹⁷: 5 distinct values, on both sides of zero, including exact zeros. Across the whole factor, 125 of the 1128 off-diagonal pairs have a sign that is not a property of the matrix. And the aggregate is fine: ‖QᵀQ − I‖ over the same ten partitionings moves by a factor of 1.0243, because a norm of 2304 independently rounded quantities averages their disagreements away. Report the norm; never read one entry.110¹-101pieces the inner product was summed inqᵢᵀqⱼ ÷ 2.78·10⁻¹⁷the true valuethe norm and its partsdistinct values5of runs10pairs with no fixed sign125of pairs1128κ of this inner product1.1·10¹⁷‖QᵀQ − I‖ moves by1the aggregate is stableand no entry of it is
Fig. 1 One inner product of two columns of a 48 × 48 Householder factor, computed at ten partition counts, in units of the rounding. The line at zero is the true value.

Five distinct values, on both sides of zero, and several of them exactly zero — a computed quantity whose sign is decided by how many workers were available. Across the whole factor, 125 of the 1,128 off-diagonal pairs — one in nine — have a sign that is not a property of the matrix.

And the norm is fine

Here is the other half, and it is the field’s one genuinely reassuring result.

‖QᵀQ − I‖_F over the same ten partitionings moves by a factor of 1.0243. Two and a half per cent, and between 1.015 and 1.030 across the whole sweep of conditionings. Every figure on this site that prints an orthogonality residual is printing a number whose leading digit and whose order of magnitude are properties of the factorisation rather than of the machine.

The reason is aggregation. The norm is a square root of a sum of 2,304 squared entries, each of which the partitioning perturbs independently and in an unpredictable direction. Independent perturbations of many quantities do not accumulate in a norm; they average, and a norm of n² quantities each moved by a relative O(1) moves by a relative O(1/n).

That is the same √n the mechanism essay derives for a reduction’s own error, appearing one level up: where the disagreement comes from shows that a reduction’s roundings average rather than accumulate, and here the entries average rather than accumulate. Both are the same statement about many small independent quantities.

Why an aggregate is not always safe

The rule the previous section is about to state has an exception, and stating it here keeps the rule honest.

A norm averages the disagreements of its entries when the entries are independent and the norm is a sum of their squares. Both clauses matter.

A maximum is not an average. ‖QᵀQ − I‖_∞ takes the largest row sum, which is dominated by a handful of entries rather than by all of them, and inherits their instability in proportion. The site’s own figures use the Frobenius norm nearly everywhere, which is fortunate rather than deliberate.

And the independence fails where the entries share terms. Every entry of QᵀQ is built from the same Q, so a change of partitioning that moves one column’s roundings moves every entry involving that column together. What saves the norm here is that a partitioning perturbs each inner product separately — the reduction is per entry — rather than perturbing the matrix Q itself.

Change that and the conclusion changes. If the partitioning had moved the factorisation instead of the check — if Q itself had been computed differently — the perturbations of the entries would be correlated, the averaging argument would fail, and the norm would move by more. That is the situation a genuinely parallel QR is in, and it is why a reduction that changes the order measures a different ‖QᵀQ − I‖ for a tree factorisation than for a sweep — 1.65·10⁻¹⁵ against 9.95·10⁻¹⁵, a factor of six, from two algorithms rather than from two partitionings of one.

So: an aggregate of independently perturbed quantities is stable, an aggregate of jointly perturbed ones is not, and the difference is whether the machine changed the reduction or the algorithm.

The rule this yields

The two halves together give the field’s sharpest practical rule, and it is short enough to be remembered:

Report the norm. Never read one entry.

An aggregate over many independently rounded quantities is stable to a few per cent. A single one of them is not stable at all, and if it is near zero it is not stable in sign.

That rule has consequences beyond orthogonality checks, because a great deal of numerical software reads exactly one entry:

A componentwise backward error asks which equation is worst satisfied, which is a maximum over entries rather than a norm of them — accurate is not a property of a method makes the case that componentwise measurements are the sharper ones, and they are. They are also the ones whose answer moves.

A pivot search takes a maximum over a column, which is a comparison between entries, and two entries that differ by less than their own disagreement can swap order.

A convergence test on the largest residual component rather than on the residual norm is the same thing again.

And a check for exact orthogonalityis qᵢᵀqⱼ zero — is a sign test on the quantity in the hero figure, which is the case with no room at all.

What the figure is showing, exactly

Worth spelling out, because the vertical axis is in units of the rounding and that is easy to misread as a normalisation trick.

The two columns are orthonormal to the accuracy a Householder factorisation delivers, which is 1.8·10⁻¹⁵ in the norm and about 10⁻¹⁷ per entry at this size. Their exact inner product — the sum of the 48 products, computed by an expansion that does not round — is not zero either: the columns are orthogonal in exact arithmetic only if Q is, and the computed Q is orthogonal to the rounding level.

So there are three quantities in play and only two of them are on the figure. The true inner product of the columns as stored, which the expansion gives; the computed value at each partitioning, which is what is drawn; and zero, which is what the algebra says and neither of the first two is.

The figure’s line at zero is the algebra’s value. The dots are ten answers to a question whose correct answer is 2.8·10⁻¹⁷ of one thing or another, and the disagreement between them is the same size as the answer.

Where the zeros come from

Three of the ten values in the hero figure are exactly zero, which looks like an artefact and is the clearest evidence in the field that the picture is arithmetic rather than noise.

An inner product of two orthonormal columns is a sum of 48 products, each about 1/48 in magnitude, whose exact total is zero to within the rounding of the vectors themselves. The computed value is therefore a sum of roundings, and roundings are multiples of the spacing at the scale they were committed — here 2⁻⁵⁴ or thereabouts. So the computed value is a small multiple of 1.39·10⁻¹⁷ — half the largest value in the figure — and the ten partitionings return −1.75, +2, +1, −2, 0, 0, +1, 0, 0 and 0 of them.

Zero is not a special outcome; it is one of the four or five values available, and it occurs when the roundings happen to cancel. What it means for a caller is worse than a nonzero answer would be: a test asking are these columns exactly orthogonal returns yes on three machines of ten and no on the other seven, and the seven disagree about the direction of the failure.

This is the same quantisation the numbers below the smallest one meets at the other end of the range, where the representable numbers are a lattice rather than a continuum. Near zero every computed quantity is a lattice, and a comparison with zero is a question about which lattice point a set of roundings landed on.

What the sweep does not show

The drag runs the conditioning of the matrix from 10² to 10¹², and the picture barely changes: the entries stay at the rounding level and about a ninth of them keep no sign at every stop.

That is a fact about the factorisation rather than about this field. A Householder QR’s loss of orthogonality is flat in κ — 1.8·10⁻¹⁵ across eleven decades, which is the measurement orthogonal is a number is built on and the reason the method is recommended. So there is nothing for the conditioning to degrade: the entries were always at the rounding level and the rounding level is where the partitioning has its say.

Run the same measurement on classical Gram–Schmidt and the picture is different in an instructive way. Its ‖QᵀQ − I‖ on this matrix is 1.179, and it is 1.179 at every partitioning to four figures — because the loss of orthogonality there is a real quantity, produced by the algorithm and enormous compared with any rounding, so a change of reduction cannot move it. The disagreement is visible only where the quantity is small.

That is worth stating as its own observation. A badly behaved computation returns a stable wrong answer; a well behaved one returns an answer whose last digits belong to the machine. Reproducibility and quality are, once again, not the same axis — and here they point in opposite directions.

How many entries, and why one in nine

The count — 125 of 1,128 — deserves a sentence, because it is neither one nor all and both of those would be easier to explain.

An off-diagonal entry of QᵀQ has a true value at the rounding level and a computed value that is a few multiples of the local spacing. Whether two partitionings put it on opposite sides of zero depends on whether its typical magnitude is comparable with the disagreement between them: an entry that comes out at eight multiples of the spacing has room to move by two without changing sign, and one that comes out at one multiple does not.

So the fraction with no fixed sign is the fraction whose computed value is within the run-to-run disagreement of zero, which for a distribution of entries spread over a few multiples of the spacing is a fraction of order one in ten. Measured across the drag’s six conditionings it stays between 8.3% and 11.1% — 94, 95, 110, 112, 120 and 125 pairs of 1,128 — while the matrix being factorised changes by ten orders of magnitude in its condition number. That stability is what makes it a statement about the arithmetic rather than about this matrix.

The number to carry is not 125. It is that about a tenth of the entries of a computed orthogonality residual have no determined sign, on any matrix, at any conditioning, in this precision.

What this does to the site’s own figures

The honest accounting, since this collection prints orthogonality residuals on dozens of pages.

The values drawn are stable, because the builds are serial. Every figure here is computed in one process, in one order, from a seeded stream, and the build’s own check that a rebuild reproduces the deployed content hash would fail if any of them moved. The site is in the corner of accuracy and agreement are different properties’s table where the order never changes, so the question never arises.

A reader reproducing them in a threaded environment should expect the norms to agree — they are aggregates, stable to a few per cent — and should not expect an entry to agree at all. Where a figure draws the matrix QᵀQ entry by entry, as orthogonal is a number’s companion does, the individual numbers shown are one machine’s.

And the claims are unaffected, because every claim on this site is about an order of magnitude or a ratio: classical Gram–Schmidt loses orthogonality like κ² and modified like κ, Householder is flat at 10⁻¹⁵. Those are statements about slopes across decades, and a 2.4% wobble at each point does not touch them.

That last paragraph is the general answer to does this invalidate anything. It does not, and the reason is worth carrying: a claim stated as an order of magnitude survives the machine, and a claim stated to three digits does not. This site’s habit of quoting a fitted exponent — 1.95 for the squaring, 0.93 after a second pass — is a habit that happens to be robust to the field it did not know about.

The instrument that measures the instrument

There is something slightly recursive about this essay and it is worth naming rather than leaving as a discomfort.

This collection’s method is to measure rather than assert: an adjective becomes a number, the number is printed on the figure, and a gate refuses a figure that draws a factorisation without one. The essay above takes that instrument and measures it, and finds that its aggregate is trustworthy to two and a half per cent and its parts are not trustworthy at all.

Two responses are available and only one of them is right.

The wrong one is to conclude that measurement is undermined. It is not: the norm is stable, the claims are about slopes across decades, and the whole apparatus does what it was built to do. A measurement with a known 2.4% variability is a measurement, and knowing the figure is better than assuming it is zero.

The right one is that an instrument needs its own error bar, and this collection has been printing residuals without one for nineteen fields. Not because anybody was careless — the variation is invisible on a serial build, which is what every figure here is — but because the question was never asked. Printing κ of the inner product beside ‖QᵀQ − I‖ would be the honest form, and it costs one pass.

That is the same move the site made when it stopped saying orthogonal and started printing a number. The number needs a number.

The one measurement that would be worth adding

If the site were to print one more number beside its orthogonality residuals, it would not be a reproducibility figure. It would be κ of the inner product — Σ|qᵢₖqⱼₖ| divided by the computed value — which is one pass, says how much of the printed number is rounding, and would have made this whole essay a footnote rather than a discovery.

At κ = 10¹⁶ the number printed is entirely rounding and its digits mean nothing; at κ = 10² it is a measurement. Both appear in this collection, and nothing on the page distinguishes them.

One line

The site’s signature measurement survives a change of machine because it is a norm of two thousand independently rounded quantities; the quantities themselves do not, and one in nine of them has no determined sign.

At other settings

An inner product whose sign is a property of the thread countTwo columns of a 48 × 48 orthogonal factor from a Householder QR of a matrix with κ = 10^2. Their inner product is zero in exact arithmetic and its terms cancel completely, so its summation condition number is 6.79·10¹⁶. The dots are its computed value at ten partition counts, in units of 2.78·10⁻¹⁷: 6 distinct values, on both sides of zero, including exact zeros. Across the whole factor, 112 of the 1128 off-diagonal pairs have a sign that is not a property of the matrix. And the aggregate is fine: ‖QᵀQ − I‖ over the same ten partitionings moves by a factor of 1.0181, because a norm of 2304 independently rounded quantities averages their disagreements away. Report the norm; never read one entry.110¹-101pieces the inner product was summed inqᵢᵀqⱼ ÷ 2.78·10⁻¹⁷the true valuethe norm and its partsdistinct values6of runs10pairs with no fixed sign112of pairs1128κ of this inner product6.8·10¹⁶‖QᵀQ − I‖ moves by1the aggregate is stableand no entry of it is
Fig. 2 At κ = 100, where the factorisation is easy and the entries are still at the rounding level.
An inner product whose sign is a property of the thread countTwo columns of a 48 × 48 orthogonal factor from a Householder QR of a matrix with κ = 10^12. Their inner product is zero in exact arithmetic and its terms cancel completely, so its summation condition number is 2.16·10¹⁹. The dots are its computed value at ten partition counts, in units of 6.94·10⁻¹⁸: 4 distinct values, on both sides of zero, including exact zeros. Across the whole factor, 94 of the 1128 off-diagonal pairs have a sign that is not a property of the matrix. And the aggregate is fine: ‖QᵀQ − I‖ over the same ten partitionings moves by a factor of 1.0150, because a norm of 2304 independently rounded quantities averages their disagreements away. Report the norm; never read one entry.110¹-101pieces the inner product was summed inqᵢᵀqⱼ ÷ 6.94·10⁻¹⁸the true valuethe norm and its partsdistinct values4of runs10pairs with no fixed sign94of pairs1128κ of this inner product2.2·10¹⁹‖QᵀQ − I‖ moves by1the aggregate is stableand no entry of it is
Fig. 3 And at 10¹², where the Householder factor is still orthogonal to 10⁻¹⁵ and its entries still have no fixed sign.
Loss of orthogonality against condition number, in binary64A log–log plot of the norm of Q-transpose-Q minus the identity against condition number. Classical Gram–Schmidt rises steeply, modified Gram–Schmidt rises gently, and Householder is flat.110²10⁴10⁶10⁸10¹⁰10¹²10⁻¹⁷10⁻¹⁴10⁻¹¹10⁻⁸10⁻⁵10⁻²10¹condition number κ(A)‖QᵀQ − I‖classicalmodifiedHouseholderκ²uκu8×8, eight seeds per κ, binary64all three reconstruct A
Fig. 4 The curve those numbers are the points of.
QᵀQ from classical Gram–Schmidt and from Householder on the 8×8 Hilbert matrixTwo eight-by-eight tables of QᵀQ. The upper one has ones on the diagonal and entries as large as one off it; the lower one is the identity to three decimal places everywhere.A = H8 · κ = 1.5·10¹⁰ · both factorisations reconstruct A to 6·10⁻¹⁷the diagonal is 1 in both — every column is a unit vector either way1.000000000001.000000000001.000000000001.000000000001.00000.002-0.002000001.0000.125-0.13300000.0020.1251.000-1.0000000-0.002-0.133-1.0001.000classical Gram–Schmidt1.000000000001.000000000001.000000000001.000000000001.000000000001.000000000001.000000000001.000Householderclassical ‖QᵀQ − I‖1.4Householder ‖QᵀQ − I‖1.4·10⁻¹⁵largest off-diagonal 1 against 3.1·10⁻¹⁶length is not angle
Fig. 5 QᵀQ printed entry by entry, which is the figure this essay qualifies.
Classical and modified Gram–Schmidt: the same subtraction, in a different orderTwo panels of pseudocode differing in one argument, with the resulting pairwise dot products of the computed columns listed beneath each.for each previous column i, subtract the projection of column j onto qᵢclassicalr[i][j] = qᵢ · a[j] ↑ the ORIGINAL columnv = v − r[i][j] · qᵢthe three worst |qᵢ · qⱼ|:columns 7 and 8: 1columns 6 and 8: 0.13columns 6 and 7: 0.13modifiedr[i][j] = qᵢ · v ↑ what is LEFT of itv = v − r[i][j] · qᵢthe three worst |qᵢ · qⱼ|:columns 1 and 8: 4.4·10⁻⁷columns 2 and 8: 2.7·10⁻⁷columns 3 and 8: 2.4·10⁻⁸The two R factors agree to 1.2·10⁻⁶ relative. The two Q factors do not.the 8×8 Hilbert matrixone word, eight orders
Fig. 6 Two orderings of one orthogonalisation, where the difference is the algorithm’s rather than the machine’s.
The summation condition number of six inner products this site already computesκ = Σ|xᵢ| ÷ |Σxᵢ| for six reductions taken from computations elsewhere on this site, at 64 terms: an orthogonality check between two columns of a Q, one component of a residual b − Ax on an ill-conditioned system, a nearly degenerate 2 × 2 determinant, a Hutchinson trace probe zᵀAz, a residual norm rᵀr, and a curvature pᵀAp. The range is 1 to 1.01·10¹⁷. The two at the safe end are sums of squares, where no term can cancel another; the three above 10¹⁰ are the orthogonality check, the residual and the determinant — which is to say every quantity a stopping test, an orthogonality test or an orientation test is written in. The reductions that are reproducible are the ones nobody makes a decision from.κ of the suma component of b − Ax1.01·10¹⁷ad − bc, near-degenerate3.6·10¹⁶qᵢᵀqⱼ, an orthogonality check7.39·10¹⁵pᵀAp, a curvature409zᵀAz, a trace probe41.8rᵀr, a residual norm1measured, not assumedhighest10¹⁷lowest1above 10¹⁰3terms64sums of squares are safeand nobody decides anything from one
Fig. 7 Where this inner product sits among the site’s reductions.
The same 4096 numbers, added up 26 ways, 21 different answersEach dot is one reduction of one vector of 4096 binary64 numbers whose summation condition number is 1.01·10⁸: the vector is cut into p contiguous pieces, each piece summed left to right, and the pieces combined in a tree. The vertical position is the distance from the exactly rounded sum, relative. Filled dots are the static split a fixed thread count gives; open dots are unequal splits, which is what a work-stealing scheduler produces at the same p. 21 of the 26 runs returned distinct values, spanning 1.55·10⁻¹³ — 2.3·10⁷ ulps of the answer. The dashed line is the classical bound γ₍ₙ₋₁₎Σ|xᵢ|, which every one of them satisfies with 2.58·10⁴ to spare, and which is the same number for all of them: it contains n and Σ|xᵢ| and nothing about the order.110¹10⁻¹¹10⁻⁸10⁻⁵pieces the vector was divided intodistance from the exact sum, relativethe published boundκ · uone vector, one algorithmdistinct answers21runs26spread, in ulps2.3·10⁷κ of the sum10⁸bound ÷ worst error2.6·10⁴nobody chose pand no answer is the answer
Fig. 8 The same disagreement on a vector built to show it.
What the runs disagree by, and what the bound says they mightOver ten decades of summation condition number, on vectors of 2048 numbers: the measured spread between seven partitioned reductions of the same vector, the quantity κu, and the classical error bound γ₍ₙ₋₁₎Σ|xᵢ| relative to the sum. The measured spread and κu are one curve times a constant — the ratio runs from 0.253 to 0.258 across the whole sweep, a spread of 1.021 while both quantities move by ten orders. The bound sits 7932 to 8100 above the disagreement and is identical for every ordering, which is what makes it useless for the question a reader actually has: not how wrong is this, but will the next run say the same.10²10⁴10⁶10⁸10¹⁰10¹²10⁻¹⁷10⁻¹⁴10⁻¹¹10⁻⁸10⁻⁵10⁻²10¹κ of the sumrelative sizethe boundκ · umeasured spreadtwo curves and one constantspread ÷ κu, low0.25spread ÷ κu, high0.26bound ÷ spread, low7932decades swept10the spread is computablethe bound cannot see the order
Fig. 9 Its size, and the bound that covers it.
The error of a reduction is a walk, and the number of pieces changes which walkRunning error of two reductions of the same 2048 numbers, against how many terms have been consumed: one accumulator, and 8 pieces combined at the end. Each is the distance between what the arithmetic has accumulated so far and the exact sum of the same terms, carried in a compensated pair so the instrument does not round. The two separate within the first few terms and never meet again, ending at 7.56·10⁻¹⁴ and 2.41·10⁻¹⁴. The mechanism is in the horizontal axis: a rounding is committed at every partial sum and its size is that partial sum's spacing, and this vector's running total reaches 32.1 on the way to an answer of 1.63·10⁻⁵. Dividing the work shortens each walk, so the mean error over eight vectors falls from 4.78·10⁻¹⁴ at one piece to 8.14·10⁻¹⁵ at sixty-four: more workers is more accurate, which is the opposite of what the word *parallel* suggests here.051210241536204810⁻¹⁷10⁻¹⁴terms consumederror accumulated so farone accumulator8 piecesthe steps are the partial sumspeak partial sum32the answer1.6·10⁻⁵error, one piece7.6·10⁻¹⁴error, 8 pieces2.4·10⁻¹⁴mean at p = 648.1·10⁻¹⁵the walk sets the sizeand nothing sets the value
Fig. 10 The mechanism.
Five summation policies, 400 permutations each, and how many answers each returnedThe same 1,024 numbers, summation condition number 10⁸, presented in 400 different orders. The bar is the number of distinct binary64 values the policy returned; the figure beside it is the worst relative error it made. A single accumulator returns 303 values and eight pieces return 72; Kahan's compensated loop is the most accurate of the three at 4.96·10⁻¹⁰ and still returns 119. Pre-rounded summation returns one value, at an error of 4.91·10⁻⁶ — four orders worse than the compensated loop and the same on every machine. Exact accumulation returns one value and the right one. The comparison is bitwise because the claim is bitwise: a tolerance here would pass everything.distinct answersone accumulator303eight pieces72compensated119pre-rounded1exact1worst error 1.17·10⁻⁸worst error 4.61·10⁻⁹worst error 4.96·10⁻¹⁰worst error 4.91·10⁻⁶worst error 0bitwise, or not at allpermutations400one accumulator303pre-rounded1its error4.9·10⁻⁶compensated error5·10⁻¹⁰accuracy and agreement are different propertiesand the accurate one is not the agreed one
Fig. 11 The policy that would give an entry a fixed sign.
Six ways to add up a vector, priced against what they returnBinary64 operations per element on the horizontal axis and relative error on the vertical, for one vector of 2,048 numbers with a summation condition number of 1.05·10⁶. Filled markers are the policies whose answer does not depend on the order the terms arrive in; open markers are the ones whose answer does. The cheapest order-independent policy costs 3 operations an element — a divide, a round and an add — and is 2.29·10⁻⁷ wrong; the most accurate policy here is pre-rounded, two passes at 7. Nothing sits in the bottom left. The cost of an answer that is the same on every machine is between three and twelve times the cost of an answer that is not, and the two-pass pre-rounded policy is the one worth knowing about: seven operations, order-independent, and accurate.02468101210⁻¹⁷10⁻¹⁴10⁻¹¹10⁻⁸binary64 operations per elementrelative errorruntime orderfixed partitionpre-rounded, one passpre-rounded, two passescompensated (Kahan)exact accumulationwhat determinism costsreproducible policies3cheapest, ops/element3its error2.3·10⁻⁷two passes10⁻¹⁷ordinary, 8 pieces2.7·10⁻¹¹nothing is cheap and exactthe middle of the figure is the answer
Fig. 12 And its price.
‖QᵀQ − I‖ of the implied Q, against the condition numberLoss of orthogonality against κ, both axes logarithmic, for three factorisations of the same 256×8 matrix. The column sweep and the reduction tree run from 2.7·10⁻¹⁴ to 1.5·10⁻¹⁰. Cholesky QR — the one with a single reduction — runs from 2.3·10⁻¹³ to 1.8·10⁻⁵, a fitted slope of 1.97 against the others' near-flat one.10²10³10⁴10⁵10⁶10⁻¹⁴10⁻¹²10⁻¹⁰10⁻⁸10⁻⁶condition number κ‖QᵀQ − I‖Cholesky QRsweeptreethe price of one roundfitted slope, Cholesky QR2‖QᵀQ − I‖ at κ = 10·10⁵1.8·10⁻⁵the sweep's, at the same κ1.5·10⁻¹⁰one reduction instead of nand the condition number squared
Fig. 13 The claim this essay does not disturb: a slope across decades.
‖QᵀQ − I‖ at every step of a Lanczos run, n = 40The departure from orthogonality of the Lanczos basis, against the step, on a logarithmic vertical axis. It sits at the level of rounding for 13 steps and then climbs by a factor of about seventeen a step for ten steps running, twelve orders of magnitude, before saturating. The dashed line marks the step at which the first Ritz value converged, which is step 11.051015202530354010⁻¹⁷10⁻¹⁴10⁻¹¹10⁻⁸10⁻⁵10⁻²10¹step‖QᵀQ − I‖first Ritz value converges√uno reorthogonalisationfullthe two events are one eventstep orthogonality crosses √u14step the first Ritz value converges11consecutive steps at ≥5× growth10a drift would grow like a square rootthis grows like a geometric series and then stops
Fig. 14 A loss of orthogonality large enough that no reduction order could move it.
The numerical rank of one matrix is 10, 12, or somewhere betweenSingular values of one 60 × 14 matrix whose spectrum falls by a fixed factor per index, so there is no gap anywhere and the threshold decides the rank. Each curve is the same matrix, its Gram matrix formed with the inner products summed in a different number of pieces. The curves lie on top of each other for the first several values and separate below about 7.3·10⁻¹³, which is where forming AᵀA has put the rounding. The dashed line is the threshold, σ₁ · 10⁻¹⁴. Counting the values above it gives 12 at p = 1, 12 at p = 2, 12 at p = 4, 10 at p = 8, 10 at p = 16, 11 at p = 32, 11 at p = 60 — the rank of one matrix, as a function of how many workers were available. Not a digit of an answer: the number of columns a model built from this matrix would have.13579111310⁻¹⁴10⁻¹¹10⁻⁸10⁻⁵10⁻²10¹index ksingular valueσ₁ · 10⁻¹⁴, the thresholdone matrix, three rankspartitionings7lowest rank10highest rank12threshold7.3·10⁻¹⁴σ₁7.3the curves separate in the noiseand the threshold is drawn through it
Fig. 15 An aggregate of the same kind that is not stable, because a threshold reads it.
Two conforming builds, one matrix, and 26 different verdicts in 200 triesForty 6 × 6 Gram matrices at each of five conditionings, each formed exactly from a tall matrix whose last column is nearly the sum of its first two. Every one of them is asked *are you positive definite* by a Cholesky, once with the inner products accumulated with a single rounding per term and once with each product rounded before it is subtracted. The bar is how many of the forty came back with different verdicts: 7 at 10⁻⁸, 2 at 10⁻⁹, 4 at 10⁻¹⁰, 10 at 10⁻¹¹, 3 at 10⁻¹². The two shaded parts split those by which build was right, settled by the signs of the leading principal minors computed in BigInt rationals — 9 to the fused form and 17 to the rounded one. So neither is the correct implementation. The verdict is a property of the build, and the answer to which build is right is a property of the matrix.-12-11-10-9-8024681012log₁₀ of how nearly dependent the columns areverdicts that disagreed, of 40724103which one is correctmatrices tested200verdicts disagreed26fused was right9unfused was right17lower part: thefused build was righta sign has no last digitso a verdict has nowhere to hide
Fig. 16 And a sign that is read directly.
Two perturbation bounds and the error that was measured, on a 8×8 matrix spread over 8 decades of unitsThree curves against the size of an entrywise relative perturbation. The normwise bound κ_∞·ε is a valid bound and sits 4·10⁷ times above the componentwise one cond(A, x)·ε, which is also a bound and is nearly attained by the worst of forty random perturbations at each size.10⁻¹⁴10⁻¹³10⁻¹²10⁻¹¹10⁻¹⁰10⁻⁹10⁻¹⁵10⁻¹²10⁻⁹10⁻⁶10⁻³1relative size of the entrywise perturbationrelative forward errorκ_∞ · εcond(A,x) · εmeasuredboth bounds holdκ_∞(A)1.9·10⁸cond(A, x)4.8ratio of the bounds4·10⁷both curves above the data are boundsand only one of them is a measurement
Fig. 17 A measurement taken entry by entry, which is the sharper one and the less stable one.
Backward and forward error against the condition numberA log–log plot over twelve decades of condition number. The backward error is a flat line at ten to the minus sixteen; the forward error rises in proportion to the condition number.110²10⁴10⁶10⁸10¹⁰10¹²10¹⁴10⁻¹⁷10⁻¹⁴10⁻¹¹10⁻⁸10⁻⁵10⁻²10¹condition number κ(A)relative errorforward errorbackward errorpredicted: κ · u8×8, 20 seeds per κ; dashed is the worstthe problem worsens, not the method
Fig. 18 The distinction that survives this untouched.
The exact solution of a 13×13 Hilbert system beside the computed oneTwo columns of numbers: the exact answer, which is the integers one to thirteen, and the answer double-precision elimination returns, with the number of correct digits beside each.H13 x = b, b formed exactly so that x = (1, 2, …, 13)12345678910111213exact1.00002.00003.00133.97865.18864.993010.46720.048921.2657-2.575319.21478.906013.5113computed6.6 correct digits4.8 correct digits3.4 correct digits2.3 correct digits1.4 correct digit0.8 correct digitno correct digitsno correct digitsno correct digitsno correct digitsno correct digits0.6 correct digit1.4 correct digitbackward error2.2·10⁻¹⁷κ = 1.7·10¹⁸The algorithm solved a neighbouring problem perfectly. That problem's answer is this one.right-hand side built in BigInt rationalsthe truth is known
Fig. 19 The standing that makes the true value here exactly zero.
One system, one tolerance, and 11 different amounts of workConjugate gradients on a 200 × 200 symmetric positive definite matrix with κ = 10⁴, stopped when the relative residual falls below 10⁻¹⁰, run at each of 13 partition counts. The only thing that differs between the runs is how many pieces the two global inner products were summed in — which on a real machine is the number of workers. Iteration counts run from 674 to 690, 11 of them distinct, a spread of 2.4% of the work. Every run converged and every answer is right to the accuracy asked for; the forward errors span 6.31·10⁻¹¹ to 1.08·10⁻¹⁰, a factor of 1.72. What differs is not a digit at the end of an answer — it is the bill, and it is an integer.110¹670673676679682685688691694pieces the inner products were summed initerations to the tolerance674, the cheapest run690, the dearestthe same solve, pricedpartitionings run13distinct counts11spread, per cent2.4best forward error6.3·10⁻¹¹worst1.1·10⁻¹⁰one matrix, one toleranceand the cost is the machine's
Fig. 20 What happens when a quantity like this one is compared with something.
Relative error of two algebraically identical expressions for (1 − cos x)/x², in binary32A log–log plot of relative error against x. The expression written as it reads loses accuracy as x falls and is eventually wrong in every digit; the rearranged form stays at rounding level.10⁻⁸10⁻⁶10⁻⁴10⁻²110⁻⁹10⁻⁶10⁻³1xrelative error of the computed value(1 − cos x)/x², as written2 sin²(x/2)/x²no digits left at allbinary32 throughoutone function, two spellings · zero below 3.5·10⁻⁴
Fig. 21 The mechanism that puts an inner product of orthogonal vectors at the top of the census.
Forward error of a 6×6 Hilbert solve at eight precisionsA bar for each significand width from 12 to 53 bits showing the relative error in the computed solution, with the condition number times the unit roundoff marked as a prediction.κ = 1.5·10⁷ · the exact answer is (1, 2, …, 6)12 bits3.316 bits0.8620 bits4.324 bits0.09330 bits7.6·10⁻⁴36 bits6.2·10⁻⁶43 bits2·10⁻⁷53 bits4.5·10⁻¹¹dashed: κ · unit roundoffone matrix, eight arithmeticsmeasured against a known answer
Fig. 22 The knob that moves the rounding level and not the fraction of pairs without a sign.

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.

Bitwise reproducibilityGram matrixHouseholder reflectionMatrix normOrthogonality lossReduction orderRun-to-run variationSummation condition number