Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions src/linalg.jl
Original file line number Diff line number Diff line change
Expand Up @@ -986,6 +986,11 @@ estimator of Higham and Tisseur, from a factorization of `A` by `factorize` and
forming the inverse, so the result can fall below the exact condition number. `p = 2`, the
default, throws an `ArgumentError`, so `cond(A)` does too: use `cond(Array(A))` for a matrix
small enough to store dense.

A singular matrix gives `Inf` when its factorization meets an exactly zero pivot. Rounding
can hide that zero, and the result is then finite but very large. The sparse LU pivots in
another order than the dense one, so `cond(A, p)` can be finite where `cond(Array(A), p)`
is `Inf`.
"""
function cond(A::AbstractSparseMatrixCSC, p::Real=2)
# as for a dense matrix; the estimator of the inverse's norm needs at least one column
Expand Down
Loading