The sensor fault that vanished in one multiplication
Two temperature probes sit beside the same machine. On a healthy reading they report 40 and 40. During a wiring fault they report 41 and 39. The mean remains 40, so a monitoring pipeline that replaces the pair with their average produces exactly the same output for both states.
Nothing downstream can recover that disagreement from the average. A larger model, a more elaborate rule and a human reviewer all receive the same number. The loss occurred before any of them saw the case. The matrix did not merely calculate a statistic. It decided which difference between possible worlds would remain expressible.
The durable intuition is that a matrix acts on differences. If two inputs differ by a vector d, their outputs differ by Ad. Rotation changes the description of that difference. Stretching changes its magnitude. Mixing redistributes it across coordinates. A null direction sends it to zero. Once this view is adopted, rank, determinant, singular values and conditioning become answers to practical questions rather than isolated definitions.
The operator view is historically faithful as well as useful. Matrices became independent algebraic objects in the nineteenth century, and modern linear algebra treats matrix-vector multiplication as a linear transformation from one space to another.12 Yet the key engineering question is narrower: which distinctions does this particular operator preserve well enough for the next decision?
Part IRead the machine from its columns
A table of numbers encourages an entry-by-entry reading. That is useful for bookkeeping and poor for intuition. Take a matrix with two columns, a1 and a2. The first column is where the horizontal unit direction goes. The second is where the vertical unit direction goes. Once those two destinations are known, linearity fixes the destination of every point in the plane.
Consider the small operator
This minimal example contains the whole mechanism. The unit square becomes the parallelogram spanned by the two columns. Parallel lines remain parallel because the same weighted-sum rule applies everywhere. The origin stays fixed because a linear map sends the zero combination to zero. Straight lines stay straight, although their lengths and angles may change.
Figure 2. the columns are the machine’s handles
Rows ask questions; columns route causes
For an m by n matrix, the dimensions are an interface contract. The machine accepts n input coordinates and emits m output coordinates. Each of its n columns describes the output caused by one unit input. Each of its m rows describes one weighted question asked of the whole input. In the sensor average, the single row asks, “what is the common level?” It never asks, “do the probes disagree?” The missing question is the missing evidence.
This row view is useful whenever a matrix represents measurements rather than motion. A camera pixel, a portfolio factor, a neural feature and a linear sensor channel are all weighted summaries. Two rows that ask nearly the same question add little independent evidence. A row aligned with a required contrast can make that contrast visible even when the original coordinates are inconvenient. The same numbers therefore admit two complementary readings: columns reveal how input causes propagate; rows reveal what the output is capable of observing.
The distinction also clarifies rectangular matrices. A wide matrix with fewer rows than columns must compress an input into fewer reported coordinates. It can still preserve a particular finite set of task contrasts, but it cannot preserve every direction of the full continuous input space. A tall matrix can add measurements, yet duplicated or dependent rows do not create new information. Output width alone is not evidence of independent observation. Rank records the number of genuinely independent directions, while the rows and columns explain where those directions come from.
Matrices become systems through composition. If A transforms raw inputs and B transforms the result, the combined machine is BA. The order matters: BA means “apply A, then B”, and it is generally different from AB. Dimensions enforce the wiring. An output type from one stage must match the input type of the next. This makes matrix multiplication less mysterious: it is the algebra of connecting linear machines.
An affine layer adds a bias, y=Ax+b. Bias moves the whole output cloud but cancels when two cases are compared: (Ax+b)-(Ax′+b)=A(x-x′). It can change whether a later threshold fires, but it cannot by itself restore a distinction already erased by A. This is why difference vectors are the right probe for the present argument. They remove a common offset and expose the part of the layer responsible for preserving separability.
The rule depends on the chosen coordinates, but the underlying transformation does not. Change the input basis and the column values change because the machine is being described with different handles. Change the output basis and the coordinate labels change again. This distinction prevents a common mistake: treating a large coefficient as an intrinsic effect when it may partly reflect units or basis choice.
Linearity is the constraint that makes this compression possible:
That constraint is powerful and severe. A linear map cannot create a bend, a threshold or a context-dependent rule by itself. Neural networks gain non-linear behaviour by alternating matrix operations with non-linear activations. PyTorch’s official definition of a linear layer makes the affine rule explicit as a matrix transformation plus a bias.11 The matrix still controls which local combinations and directions are available to the activation that follows.
Reading columns answers “where do the basis directions go?” It does not yet answer which directions are stretched most, whether any are nearly lost, or how stable an inverse will be. Those questions require a basis-independent view.
Part IIIWhen information disappears
Return to the two probes. Their disagreement is the vector d = (1, −1)T. The averaging matrix sends d to zero. Therefore every pair of readings that differs only by some multiple of d has the same average. The set of all such invisible directions is the null space:
Erasure is an impossibility result, not a weak prediction
Suppose two possible states are x and x′, and the matrix produces the same representation for both: Ax=Ax′. Let g be any downstream procedure that receives only that representation. It may be a rule, a classifier, a language model or a human-facing dashboard. Because its inputs are identical, g(Ax)=g(Ax′). The downstream procedure may guess from prior frequencies, but it cannot base the distinction on evidence that the matrix removed.
This proof isolates the causal burden. Poor downstream performance is sometimes blamed on model capacity, training data or decision policy. Those explanations remain possible when the representations differ. They become insufficient when the relevant cases have collided exactly. The repair must alter the measurement, retain another channel, or provide independent evidence. More computation after the collision changes neither the equality nor the missing information.
The column space gives the companion boundary on outputs. It contains every vector the machine can produce. If a requested output lies outside that space, the equation Ax=b has no exact solution. Least squares can choose the nearest attainable output, but closeness is an optimisation criterion, not proof that the missing component was observed. The null space tells which input variations are invisible; the column space tells which output claims are reachable. Together they define the evidential envelope of the linear machine.3
Near-collision needs a quantitative version of the same argument. Let the observed output be y=Ax+e, where e is perturbation from measurement noise, rounding or upstream error. If two states differ by d, their noiseless outputs differ by Ad. When that separation is no larger than the possible difference between their perturbations, the observed output sets overlap. No deterministic decoder can then guarantee the correct state for every permitted perturbation.
Conditioning describes the global sensitivity of inversion, while task retention describes one declared direction. They answer different questions. A large condition number warns that some direction is fragile, even if the application never uses it. A small value of ‖Ad‖ for a named d warns that this application’s contrast is fragile, even when the global condition number appears acceptable. Global conditioning is a searchlight; task retention is the inspection at the actual fault line.
Figure 5. a null direction makes distinct inputs collide
The rank counts how many independent output directions survive. If an n-dimensional input matrix has rank r, then n−r independent input directions lie in its null space. Software cannot decide numerical rank without a tolerance because floating-point calculations rarely return an exact zero. NumPy’s matrix_rank therefore counts singular values above a threshold tied to the largest singular value, matrix dimensions and machine precision.7
That numerical convention hints at a deeper operating issue. Exact rank asks whether a direction is mathematically zero. A deployed measurement pipeline needs to ask whether the direction remains large relative to noise, quantisation and the downstream decision margin. A singular value of 10−8 is non-zero. If the output is rounded to 10−3, the corresponding distinction has effectively vanished.
Consider a second thought experiment. A press can be set to thickness η. At η = 0 it turns a clay square into a line, so depth is exactly unrecoverable. At η = 0.01 the output is technically a very thin rectangle. In a noiseless world with infinite precision, depth can be recovered by multiplying by 100. Add surface noise of ±0.02, and the attempted inverse amplifies that noise until it dominates the recovered depth. The causal change from 0 to 0.01 restores algebraic invertibility without restoring practical evidence.
NumPy likewise computes the 2-norm condition number from the SVD and warns that an ill-conditioned inverse may be inaccurate even when no singularity error is raised.89 The issue is not an implementation quirk. It follows from the machine’s geometry. Recovering a direction shrunk by a factor of one hundred requires amplification by one hundred, including amplification of whatever perturbation occupies the same output direction.
Figure 6. full rank can still fall below the evidence floor
Exact erasure is a property of the null space; practical erasure is a relation among the matrix, the task and the noise floor. This explains why a single global rank threshold is never enough for high-consequence feature compression. The relevant tolerance comes from units, expected perturbations and the distinction the system must preserve.
There is another boundary. The smallest singular value is a worst-case measure across all directions. A system may safely crush an irrelevant direction while preserving every task-relevant one. Conversely, a matrix with a respectable global condition number can still attenuate the one semantic contrast that matters because the input was poorly scaled or the task direction lies near its weakest axis. That is why the audit must become task-specific.
Part IVAudit the distinctions that matter
Suppose a synthetic equipment-monitoring encoder receives four standardised inputs: temperature probe A, temperature probe B, vibration and pressure. Its first output is the average temperature. Its second is a scaled disagreement channel. The remaining outputs carry vibration and pressure unchanged:
For the task-relevant difference d = (1, −1, 0, 0)T, the transformed difference is (0, η, 0, 0)T. The average channel cannot see it. The disagreement channel carries all of it, scaled by η. If η is learned towards zero because most training rows contain agreeing sensors, a rare fault signature can disappear while average reconstruction or prediction loss remains good.
This is a worked scenario, not a reported deployment. Its purpose is to expose a common causal pattern: an aggregate metric rewards common variation, while an operationally decisive contrast lives in a low-variance direction. The matrix alone cannot tell us which contrast matters. The task definition supplies that information.
Make the contrast set part of the system specification
The four-sensor encoder should not be reviewed as an isolated array. Its specification needs a contrast register. One contrast may represent equal-and-opposite probe drift. Another may represent a one-unit pressure change at fixed temperature. A third may encode an invariance, such as adding the same calibration offset to both temperature probes when only their disagreement matters. Required distinctions should stay separated; declared nuisance variations may be attenuated or deleted.
That register turns an abstract representation claim into tests. For each contrast, record its source, plausible magnitude, units, consequence if lost, and expected behaviour. Run a positive case that must survive, a negative control that may disappear, and a scale test around the operating boundary. Test both signs because a later non-linearity can respond asymmetrically even when the matrix is symmetric. Repeat the calculation after quantisation, export and hardware conversion, since numerical changes can move a marginal direction across the threshold.
Training introduces another comparison. Evaluate the matrix before training, at checkpoints and at release. If a required retention ratio declines while average loss improves, the optimisation objective is buying common-case performance with a hidden loss of evidence. That is not automatically wrong. It is a decision that needs an owner. Possible responses include an auxiliary contrast loss, a constrained singular floor on a protected subspace, a skip connection, a wider bottleneck, or an explicit deterministic channel outside the learned compression.
The last option is often the clearest. If probe disagreement has a fixed operational meaning, compute it directly and carry it beside the learned features. A neural representation can still model complex interactions without being the sole custodian of a simple high-consequence signal. This is the same placement discipline used elsewhere in reliable systems: keep a deterministic fact in a typed channel when its semantics and calculation are stable, and use learning for the residual uncertainty.
Figure 7. the average survives while the fault direction fades
A useful audit starts with difference vectors rather than raw examples. Each vector names a controlled contrast and its required fate: sensor disagreement that must remain observable, a class margin that must survive, a nuisance perturbation that should disappear, or a control variable that must remain recoverable. For a non-zero preservation contrast d, define its retention:
The ratio has no universal pass mark. If two output observations can each carry perturbation with Euclidean norm at most ε, their separation can be obscured by as much as 2ε. A conservative deterministic test is therefore ‖Ad‖2 > 2ε. A probabilistic system should replace that bound with a distributional error model and a required confidence level. A classifier may instead compare the transformed distinction with its decision margin. A reversible codec may compare reconstruction error with application tolerance.
The threshold must be stated in the units of the decision. Matrix diagnostics become misleading when features with kilograms, milliseconds and percentages are combined without scaling. Standardisation may help numerical analysis, but it is not neutral: it embeds a judgement about which variation counts as comparable. Record the scaling transformation alongside the matrix and run the distinction test in both engineering units and model coordinates.
| Question | Measure | Failure signal | Decision response |
|---|---|---|---|
| What does each input basis direction become? | Columns and units | Unexpected coupling or scale dominance | Rescale, constrain or redesign features |
| Which directions are amplified or attenuated most? | Singular vectors and singular values | Large spread or amplification of nuisance directions | Regularise, reparameterise or add monitoring |
| Which distinctions vanish exactly? | Null space and rank | A required contrast lies in or near the null space | Keep an explicit channel or increase output dimension |
| Which distinctions vanish operationally? | ρA(d) against noise and margin | ‖Ad‖ is below the declared threshold | Reject the transformation for that task |
| Can recovery tolerate perturbation? | Condition number and error bounds | Inverse sensitivity exceeds the recovery budget | Avoid inversion, collect more evidence or redesign |
| Does the conclusion survive basis and scale choices? | Whitened and engineering-unit analyses | Pass or fail changes without a justified unit model | Make preprocessing part of the governed artefact |
A release protocol for a learned projection
A practical review can proceed in six passes. First, confirm the matrix’s input and output semantics, including every scaling step. Second, inspect columns and rows for unintended coupling. Third, compute rank, singular values and condition estimates with a declared numerical tolerance. Fourth, run the named contrast register through the operator and compare retained separation with the applicable noise or margin model. Fifth, use an orthogonal or identity baseline to separate harm caused by compression from harm caused merely by coordinate mixing. Sixth, repeat the decisive tests end to end so that later non-linear stages cannot hide behind a healthy local diagnostic.
The baseline matters. Suppose a learned projection and an orthogonal mixer have the same output width and similar downstream latency. If both change the coordinate names but only the learned projection loses a protected contrast, compression geometry is implicated. If both pass locally and the full model fails, the cause lies later. If the identity baseline also fails, the contrast may not be present in the input evidence at all. These matched controls prevent every error from being attributed to the most visually complex matrix.
Store the results as a small decision receipt: matrix or model version, preprocessing version, contrast-set version, numerical tolerance, noise assumptions, measured retentions, negative controls, end-to-end outcomes and reviewer decision. Re-run it when any of those inputs changes. The receipt does not claim that the model is globally reliable. It establishes a bounded proposition: under the stated units and perturbations, this transformation retained these declared distinctions above these thresholds.
For a stack of learned layers, locate the first material attenuation. Let d0 be the input contrast and dk its representation after stage k. Plot ‖dk‖ and, where meaningful, the decision margin attributable to that contrast. A sharp fall identifies the stage to investigate. A gradual decline points to cumulative geometry. A rebound after a non-linearity may restore separability on sampled cases, but it does not prove robust recovery under nearby perturbations, so intervention tests must accompany the trace.
The release decision should be contrast-specific. One matrix may be acceptable for forecasting aggregate load and unacceptable for detecting sensor disagreement. Another may intentionally remove identity-related variation while retaining variables required for legitimate performance. “Good representation” is therefore incomplete without a downstream use, a nuisance model and a consequence model.
There is precedent for caring about singular geometry in learning systems. Glorot and Bengio connected training difficulty to how activations, gradients and Jacobian singular values behave across layers, motivating an initialisation scheme that improved convergence in their experiments.12 That published result concerns optimisation, not semantic retention. The shared mechanism is that repeated linear transformations can amplify some directions and suppress others. The task audit adds the missing question: which of those directions correspond to distinctions the application cannot afford to lose?
Executable matrix notebook
The notebook below is the article’s operational artefact. It accepts a 2 × 2 matrix, a task-relevant difference vector and a bounded output-noise level. It draws the transformed grid, calculates determinant, singular values, numerical rank, condition number and distinction retention, then applies the conservative separation test ‖Ad‖2 > 2ε.
Its assumptions are explicit: real-valued two-dimensional inputs, Euclidean norms, exact matrix entries, and a worst-case bound ε on each output observation. The expected positive case is the orthogonal mixer, which preserves every difference. The negative case is the averaging collapse, which deletes (1, −1). The near-collapse preset is full rank but fails when the retained signal lies within the selected noise bound.
Figure 8. matrix notebook: inspect the machine, then test a distinction
Expected positive and negative cases
| Preset | Expected geometry | For d = (1, −1) | Expected decision at ε = 0.01 |
|---|---|---|---|
| Orthogonal mixer | σ = (1,1), κ = 1 | ρ = 1 | Pass |
| Area-one shear | det = 1, unequal singular values | Direction-dependent retention | Usually pass, with distortion visible |
| Near-collapse | rank 2, κ ≈ 100 | ‖Ad‖ = 0.01, ρ ≈ 0.0071 | Fail because 0.01 ≤ 0.02 |
| Collapse | rank 1, σmin = 0 | Ad = 0 | Fail exactly |
Core calculation used by the notebook
const trace = a*a + b*b + c*c + d*d;
const determinant = a*d - b*c;
const disc = Math.sqrt(Math.max(0, trace*trace - 4*determinant*determinant));
const sigmaMax = Math.sqrt(Math.max(0, (trace + disc) / 2));
const sigmaMin = Math.sqrt(Math.max(0, (trace - disc) / 2));
const out1 = a*dx + b*dy;
const out2 = c*dx + d*dy;
const retainedSeparation = Math.hypot(out1, out2);
const retention = retainedSeparation / Math.hypot(dx, dy);
const survives = retainedSeparation > 2*epsilon;Failure boundary: where the operator audit stops helping
The audit does not turn every machine-learning problem into linear algebra. It characterises a declared linear or locally linear stage. A non-linear activation can restore separability after one matrix mixes coordinates, and it can also destroy a distinction that the matrix preserved. Data-dependent operations such as attention, normalisation in training mode and routing change the effective operator with context. End-to-end intervention remains necessary.
The method also depends on choosing meaningful differences. If the task-relevant contrast is unknown, misspecified or outside the observed environment, a clean audit can certify the wrong set. Singular values offer a global worst case, but they do not attach semantics to directions. Domain evidence must provide the contrasts, units, noise model and recovery cost.
Finally, a small singular value can be intentional. Compression, denoising and invariance often require deleting variation. The question is whether the deleted direction is nuisance variation under the target decision, not whether every input can be reconstructed. The mechanism ceases to help when preservation itself is not the objective or when the effective transformation is materially non-linear and context-dependent.
Compact glossary
- Column space
- All outputs the matrix can produce.
- Null space
- Input directions that map exactly to zero.
- Rank
- The number of independent output directions that survive.
- Determinant
- Signed area or volume scale for a square matrix.
- Singular value
- A principal directional stretch in the SVD.
- Condition number
- The ratio between greatest and least surviving stretch.
- Orthogonal matrix
- A rotation or reflection that preserves Euclidean lengths.
- Distinction retention
- The task-specific ratio ‖Ad‖/‖d‖ for a chosen contrast.
Choose matrices by the distinctions they keep
A matrix is often introduced as a rectangular arrangement of numbers because that is easy to write down. It is more useful to meet it as a machine. Its columns route basis directions. Its determinant summarises volume. Its singular values expose directional gain. Its null space records exact oblivion. Its condition number estimates the price of trying to reverse a severe squeeze.
The central decision follows. Do not accept a transformation because it has full rank, a respectable determinant or good average loss. Name the differences the downstream task must still recognise. Push those vectors through the matrix. Compare their retained separation with noise, quantisation, margin and recovery cost. Keep the audit with the preprocessing, units and matrix version so that a later change can be tested against the same obligations.
This changes model design in a concrete way. An encoder that averages two channels must retain a separate disagreement channel when disagreement carries fault evidence. A learned projection that suppresses a rare but consequential contrast needs a constraint, an auxiliary loss or a wider representation. An inverse problem with a large condition number should seek new measurements rather than pretend that algebra can manufacture missing evidence.
The grid picture is therefore more than a teaching aid. It is a causal diagram of what the system can still distinguish. Rotation relocates evidence. Stretch changes its scale. Mixing changes its coordinates. Collapse removes it. The matrix earns its place only when the distinctions that matter survive the trip.
Sources
- Arthur Cayley, “A Memoir on the Theory of Matrices”, Philosophical Transactions of the Royal Society, 1858. Primary historical source.
- MIT OpenCourseWare, “Linear Transformations and their Matrices”. Authoritative teaching source for the operator view.
- MIT OpenCourseWare, “Column Space and Nullspace”. Authoritative teaching source for solvability and invisible directions.
- MIT OpenCourseWare, “Cramer’s Rule, Inverse Matrix and Volume”. Authoritative teaching source for determinant and volume.
- MIT OpenCourseWare, “Singular Value Decomposition”. Authoritative teaching source for A=UΣVT.
- LAPACK Users’ Guide, “How to Measure Errors” and “Error Bounds for Linear Equation Solving”. Official numerical linear algebra guidance.
- NumPy,
numpy.linalg.matrix_rank. Official implementation documentation for SVD-based numerical rank. - NumPy,
numpy.linalg.cond. Official implementation documentation for condition numbers. - NumPy,
numpy.linalg.inv. Official documentation and warning on ill-conditioned inversion. - PyTorch,
torch.nn.Linear. Official specification of an affine linear layer. - Xavier Glorot and Yoshua Bengio, “Understanding the difficulty of training deep feedforward neural networks”, AISTATS 2010. Primary machine-learning result connecting training behaviour with layer and Jacobian singular geometry.