Expand description
Small dense matrix algebra shared by every conductor sized calculation:
the series impedance inverses of lines and transformers, the potential
coefficient inverses of overhead geometry, and Kron reduction. The kernel
is [powerio_core::dense], the one dense elimination; this module
re-exports it.
Enums§
- Dense
Pivot - The pivot order of
invert_dense_matrix’s elimination.
Traits§
- Dense
Scalar - A scalar
invert_dense_matrixworks over: real (f64) or complex (Complex64).
Functions§
- invert_
dense_ matrix - The inverse of a small dense square matrix by Gauss-Jordan elimination
in the
pivotorder (DensePivot).Nonewhen a pivot’s magnitude is NaN, infinite (underDensePivot::Partial; underDensePivot::OpenDssDiagonalan infinite unscaled magnitude is a pivot),singular_pivotor smaller, orrelative_pivottimes the largest original magnitude in its column or smaller. Each caller states the pivot its quantity is singular at: an absolutesingular_pivot(ohms for a series impedance, a dimensionless coefficient for a potential matrix) and arelative_pivotthat measures cancellation within a column against that column’s own scale (the dense PTDF fallback passesn ε, so a column eliminated to rounding noise is singular while a wide but valid spread of magnitudes stays invertible). Zero for both refuses only exact singularity. A one by one matrix inverts as its scaled reciprocal (DenseScalar::reciprocal). An empty matrix inverts to an empty matrix.