FLINT3.7.0-dev

vec1d_reduce_pm1no_to_0n, vec4d_reduce_pm1no_to_0n, vec8d_reduce_pm1no_to_0n

Synopsis#include <flint/machine_vectors.h>
vec1d vec1d_reduce_pm1no_to_0n(vec1d a, vec1d n)source
vec4d vec4d_reduce_pm1no_to_0n(vec4d a, vec4d n)
vec8d vec8d_reduce_pm1no_to_0n(vec8d a, vec8d n)

Returns a mod na \bmod n in [0,n)[0, n) for a∈(−n,n)a \in (-n, n), by adding nn to negative lanes. The vec4d and vec8d versions on AVX2 test the sign bit, so they map −0.0-0.0 to nn; the others return −0.0-0.0. AVX2 and NEON.

Cite this page

The FLINT team, “vec1d_reduce_pm1no_to_0n, vec4d_reduce_pm1no_to_0n, vec8d_reduce_pm1no_to_0n (machine_vectors.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/machine_vectors/vec1d_reduce_pm1no_to_0n.html (generated 2026-11-02).