public class StandardDouble extends java.lang.Object implements java.io.Serializable, Real
| Modifier and Type | Field and Description |
|---|---|
static StandardDouble |
SMALLEST
A StandardDouble representing the smallest possible value StandardDouble can represent
|
| Constructor and Description |
|---|
StandardDouble(double d)
Creates a StandardDouble representing the same number as a double
|
| Modifier and Type | Method and Description |
|---|---|
StandardDouble |
add(double o)
Adds this Real to a double
|
StandardDouble |
add(Real o)
Adds this Real to another
|
void |
addip(Real o)
Adds a Real to this Real in place.
|
void |
addproductip(Real o1,
double o2)
Adds the product of a Real and a double to this Real in place.
|
StandardDouble |
divide(double o)
Divides this Real by a double
|
StandardDouble |
divide(Real o)
Divides this Real by another one
|
boolean |
equals(java.lang.Object o) |
boolean |
greaterThan(double o)
Compares this real to a double
|
boolean |
greaterThan(Real o)
Compares this real to another
|
int |
hashCode() |
StandardDouble |
inverse()
Returns the inverse of this real (i.e.
|
double |
ln()
Returns the natural logarithm of this Real
|
double |
ln1m()
Returns the natural logithm of one minus the value of this Real
|
StandardDouble |
multiply(double o)
Multiplies this Real by a double
|
StandardDouble |
multiply(Real o)
Multiplies this Real by another
|
void |
multiplyip(double o)
Multiplies this Real by a double in place.
|
void |
multiplyip(Real o)
Multiplies this Real by another Real in place.
|
StandardDouble |
negate()
Negates this real.
|
StandardDouble |
subtract(double o)
Subtracts a double from this Real
|
StandardDouble |
subtract(Real o)
Subtracts another Real from this one
|
double |
toDouble()
Returns this real as a double.
|
SmallDouble |
toSmallDouble()
Returns this real as a SmallDouble
|
java.lang.String |
toString() |
public static final StandardDouble SMALLEST
public StandardDouble(double d)
d - The double to be representedpublic StandardDouble multiply(Real o)
Realpublic StandardDouble multiply(double o)
Realpublic StandardDouble add(Real o)
Realpublic StandardDouble add(double o)
Realpublic double ln()
Realpublic double ln1m()
Realpublic boolean greaterThan(Real o)
RealgreaterThan in interface Realo - The other realpublic boolean greaterThan(double o)
RealgreaterThan in interface Realo - The doublepublic StandardDouble subtract(Real o)
Realpublic StandardDouble subtract(double o)
Realpublic StandardDouble negate()
Realpublic StandardDouble inverse()
Realpublic StandardDouble divide(Real o)
Realpublic StandardDouble divide(double o)
Realpublic double toDouble()
Realpublic SmallDouble toSmallDouble()
RealtoSmallDouble in interface Realpublic void addip(Real o)
Realpublic void multiplyip(Real o)
Realmultiplyip in interface Realo - The real to multiply by.public void multiplyip(double o)
Realmultiplyip in interface Realo - The double to multiply by.public void addproductip(Real o1, double o2)
Realaddproductip in interface Realo1 - The real to be be used in the product.o2 - The double to be used in the product.public java.lang.String toString()
toString in class java.lang.Objectpublic boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Object