- All Superinterfaces:
Comparable<Number>,Number
An instance of this class represents a rational number.
-
Method Summary
Modifier and TypeMethodDescriptionReturns the denominator from a representation of this rational number as the quotient of two JavaBigIntegers.Returns the numerator from a representation of this rational number as the quotient of two JavaBigIntegers.Methods inherited from interface java.lang.Comparable
compareToMethods inherited from interface dev.civl.sarl.IF.number.Number
atomString, isInfinite, isOne, isZero, numericalCompareTo, signum
-
Method Details
-
numerator
BigInteger numerator()Returns the numerator from a representation of this rational number as the quotient of two JavaBigIntegers.
If this number is infinite, it will returnnull;- Returns:
- the numerator as a
BigInteger
-
denominator
BigInteger denominator()Returns the denominator from a representation of this rational number as the quotient of two JavaBigIntegers.
If this number is infinite, it will returnnull;- Returns:
- the denominator as a
BigInteger
-