Many Octave functions have been overloaded to work with either sparse or full matrices. There is no difference in calling convention when using an overloaded function with a sparse matrix, however, there is also no access to potentially sparse-specific features. At any time the sparse matrix specific version of a function can be used by explicitly calling its function name.
The table below lists all of the sparse functions of Octave. Note that the names of the specific sparse forms of the functions are typically the same as the general versions with a sp prefix. In the table below, and in the rest of this article, the specific sparse versions of functions are used.
spalloc, spdiags, speye, sprand, sprandn, sprandsym
full, sparse, spconvert
issparse, nnz, nonzeros, nzmax, spfun, spones, spy
etree, etreeplot, gplot, treeplot
amd, ccolamd, colamd, colperm, csymamd, dmperm, symamd, randperm, symrcm
condest, eigs, matrix_type, normest, normest1, sprank, spaugment, svds
ichol, ilu, pcg, pcr
spparms, symbfact, spstats
In addition all of the standard Octave mapper functions (i.e., basic math functions that take a single argument) such as abs, etc. can accept sparse matrices. The reader is referred to the documentation supplied with these functions within Octave itself for further details.
© 1996–2018 John W. Eaton
Permission is granted to make and distribute verbatim copies of this manual provided the copyright notice and this permission notice are preserved on all copies.
Permission is granted to copy and distribute modified versions of this manual under the conditions for verbatim copying, provided that the entire resulting derived work is distributed under the terms of a permission notice identical to this one.Permission is granted to copy and distribute translations of this manual into another language, under the above conditions for modified versions.
https://octave.org/doc/interpreter/Sparse-Functions.html