|
M4RI
1.0.1
|
Input/output routines for matrices. More...
Go to the source code of this file.
Functions | |
| void | mzd_print (mzd_t const *M) |
| Print a matrix to stdout. More... | |
| void | mzd_info (const mzd_t *A, int do_rank) |
| Print compact information about the matrix to stdout. More... | |
| mzd_t * | mzd_from_jcf (const char *fn, int verbose) |
| Read matrix from ASCII file in JCF format. More... | |
Input/output routines for matrices.
| mzd_t* mzd_from_jcf | ( | const char * | fn, |
| int | verbose | ||
| ) |
Read matrix from ASCII file in JCF format.
The format is as follows:
nrows ncols modulus nonzero_entries_upper_bound column_index
where a negative column_index indicates a row_index increase by one and a non-zero entry at index -column_index.
For example, a valid input is:
2 3 2 3 -2 -1 -2
which produces the matrix
[0 1] [1 1]
| fn | Filename |
| verbose | Print error message to stdout if != 0 |
| void mzd_info | ( | const mzd_t * | A, |
| int | do_rank | ||
| ) |
Print compact information about the matrix to stdout.
Prints number of rows, number of columns, density (and rank).
| A | Matrix |
| do_rank | Also display the rank (expensive) |
| void mzd_print | ( | mzd_t const * | M | ) |
Print a matrix to stdout.
The output will contain colons between every 4-th column.
| M | Matrix |
1.8.3.1