|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.lang.Number gnu.math.Numeric gnu.math.Quantity gnu.math.Complex gnu.math.RealNum
public abstract class RealNum
Field Summary |
---|
Fields inherited from class gnu.math.Numeric |
---|
CEILING, FLOOR, ROUND, TRUNCATE |
Constructor Summary | |
---|---|
RealNum()
|
Method Summary | |
---|---|
Numeric |
abs()
|
abstract Numeric |
add(java.lang.Object obj,
int k)
Return this + k * obj. |
static RealNum |
add(RealNum x,
RealNum y,
int k)
|
int |
compareTo(java.lang.Object o)
Implements the Comparable interface. |
abstract Numeric |
div(java.lang.Object obj)
|
static RealNum |
divide(RealNum x,
RealNum y)
|
Complex |
exp()
|
RealNum |
im()
The value of the imaginary component, as a RealNum. |
abstract boolean |
isNegative()
|
boolean |
isZero()
|
Complex |
log()
|
RealNum |
max(RealNum x)
|
RealNum |
min(RealNum x)
|
abstract Numeric |
mul(java.lang.Object obj)
|
RealNum |
re()
The value of the real component, as a RealNum. |
RealNum |
rneg()
|
abstract int |
sign()
Return 1 if >0; 0 if ==0; -1 if <0; -2 if NaN. |
Complex |
sin()
|
Complex |
sqrt()
|
static RealNum |
times(RealNum x,
RealNum y)
|
RatNum |
toExact()
Convert to an exact number. |
static IntNum |
toExactInt(double value)
Converts an integral double (such as a toInt result) to an IntNum. |
static IntNum |
toExactInt(double value,
int rounding_mode)
Converts real to an exact integer, with specified rounding mode. |
IntNum |
toExactInt(int rounding_mode)
Converts to an exact integer, with specified rounding mode. |
static double |
toInt(double d,
int rounding_mode)
Converts a real to an integer, according to a specified rounding mode. |
RealNum |
toInt(int rounding_mode)
Converts a real to an integer, according to a specified rounding mode. |
static IntNum |
toScaledInt(double f,
int k)
Convert double to (rounded) integer, after multiplying by 10**k. |
IntNum |
toScaledInt(int k)
Convert this to (rounded) integer, after multiplying by 10**k. |
static IntNum |
toScaledInt(RatNum r,
int k)
Convert rational to (rounded) integer, after multiplying by 10**k. |
Methods inherited from class gnu.math.Complex |
---|
add, addReversed, angle, compare, compare, divide, divReversed, doubleImagValue, doubleRealValue, doubleValue, equals, equals, imMinusOne, imOne, isExact, longValue, make, make, mulReversed, neg, neg, number, polar, polar, power, times, toString |
Methods inherited from class gnu.math.Quantity |
---|
add, compare, compareReversed, dimensions, divide, imValue, make, make, make, reValue, times, unit |
Methods inherited from class gnu.math.Numeric |
---|
add, div_inv, floatValue, geq, grt, intValue, mul_ident, power, sub, toString |
Methods inherited from class java.lang.Number |
---|
byteValue, shortValue |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public RealNum()
Method Detail |
---|
public final RealNum re()
Quantity
re
in class Quantity
public final RealNum im()
Quantity
im
in class Quantity
public abstract boolean isNegative()
public abstract int sign()
public RealNum max(RealNum x)
public RealNum min(RealNum x)
public static RealNum add(RealNum x, RealNum y, int k)
public static RealNum times(RealNum x, RealNum y)
public static RealNum divide(RealNum x, RealNum y)
public abstract Numeric add(java.lang.Object obj, int k)
Numeric
add
in class Complex
public abstract Numeric mul(java.lang.Object obj)
mul
in class Complex
public abstract Numeric div(java.lang.Object obj)
div
in class Complex
public Numeric abs()
abs
in class Complex
public final RealNum rneg()
public boolean isZero()
isZero
in class Complex
public RatNum toExact()
public static double toInt(double d, int rounding_mode)
public RealNum toInt(int rounding_mode)
public IntNum toExactInt(int rounding_mode)
public static IntNum toExactInt(double value, int rounding_mode)
public static IntNum toExactInt(double value)
public Complex exp()
exp
in class Complex
public Complex log()
log
in class Complex
public final Complex sin()
public final Complex sqrt()
sqrt
in class Complex
public static IntNum toScaledInt(double f, int k)
public static IntNum toScaledInt(RatNum r, int k)
public IntNum toScaledInt(int k)
public int compareTo(java.lang.Object o)
compareTo
in interface java.lang.Comparable
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |