Sparse2csr.m

From Spinach Documentation Wiki
Jump to: navigation, search

Computes a partial Compressed Row Storage transformation for a given Matlab sparse matrix. Only returns the index arrays and ignores the values. Syntax:

                  [row_ptr,col_idx]=sparse2csr(A)

Parameters:

             A - sparse matrix to be converted into the CSR
                 format

Outputs:

              row_ptr - row pointer array of the CSR format
              col_idx - column index array of the CSR format