Amount of storage allocated for nonzero matrix elements
n = nzmax(S)
n = nzmax(S) returns the
amount of storage allocated for nonzero elements in sparse matrix
For sparse matrices,
nzmax(S) >= 1.
S is a full matrix, then
the same. But if
S is created by an operation which
produces fill-in matrix elements, such as sparse matrix multiplication
or sparse LU factorization, then more storage might be allocated than
is actually required, and
nzmax(S) reflects this.
sparse(i,j,s,m,n,nzmax) or its simpler
spalloc(m,n,nzmax), can set
anticipation of later fill-in.