Did you know ... | Search Documentation: |
Function rational/1 |
rational(0.1)
. The function rationalize/1
remedies this. See section
4.27.2.2 for more information on rational number support.
?- A is rational(0.25). A is 1r4 ?- A is rational(0.1). A = 3602879701896397r36028797018963968
For every normal float X the relation
X
rational(X) holds.
=:=
This function raises an evaluation_error(undefined)
if Expr
is NaN and evaluation_error(rational_overflow)
if Expr
is Inf.