|
|||||||||
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
public abstract class Quantity
A quantity with a unit. This generalizes the DSSSL quantity type (to more than lengths).
Field Summary |
---|
Fields inherited from class gnu.math.Numeric |
---|
CEILING, FLOOR, ROUND, TRUNCATE |
Constructor Summary | |
---|---|
Quantity()
|
Method Summary | |
---|---|
Numeric |
abs()
|
Numeric |
add(java.lang.Object y,
int k)
Return this + k * obj. |
static Quantity |
add(Quantity x,
Quantity y,
int k)
|
Numeric |
addReversed(Numeric x,
int k)
Calculate x+k&this. |
int |
compare(java.lang.Object obj)
Return 1 if this>obj; 0 if this==obj; -1 if this |
static int |
compare(Quantity x,
Quantity y)
|
int |
compareReversed(Numeric x)
|
Dimensions |
dimensions()
|
Numeric |
div(java.lang.Object y)
|
static Quantity |
divide(Quantity x,
Quantity y)
|
Numeric |
divReversed(Numeric x)
|
double |
doubleImagValue()
The value of the imaginary component, as a double. |
double |
doubleValue()
The value of the real component, as a double. |
RealNum |
im()
The value of the imaginary component, as a RealNum. |
double |
imValue()
The value of the imaginary component, as a double. |
static Quantity |
make(Complex x,
Unit u)
|
static Quantity |
make(double re,
double im,
Unit unit)
|
static Quantity |
make(RealNum re,
RealNum im,
Unit unit)
|
Numeric |
mul(java.lang.Object y)
|
Numeric |
mulReversed(Numeric x)
|
Numeric |
neg()
|
abstract Complex |
number()
|
RealNum |
re()
The value of the real component, as a RealNum. |
double |
reValue()
The value of the real component, as a double. |
static Quantity |
times(Quantity x,
Quantity y)
|
java.lang.String |
toString(int radix)
|
Unit |
unit()
|
Methods inherited from class gnu.math.Numeric |
---|
add, div_inv, equals, floatValue, geq, grt, intValue, isExact, isZero, longValue, 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 Quantity()
Method Detail |
---|
public Unit unit()
public Dimensions dimensions()
public abstract Complex number()
public RealNum re()
public RealNum im()
public final double reValue()
public final double imValue()
public double doubleValue()
doubleValue
in class java.lang.Number
public double doubleImagValue()
public static Quantity make(Complex x, Unit u)
public static Quantity make(RealNum re, RealNum im, Unit unit)
public static Quantity make(double re, double im, Unit unit)
public Numeric neg()
neg
in class Numeric
public Numeric abs()
abs
in class Numeric
public static int compare(Quantity x, Quantity y)
public int compare(java.lang.Object obj)
Numeric
compare
in class Numeric
public int compareReversed(Numeric x)
compareReversed
in class Numeric
public static Quantity add(Quantity x, Quantity y, int k)
public Numeric add(java.lang.Object y, int k)
Numeric
add
in class Numeric
public Numeric addReversed(Numeric x, int k)
Numeric
addReversed
in class Numeric
public static Quantity times(Quantity x, Quantity y)
public Numeric mul(java.lang.Object y)
mul
in class Numeric
public Numeric mulReversed(Numeric x)
mulReversed
in class Numeric
public static Quantity divide(Quantity x, Quantity y)
public Numeric div(java.lang.Object y)
div
in class Numeric
public Numeric divReversed(Numeric x)
divReversed
in class Numeric
public java.lang.String toString(int radix)
toString
in class Numeric
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |