Skip to main content

Module serial

Module serial 

Source
Expand description

Serial sparse matrix arithmetic routines.

All routines are single-threaded.

Some operations have the prealloc suffix. This means that they expect that the sparsity pattern of the output matrix has already been pre-allocated: that is, the pattern of the result of the operation fits entirely in the output pattern. In the future, there will also be some operations which will be able to dynamically adapt the output pattern to fit the result, but these have yet to be implemented.

Structs§

OperationError
A description of the error that occurred during an arithmetic operation.

Enums§

OperationErrorKind
The different kinds of operation errors that may occur.

Functions§

spadd_csc_prealloc
Sparse matrix addition C <- beta * C + alpha * op(A).
spadd_csr_prealloc
Sparse matrix addition C <- beta * C + alpha * op(A).
spadd_pattern
Sparse matrix addition pattern construction, C <- A + B.
spmm_csc_dense
Sparse-dense matrix-matrix multiplication C <- beta * C + alpha * op(A) * op(B).
spmm_csc_pattern
Sparse matrix multiplication pattern construction, C <- A * B.
spmm_csc_prealloc
Sparse-sparse matrix multiplication, C <- beta * C + alpha * op(A) * op(B).
spmm_csc_prealloc_unchecked
Faster sparse-sparse matrix multiplication, C <- beta * C + alpha * op(A) * op(B). This will not return an error even if the patterns don’t match. Should be used for situations where pattern creation immediately precedes multiplication.
spmm_csr_dense
Sparse-dense matrix-matrix multiplication C <- beta * C + alpha * op(A) * op(B).
spmm_csr_pattern
Sparse matrix multiplication pattern construction, C <- A * B.
spmm_csr_prealloc
Sparse-sparse matrix multiplication, C <- beta * C + alpha * op(A) * op(B).
spmm_csr_prealloc_unchecked
Faster sparse-sparse matrix multiplication, C <- beta * C + alpha * op(A) * op(B). This will not return an error even if the patterns don’t match. Should be used for situations where pattern creation immediately precedes multiplication.
spsolve_csc_lower_triangular
Solve the lower triangular system op(L) X = B.