Machine constants, general#
Zero, positive zero#
- property ctx.zero#
where
ctxismath53,ctxboostorctxflint.Returns \(+0\).
In extended precision (32 bit version of xlcalcnet)
>>> from xlcalcnet import xreal >>> xreal.Zero() xreal('0.0000000000000000000)
In double precision (64 bit version of xlcalcnet)
>>> from xlcalcnet import Gpr >>> Gpr.Zero() 0.0
Negative zero#
- property ctx.negzero#
where
ctxismath53,ctxboostorctxflint.Returns \(-0\).
In extended precision (32 bit version of xlcalcnet)
>>> from xlcalcnet import xreal >>> xreal.Zero() xreal('0.0000000000000000000)
In double precision (64 bit version of xlcalcnet)
>>> from xlcalcnet import Gpr >>> Gpr.Zero() 0.0
One#
- property Cxt.one#
where
ctxismath53,ctxboostorctxflint.Returns \(1\)
In extended precision (32 bit version of xlcalcnet)
>>> from xlcalcnet import xreal >>> xreal.One() xreal('1.0000000000000000000')
In double precision (64 bit version of xlcalcnet)
>>> from xlcalcnet import Gpr >>> Gpr.One() 1.0
Positive infinity#
- ctx.inf()#
where
ctxismath53,ctxboostorctxflint.Returns \(+\infty\)
In extended precision (32 bit version of xlcalcnet)
>>> from xlcalcnet import xreal >>> xreal.PositiveInfinity() xreal('+Inf')
In double precision (64 bit version of xlcalcnet)
>>> from xlcalcnet import Gpr >>> Gpr.PositiveInfinity() +Inf
Negative infinity#
- ctx.neginf()#
where
ctxismath53,ctxboostorctxflint.Returns the representation of \(-\infty\)
In extended precision (32 bit version of xlcalcnet)
>>> from xlcalcnet import xreal >>> xreal.NegativeInfinity() xreal('-Inf')
In double precision (64 bit version of xlcalcnet)
>>> from xlcalcnet import Gpr >>> Gpr.NegativeInfinity() -Inf
NaN (Not a Number)#
- ctx.nan()#
where
ctxismath53,ctxboostorctxflint.Returns
NaN(Not a Number).In extended precision (32 bit version of xlcalcnet)
>>> from xlcalcnet import xreal >>> xreal.Nan() xreal('Nan')
In double precision (64 bit version of xlcalcnet)
>>> from xlcalcnet import Gpr >>> Gpr.Nan() Nan