Skip to main content

spmv_full_ndarray

Function spmv_full_ndarray 

Source
pub fn spmv_full_ndarray<T: Scalar + Clone + Field>(
    alpha: T,
    a: &CsrMatrix<T>,
    x: &Array1<T>,
    beta: T,
    y: &mut Array1<T>,
)
Expand description

Sparse matrix-vector multiplication with scaling: y = alpha * A * x + beta * y

General form of SpMV that supports scaling factors.

§Arguments

  • alpha - Scalar multiplier for A * x
  • a - Sparse CSR matrix (m x n)
  • x - Dense input vector (length n)
  • beta - Scalar multiplier for existing y
  • y - Dense output vector (length m), modified in place

§Panics

Panics if dimensions do not match.