File numerics/src/tools/NM_conversions.h

Go to the source code of this file

Conversion related functions for the various matrix storages in Numerics.

Functions

CSparseMatrix *NM_csc_to_triplet(CSparseMatrix *csc)

Convert from csc to triplet (aka coo)

Parameters

csc – the matrix to convert

Returns

the matrix in triplet format

CSparseMatrix *NM_csc_to_half_triplet(CSparseMatrix *csc)

Convert from csc to half triplet for symmetric matrices.

Parameters

csc – the matrix to convert

Returns

the matrix in triplet format

CSparseMatrix *NM_triplet_to_csr(CSparseMatrix *triplet)

Convert from triplet (aka coo) to csr.

Parameters

triplet – the matrix to convert

Returns

the matrix in csr format

CSparseMatrix *NM_csr_to_triplet(CSparseMatrix *csr)

Convert from csr to triplet (aka coo)

Parameters

csr – the matrix to convert

Returns

the matrix in triplet format

CSparseMatrix *NM_csc_to_csr(CSparseMatrix *csc)

Convert from csc to csr.

Parameters

csc – the matrix to convert

Returns

the matrix in csr format

CSparseMatrix *NM_csr_to_csc(CSparseMatrix *csr)

Convert from csr to csc.

Parameters

csr – the matrix to convert

Returns

the matrix in csc format