FLINT3.7.0-dev

fmpz_mat_swap_rows, fmpz_mat_swap_cols

Synopsis#include <flint/fmpz_mat.h>
void fmpz_mat_swap_rows(fmpz_mat_t mat, slong * perm, slong r, slong s)source
void fmpz_mat_swap_cols(fmpz_mat_t mat, slong * perm, slong r, slong s)source

Swaps rows, respectively columns, r and s of mat, and entries r and s of perm. Rows are swapped by swapping their entries, so this costs O(c) even for multiprecision entries.

Cite this page

The FLINT team, “fmpz_mat_swap_rows, fmpz_mat_swap_cols (fmpz_mat.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/fmpz_mat/fmpz_mat_swap_rows.html (generated 2026-10-20).