Forms the ratio of two integers while checking for Overflow/Underflow.
The function toProperFraction takes a real fractional number x and returns a pair ( n, f ) such that x = n + f, and:
n is an integral number with the same sign as x; andf is a ratio with the same type and sign as x, and with absolute value less than 1.Extract the numerator of the ratio in reduced form: the numerator and denominator have no common factor and the denominator is positive.
Extract the denominator of the ratio in reduced form: the numerator and denominator have no common factor and the denominator is positive.
round x returns the nearest integer to x: the even integer if x is equily distant between two integers.
Compare two Rationals, greater than precidate.
Adds two Rationals while checking for Overflow/Underflow.
Subtract one Rational from another while checking for Overflow/Underflow.
Multiply two Rationals while checking for Overflow/Underflow.
Divide two Rationals while checking for Overflow/Underflow.
Rase Rational to the power while checking for Overflow/Underflow
Arbitrary-precision rational numbers, represented as a ratio of two
Intvalues.