fmpq_mat_rref, fmpq_mat_rref_classical, fmpq_mat_rref_fraction_free
Synopsis
#include <flint/fmpq_mat.h>slong fmpq_mat_rref(fmpq_mat_t B, const fmpq_mat_t A)sourceslong fmpq_mat_rref_classical(fmpq_mat_t B, const fmpq_mat_t A)sourceslong fmpq_mat_rref_fraction_free(fmpq_mat_t B, const fmpq_mat_t A)sourceSets B to the reduced row echelon form of A and returns the rank. B may be A. fmpq_mat_rref_classical uses Gauss–Jordan elimination with rational arithmetic; fmpq_mat_rref_fraction_free clears the denominators of the rows and calls fmpz_mat_rref. fmpq_mat_rref uses the classical algorithm if A has at most 2 rows or columns and the fraction-free one otherwise.
Cite this page
The FLINT team, “fmpq_mat_rref, fmpq_mat_rref_classical, fmpq_mat_rref_fraction_free (fmpq_mat.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/fmpq_mat/fmpq_mat_rref.html (generated 2026-10-20).
@misc{flint-doc-fmpq-mat-fmpq-mat-rref,
author = {{The FLINT team}},
title = {{fmpq\_mat\_rref, fmpq\_mat\_rref\_classical, fmpq\_mat\_rref\_fraction\_free (fmpq\_mat.h)}},
howpublished = {FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev},
year = {2026},
url = {https://flintlib.org/doc/fmpq_mat/fmpq_mat_rref.html},
note = {Generated 2026-10-20}
}