Pure data produced by an echelon-form algorithm.
- rank : Nat
Number of pivots, i.e. the rank of the original matrix.
- echelon : Matrix R n m
The matrix reduced to row-echelon form.
- transform : Matrix R n n
The accumulated row-operation transform
TwithT * original = echelon. Column index of each pivot, in increasing order.
Instances For
Shared conditions for any echelon form.
Instances For
RREF-specific conditions on top of IsEchelonForm.
Instances For
View a pivot-row index as a row index of the ambient matrix.
Instances For
The pivot entries named by pivotCols are nonzero. This is the extra
proof-facing contract needed by span solving: without it, the pivot-column
division in spanCoeffs can divide by zero.
Instances For
The square row-transform has a right inverse.
The pivot columns are injective because they are strictly increasing.
The non-pivot columns, enumerated in increasing order.
The echelon-form witness _E is a phantom argument: it carries no runtime
data but enables dot-notation (E.freeColsList) and fixes the implicit
matrix/data parameters. This intentionally triggers the unusedArguments
linter; the binder is kept deliberately (no @[nolint] exists in the
Mathlib-free layer).
Equations
- _E.freeColsList = List.filter (fun (j : Fin m) => decide ¬j ∈ D.pivotCols.toList) (List.finRange m)
Instances For
Linear merge used by the compiled implementation of freeColsList.
The second list is a sorted sublist of the first. Matching heads are discarded; otherwise the first head belongs to the complement. Both recursive calls consume a column, and a matching call also consumes a pivot, so the loop is linear in the two input lengths.
Equations
- One or more equations did not get rendered due to their size.
- Hex.Matrix.IsEchelonForm.sortedComplement x✝ [] = x✝
- Hex.Matrix.IsEchelonForm.sortedComplement [] x✝ = []
Instances For
Runtime implementation of freeColsList, merging the sorted pivot columns
with the complete sorted column range.
Equations
Instances For
Register the linear merge as the compiled implementation of
freeColsList. The proof keeps the specification and all theorem-facing
unfolding unchanged.
The number of free columns is the ambient column count minus the rank.
Sorted complement of the pivot columns.
Equations
- E.freeCols = Vector.mk E.freeColsList.toArray ⋯
Instances For
The free-column complement is strictly increasing.
The free columns are injective because they are strictly increasing.
Every column is either a pivot column or a free column.
No column can simultaneously occur in the pivot list and the free-column complement.
No column can be both pivot and free.