DEVELOPMENT EDITION · 769442725406
Library Reference
On this page

Package Ada.Numerics.Big_Numbers.Big_Reals

Ada.Numerics.Big_Numbers.Big_Reals (RM A.5.7), for specifications. As Big_Integers, the package is ghost: Big_Real values appear in contracts, assertions and ghost code, are reasoned about as the rational numbers (a Real sort in the solver), are exact in the interpreter, and are erased from the generated code.

Big_Real

type Big_Real is private;

To_Big_Real

function To_Big_Real (Arg : Big_Integer) return Big_Real
  with Global => null;
function "/" (Num, Den : Big_Integer) return Big_Real
  with Global => null, Pre => Den /= To_Big_Integer (0);

the quotient Num / Den, exactly

In_Range

function In_Range (Arg, Low, High : Big_Real) return Boolean
  with Global => null;
function "=" (L, R : Big_Real) return Boolean with Global => null;
function "<" (L, R : Big_Real) return Boolean with Global => null;
function "<=" (L, R : Big_Real) return Boolean with Global => null;
function ">" (L, R : Big_Real) return Boolean with Global => null;
function ">=" (L, R : Big_Real) return Boolean with Global => null;
function "-" (L : Big_Real) return Big_Real with Global => null;
function "abs" (L : Big_Real) return Big_Real with Global => null;
function "+" (L, R : Big_Real) return Big_Real with Global => null;
function "-" (L, R : Big_Real) return Big_Real with Global => null;
function "*" (L, R : Big_Real) return Big_Real with Global => null;
function "/" (L, R : Big_Real) return Big_Real
  with Global => null, Pre => R /= To_Big_Real (To_Big_Integer (0));
function "**" (L : Big_Real; R : Integer) return Big_Real
  with Global => null, Pre => R >= 0;

(Verada: non-negative powers only)

Min

function Min (L, R : Big_Real) return Big_Real with Global => null;

Max

function Max (L, R : Big_Real) return Big_Real with Global => null;