_flint_mpn_poly_mulmid_classical
#include <flint/mpn_extras.h>void _flint_mpn_poly_mulmid_classical(nn_ptr res, nn_srcptr f, slong flen, slong n1, nn_srcptr g, slong glen, slong n2, slong nlo, slong nhi, slong s, int sgn)sourceSets to the coefficients of the product of and , viewed as polynomials with -limb respectively -limb coefficients, computed modulo by the classical algorithm. Requires and . The coefficients are unsigned for sgn = 0, two's complement for sgn = 1, and sign-magnitude for sgn = 2 (a sign limb followed by respectively magnitude limbs; the output is two's complement). The results are exact provided that the requested coefficients fit in limbs. Squaring is detected when f == g and flen == glen.
Each output coefficient is a dot product. For the function dispatches to the fused kernels of flint_mpn_poly_mulmid_tab; for and short lengths to those of flint_mpn_poly_mulmid_short_tab; otherwise to loops over the dot product kernels or flint_mpn_mul with mpn_add_n.
The FLINT team, “_flint_mpn_poly_mulmid_classical (mpn_extras.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/mpn_extras/_flint_mpn_poly_mulmid_classical.html (generated 2026-11-02).
@misc{flint-doc-mpn-extras-flint-mpn-poly-mulmid-classical,
author = {{The FLINT team}},
title = {{\_flint\_mpn\_poly\_mulmid\_classical (mpn\_extras.h)}},
howpublished = {FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev},
year = {2026},
url = {https://flintlib.org/doc/mpn_extras/_flint_mpn_poly_mulmid_classical.html},
note = {Generated 2026-11-02}
}