|
| 1 | +from flint.flintlib.flint cimport ulong, slong, fmpz_struct, flint_rand_t |
| 2 | +from flint.flintlib.fmpz cimport fmpz_t |
| 3 | +from flint.flintlib.fmpz_mod cimport fmpz_mod_ctx_t |
| 4 | +from flint.flintlib.fmpz_mat cimport fmpz_mat_t |
| 5 | +from flint.flintlib.fmpz_mod_poly cimport fmpz_mod_poly_t |
| 6 | + |
| 7 | + |
| 8 | +cdef extern from "flint/fmpz_mod_mat.h": |
| 9 | + ctypedef struct fmpz_mod_mat_struct: |
| 10 | + fmpz_mat_t mat |
| 11 | + fmpz_t mod |
| 12 | + ctypedef fmpz_mod_mat_struct fmpz_mod_mat_t[1] |
| 13 | + |
| 14 | + |
| 15 | +cdef extern from "flint/fmpz_mod_mat.h": |
| 16 | + # This is not exposed in the docs: |
| 17 | + int fmpz_mod_mat_equal(const fmpz_mod_mat_t mat1, const fmpz_mod_mat_t mat2); |
| 18 | + |
| 19 | + |
| 20 | +cdef extern from "flint/fmpz_mod_mat.h": |
| 21 | + fmpz_struct * fmpz_mod_mat_entry(const fmpz_mod_mat_t mat, slong i, slong j) |
| 22 | + void fmpz_mod_mat_set_entry(fmpz_mod_mat_t mat, slong i, slong j, const fmpz_t val) |
| 23 | + void fmpz_mod_mat_init(fmpz_mod_mat_t mat, slong rows, slong cols, const fmpz_t n) |
| 24 | + void fmpz_mod_mat_init_set(fmpz_mod_mat_t mat, const fmpz_mod_mat_t src) |
| 25 | + void fmpz_mod_mat_clear(fmpz_mod_mat_t mat) |
| 26 | + slong fmpz_mod_mat_nrows(const fmpz_mod_mat_t mat) |
| 27 | + slong fmpz_mod_mat_ncols(const fmpz_mod_mat_t mat) |
| 28 | + void _fmpz_mod_mat_set_mod(fmpz_mod_mat_t mat, const fmpz_t n) |
| 29 | + void fmpz_mod_mat_one(fmpz_mod_mat_t mat) |
| 30 | + void fmpz_mod_mat_zero(fmpz_mod_mat_t mat) |
| 31 | + void fmpz_mod_mat_swap(fmpz_mod_mat_t mat1, fmpz_mod_mat_t mat2) |
| 32 | + void fmpz_mod_mat_swap_entrywise(fmpz_mod_mat_t mat1, fmpz_mod_mat_t mat2) |
| 33 | + int fmpz_mod_mat_is_empty(const fmpz_mod_mat_t mat) |
| 34 | + int fmpz_mod_mat_is_square(const fmpz_mod_mat_t mat) |
| 35 | + void _fmpz_mod_mat_reduce(fmpz_mod_mat_t mat) |
| 36 | + void fmpz_mod_mat_randtest(fmpz_mod_mat_t mat, flint_rand_t state) |
| 37 | + void fmpz_mod_mat_window_init(fmpz_mod_mat_t window, const fmpz_mod_mat_t mat, slong r1, slong c1, slong r2, slong c2) |
| 38 | + void fmpz_mod_mat_window_clear(fmpz_mod_mat_t window) |
| 39 | + void fmpz_mod_mat_concat_horizontal(fmpz_mod_mat_t res, const fmpz_mod_mat_t mat1, const fmpz_mod_mat_t mat2) |
| 40 | + void fmpz_mod_mat_concat_vertical(fmpz_mod_mat_t res, const fmpz_mod_mat_t mat1, const fmpz_mod_mat_t mat2) |
| 41 | + void fmpz_mod_mat_print_pretty(const fmpz_mod_mat_t mat) |
| 42 | + int fmpz_mod_mat_is_zero(const fmpz_mod_mat_t mat) |
| 43 | + void fmpz_mod_mat_set(fmpz_mod_mat_t B, const fmpz_mod_mat_t A) |
| 44 | + void fmpz_mod_mat_transpose(fmpz_mod_mat_t B, const fmpz_mod_mat_t A) |
| 45 | + void fmpz_mod_mat_set_fmpz_mat(fmpz_mod_mat_t A, const fmpz_mat_t B) |
| 46 | + void fmpz_mod_mat_get_fmpz_mat(fmpz_mat_t A, const fmpz_mod_mat_t B) |
| 47 | + void fmpz_mod_mat_add(fmpz_mod_mat_t C, const fmpz_mod_mat_t A, const fmpz_mod_mat_t B) |
| 48 | + void fmpz_mod_mat_sub(fmpz_mod_mat_t C, const fmpz_mod_mat_t A, const fmpz_mod_mat_t B) |
| 49 | + void fmpz_mod_mat_neg(fmpz_mod_mat_t B, const fmpz_mod_mat_t A) |
| 50 | + void fmpz_mod_mat_scalar_mul_si(fmpz_mod_mat_t B, const fmpz_mod_mat_t A, slong c) |
| 51 | + void fmpz_mod_mat_scalar_mul_ui(fmpz_mod_mat_t B, const fmpz_mod_mat_t A, ulong c) |
| 52 | + void fmpz_mod_mat_scalar_mul_fmpz(fmpz_mod_mat_t B, const fmpz_mod_mat_t A, fmpz_t c) |
| 53 | + void fmpz_mod_mat_mul(fmpz_mod_mat_t C, const fmpz_mod_mat_t A, const fmpz_mod_mat_t B) |
| 54 | + # unimported types {'thread_pool_handle'} |
| 55 | + # void _fmpz_mod_mat_mul_classical_threaded_pool_op(fmpz_mod_mat_t D, const fmpz_mod_mat_t C, const fmpz_mod_mat_t A, const fmpz_mod_mat_t B, int op, thread_pool_handle * threads, slong num_threads) |
| 56 | + void _fmpz_mod_mat_mul_classical_threaded_op(fmpz_mod_mat_t D, const fmpz_mod_mat_t C, const fmpz_mod_mat_t A, const fmpz_mod_mat_t B, int op) |
| 57 | + void fmpz_mod_mat_mul_classical_threaded(fmpz_mod_mat_t C, const fmpz_mod_mat_t A, const fmpz_mod_mat_t B) |
| 58 | + void fmpz_mod_mat_sqr(fmpz_mod_mat_t B, const fmpz_mod_mat_t A) |
| 59 | + void fmpz_mod_mat_mul_fmpz_vec(fmpz_struct * c, const fmpz_mod_mat_t A, const fmpz_struct * b, slong blen) |
| 60 | + void fmpz_mod_mat_mul_fmpz_vec_ptr(fmpz_struct * const * c, const fmpz_mod_mat_t A, const fmpz_struct * const * b, slong blen) |
| 61 | + void fmpz_mod_mat_fmpz_vec_mul(fmpz_struct * c, const fmpz_struct * a, slong alen, const fmpz_mod_mat_t B) |
| 62 | + void fmpz_mod_mat_fmpz_vec_mul_ptr(fmpz_struct * const * c, const fmpz_struct * const * a, slong alen, const fmpz_mod_mat_t B) |
| 63 | + void fmpz_mod_mat_trace(fmpz_t trace, const fmpz_mod_mat_t mat) |
| 64 | + slong fmpz_mod_mat_rref(slong * perm, fmpz_mod_mat_t mat) |
| 65 | + void fmpz_mod_mat_strong_echelon_form(fmpz_mod_mat_t mat) |
| 66 | + slong fmpz_mod_mat_howell_form(fmpz_mod_mat_t mat) |
| 67 | + int fmpz_mod_mat_inv(fmpz_mod_mat_t B, fmpz_mod_mat_t A) |
| 68 | + slong fmpz_mod_mat_lu(slong * P, fmpz_mod_mat_t A, int rank_check) |
| 69 | + void fmpz_mod_mat_solve_tril(fmpz_mod_mat_t X, const fmpz_mod_mat_t L, const fmpz_mod_mat_t B, int unit) |
| 70 | + void fmpz_mod_mat_solve_triu(fmpz_mod_mat_t X, const fmpz_mod_mat_t U, const fmpz_mod_mat_t B, int unit) |
| 71 | + int fmpz_mod_mat_solve(fmpz_mod_mat_t X, const fmpz_mod_mat_t A, const fmpz_mod_mat_t B) |
| 72 | + int fmpz_mod_mat_can_solve(fmpz_mod_mat_t X, const fmpz_mod_mat_t A, const fmpz_mod_mat_t B) |
| 73 | + void fmpz_mod_mat_similarity(fmpz_mod_mat_t M, slong r, fmpz_t d) |
| 74 | + void fmpz_mod_mat_charpoly(fmpz_mod_poly_t p, const fmpz_mod_mat_t M, const fmpz_mod_ctx_t ctx) |
| 75 | + void fmpz_mod_mat_minpoly(fmpz_mod_poly_t p, const fmpz_mod_mat_t M, const fmpz_mod_ctx_t ctx) |
0 commit comments