NLA-lib Explorer

Spectral conditioning and the distance to singularity

Library · Source module

Spectral conditioning and the distance to singularity

NLAlib.pseudoConditionNumber A is \|\mathbf{A}\|_2 \|\mathbf{A}^{+}\|_2, defined for a matrix of any shape through the Moore–Penrose pseudoinverse: the ratio of the largest singular value of \mathbf{A} to its smallest nonzero one, and 0 for the zero matrix. It is real-valued.

It is not the classical condition number on singular or rank-deficient matrices, which is \sigma_0(\mathbf{A}) / \sigma_{\min}(\mathbf{A}), infinite as soon as \sigma_{\min}(\mathbf{A}) = 0: a nonzero singular orthogonal projector, such as \operatorname{diag}(1, 0), has pseudo-condition number 1. For a matrix of full column rank the two agree, \|\mathbf{A}\|_2 \|\mathbf{A}^{+}\|_2 = \sigma_0(\mathbf{A}) / \sigma_{\min}(\mathbf{A}) (NLAlib.pseudoConditionNumber_of_injective), and for an invertible matrix it is the classical \kappa(\mathbf{A}) = \|\mathbf{A}\|_2 \|\mathbf{A}^{-1}\|_2 (NLAlib.pseudoConditionNumber_of_isUnit). For square matrices NLAlib.spectralConditionNumber takes values in the extended nonnegative reals: it agrees with the finite quantity on units and takes the value infinity on singular inputs.

The distance from a matrix to the nearest rank-deficient one, in spectral norm, is its smallest singular value.

The names conditionNumber and conditionNumber_* are deprecated aliases (2026-10-14).

Main definitions

* NLAlib.pseudoConditionNumber: \|\mathbf{A}\|_2 \|\mathbf{A}^{+}\|_2, that is specNorm A * specNorm (pinv A). * NLAlib.frobPseudoConditionNumber: \|\mathbf{A}\|_{\mathsf{F}}\|\mathbf{A}^{+}\|_2, that is frobNorm A * specNorm (pinv A), the rate constant of randomized Kaczmarz.

Main results

* NLAlib.pseudoConditionNumber_mul_le: submultiplicativity on invertible matrices.

* NLAlib.spectralConditionNumber_eq_top_iff: singularity is equivalent to infinite spectral condition number.

* NLAlib.pseudoConditionNumber_eq_singularValues_div: the ratio of the extreme nonzero singular values. * NLAlib.pseudoConditionNumber_of_injective: the classical \sigma_0(\mathbf{A}) / \sigma_{\min}(\mathbf{A}) at full column rank. * NLAlib.one_le_pseudoConditionNumber: at least one for a nonzero matrix. * NLAlib.pseudoConditionNumber_of_isUnit: the classical formula \|\mathbf{A}\|_2 \|\mathbf{A}^{-1}\|_2. * NLAlib.singularValues_last_le_specNorm_of_not_injective_add, NLAlib.isLeast_specNorm_not_injective_add: the distance to rank deficiency. * NLAlib.one_le_frobPseudoConditionNumber, NLAlib.rank_le_frobPseudoConditionNumber_sq, NLAlib.frobPseudoConditionNumber_sq_le_rank_mul_pseudoConditionNumber_sq: the squared Frobenius pseudo-condition number lies between the rank and the rank times the squared pseudo-condition number.

Declarations