Top | ![]() |
![]() |
![]() |
![]() |
IntegerMatrix * | intmat_new () |
IntegerMatrix * | intmat_copy () |
IntegerMatrix * | intmat_identity () |
void | intmat_free () |
signed int | intmat_get () |
void | intmat_set () |
IntegerMatrix * | intmat_intmat_mult () |
signed int * | intmat_intvec_mult () |
signed int | intmat_det () |
IntegerMatrix * | intmat_inverse () |
int | intmat_equals () |
int | intmat_is_identity () |
int | intmat_is_inversion () |
void | intmat_print () |
IntegerMatrix * intmat_new (unsigned int rows
,unsigned int cols
);
Allocates a new IntegerMatrix
with all elements set to zero.
void
intmat_free (IntegerMatrix *m
);
Frees m
, unless m
is NULL in which case nothing is done.
signed int intmat_get (const IntegerMatrix *m
,unsigned int i
,unsigned int j
);
Gets the i
,j
element of m
.
void intmat_set (IntegerMatrix *m
,unsigned int i
,unsigned int j
,signed int v
);
Sets the i
,j
element of m
to v
.
IntegerMatrix * intmat_intmat_mult (const IntegerMatrix *a
,const IntegerMatrix *b
);
Multiplies the matrix a
by the matrix b
.
signed int * intmat_intvec_mult (const IntegerMatrix *m
,const signed int *vec
);
Multiplies the matrix m
by the vector vec
. The size of vec
must equal the
number of columns in m
, and the size of the result equals the number of rows
in m
.
signed int
intmat_det (const IntegerMatrix *m
);
Calculates the determinant of m
. Inefficiently.
IntegerMatrix *
intmat_inverse (const IntegerMatrix *m
);
Calculates the inverse of m
. Inefficiently.