FLINT3.7.0-dev

fmpz_mat_is_diagonal

Synopsis#include <flint/fmpz_mat.h>
int fmpz_mat_is_diagonal(const fmpz_mat_t A)source

Returns 1 if all entries of A outside the main diagonal are zero, and 0 otherwise. A need not be square.

Cite this page

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