[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

Basic Operations on matrices

Function: matrix_t* matrix_alloc (int nr, int nc, bool s)
Allocates a new matrix with nr rows and nc columns and sets all elements to zero. s indicates if once filled the matrix should be considered as already sorted or not, according to the lexicographic order.

If either nr or nc is zero, the matrix is said to be degenerated and no space is allocated for coefficients (fields p and _pinit of the matrix are null). Only functions of this paragraph handle correctly such matrices (this happens to be useful, for instance when interfacing with OCAML language).

Function: void matrix_free (matrix_t* mat)
Frees the matrix mat and finalizes referenced elements.

Function: matrix_t* matrix_copy (const matrix_t* mat)
Return a copy of mat. The new matrix is dimensionned from the active part of mat.

Function: void matrix_print (const matrix_t* mat)
Prints the matrix.

Function: void matrix_clear (matrix_t* mat)
Sets to zeros the active coefficients of mat.

This document was generated on October, 27 2006 using texi2html