padic_radix_dot_strided, padic_radix_dot_strided_naive, padic_radix_dot_strided_delayed
#include <flint/padic_radix.h>int padic_radix_dot_strided(padic_radix_t res, const padic_radix_t initial, int subtract, const padic_radix_struct * vec1, slong stride1, const padic_radix_struct * vec2, slong stride2, slong len, gr_ctx_t ctx)sourceint padic_radix_dot_strided_naive(padic_radix_t res, const padic_radix_t initial, int subtract, const padic_radix_struct * vec1, slong stride1, const padic_radix_struct * vec2, slong stride2, slong len, gr_ctx_t ctx)sourceint padic_radix_dot_strided_delayed(padic_radix_t res, const padic_radix_t initial, int subtract, const padic_radix_struct * vec1, slong stride1, const padic_radix_struct * vec2, slong stride2, slong len, gr_ctx_t ctx)sourceSet res to with = vec1[i * stride1], = vec2[i * stride2], = initial (zero if initial is NULL) and the sign if subtract is nonzero. The naive version calls padic_radix_mul and padic_radix_add in a loop. The delayed version finds the minimum valuation and the precision of the result first, then accumulates the limb products of all terms in three-word accumulators, grouped by the residue of the digit offset modulo and by sign; at the end the residue classes are combined in one pass (each accumulator multiplied by for its residue ) and the carries are propagated once. The default uses the naive version for at most 4 terms at a precision of one limb, 3 terms at two limbs and 2 terms above (relative precision, or absolute if there is none), and, at precisions of up to two limbs, also for up to 7 terms whose valuations are not all equal.
When all terms are exact, the delayed version keeps the result exact if it fits in the context precision (as padic_radix_mul and padic_radix_add do), provided that the a priori extent of the terms, for units of and limbs, is at most one limb beyond the context precision; otherwise the sum is rounded to the context precision. In a context without finite precision, when the window of the delayed version (the extent of the exact terms, or the precision they determine) exceeds the size_limit of the context, it calls the naive version, which builds only the partial sums (and still gets exact cancellations of terms with huge valuations right).
The FLINT team, “padic_radix_dot_strided, padic_radix_dot_strided_naive, padic_radix_dot_strided_delayed (padic_radix.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/padic_radix/padic_radix_dot_strided.html (generated 2026-11-02).
@misc{flint-doc-padic-radix-padic-radix-dot-strided,
author = {{The FLINT team}},
title = {{padic\_radix\_dot\_strided, padic\_radix\_dot\_strided\_naive, padic\_radix\_dot\_strided\_delayed (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_dot_strided.html},
note = {Generated 2026-11-02}
}