FLINT3.7.0-dev

ca_add_fmpq, ca_add_fmpz, ca_add_ui, ca_add_si, ca_add

Synopsis#include <flint/ca.h>
void ca_add_fmpq(ca_t res, const ca_t x, const fmpq_t y, ca_ctx_t ctx)source
void ca_add_fmpz(ca_t res, const ca_t x, const fmpz_t y, ca_ctx_t ctx)source
void ca_add_ui(ca_t res, const ca_t x, ulong y, ca_ctx_t ctx)source
void ca_add_si(ca_t res, const ca_t x, slong y, ca_ctx_t ctx)source
void ca_add(ca_t res, const ca_t x, const ca_t y, ca_ctx_t ctx)source

Sets res to x + y.

For special values:

  • c \infty + d \infty = c \infty if c = d, and Undefined if c \ne d (Unknown if this cannot be decided);
  • \tilde \infty + \tilde \infty and \tilde \infty + c \infty are Undefined;
  • c \infty + z = c \infty and \tilde \infty + z = \tilde \infty;
  • Undefined plus any value, including Unknown, is Undefined; otherwise Unknown plus any value is Unknown.

Guides#

Cite this page

The FLINT team, “ca_add_fmpq, ca_add_fmpz, ca_add_ui, ca_add_si, ca_add (ca.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/ca/ca_add_fmpq.html (generated 2026-10-20).