FLINT3.7.0-dev

mag_sub, mag_sub_lower

Synopsis#include <flint/mag.h>
void mag_sub(mag_t res, const mag_t x, const mag_t y)source
void mag_sub_lower(mag_t res, const mag_t x, const mag_t y)source

Set res to an upper, respectively lower, bound for \max(x - y, 0).

To bound x - y from above, x should itself be an upper bound and y a lower bound; mag_sub_lower is typically used to bound a denominator such as 1 - |z| away from zero.

Cite this page

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