padic_radix_mat_mul_packed, padic_radix_mat_mul_fmpz, padic_radix_mat_mul_mpn_mod, padic_radix_mat_mul
#include <flint/padic_radix.h>Set . The packed version accumulates the limb products of every output directly. The fmpz version scales row of and column of to base frames and , truncates the residues to the largest output window, multiplies the resulting integer matrices with nmod_mat_mul (modulo , when every window is a single limb) or fmpz_mat_mul (multimodular and blocked algorithms), and reduces every output modulo for its window of limbs before the conversion to radix . The mpn_mod version is the same with the products done modulo for the largest window of limbs by mpn_mod_mat_mul (classical with delayed reduction, Waksman or multimodular), and returns GR_UNABLE if does not have between 2 and MPN_MOD_MAX_LIMBS binary limbs; padic_radix_mat_mul uses it in that range, the nmod version for one-limb windows and the fmpz version above. Outputs whose terms are all exact are summed exactly, in windows covering the a priori extents of their terms plus a carry and a sign limb, when padic_radix_dot_strided_delayed would keep them exact. Its precisions are computed with blockwise minima of the exponents, in operations for outputs whose row of or column of has exponents that are constant on blocks of the inner index (e.g. uniform valuations and precisions), and with the exact minimum for the others; the results are identical to those of the packed version. The base frames can be far below the frame of an output whose terms all have higher valuations; the fmpz and mpn_mod versions return GR_UNABLE when the largest window in the base frames exceeds four times (plus 8 limbs) the largest window of an output in its own frame, since the integers would then be much larger than the precision requires (arbitrarily large for valuations spread beyond the precision).
padic_radix_mat_mul implements the generic method gr_mat_mul: the classical algorithm for inner dimension at most 3, the modular versions above tuned crossovers (estimated from an upper bound for the output windows: from dimension 8 when all windows are one limb, about 32 at two limbs, 16 at 3 to 8 limbs, 28 up to 15 limbs and 48 beyond, raised when the limb frames of the entries are spread out and when the exact precision bookkeeping is needed), and the packed version otherwise.
The FLINT team, “padic_radix_mat_mul_packed, padic_radix_mat_mul_fmpz, padic_radix_mat_mul_mpn_mod, padic_radix_mat_mul (padic_radix.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/padic_radix/padic_radix_mat_mul_packed.html (generated 2026-11-02).
@misc{flint-doc-padic-radix-padic-radix-mat-mul-packed,
author = {{The FLINT team}},
title = {{padic\_radix\_mat\_mul\_packed, padic\_radix\_mat\_mul\_fmpz, padic\_radix\_mat\_mul\_mpn\_mod, padic\_radix\_mat\_mul (padic\_radix.h)}},
howpublished = {FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev},
year = {2026},
url = {https://flintlib.org/doc/padic_radix/padic_radix_mat_mul_packed.html},
note = {Generated 2026-11-02}
}