|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.xinapse.multisliceimage.DoubleComplex
public final class DoubleComplex
A complex (real, imaginary) number, with double precision.
| Constructor Summary | |
|---|---|
DoubleComplex()
Creates a new DoubleComplex number, with zero real and imaginary parts. |
|
DoubleComplex(DoubleComplex c)
Creates a new DoubleComplex number, with the real and imaginary parts copied from an existing DoubleComplex. |
|
DoubleComplex(double r,
double i)
Creates a new DoubleComplex number, with the real and imaginary parts specified by the arguments. |
|
| Method Summary | |
|---|---|
boolean |
equals(java.lang.Object o)
Determines whether another object is equal to this DoubleComplex number. |
double |
getArg()
Returns the polar angle of this DoubleComplex number. |
double |
getImag()
Returns the imaginary part of this DoubleComplex number. |
double |
getMod()
Returns the modulus of this DoubleComplex number. |
double |
getReal()
Returns the real part of this DoubleComplex number. |
int |
hashCode()
Returns a hash code value for this Complex number. |
void |
polar(double mod,
double arg)
Set real and imaginary components of this DoubleComplex given the modulus and argument (in radians). |
void |
set(double r,
double i)
Sets the real and imaginary parts of this DoubleComplex number. |
void |
setImag(double i)
Sets the imaginary part of this DoubleComplex number. |
void |
setReal(double r)
Sets the real part of this DoubleComplex number. |
java.lang.String |
toString()
Returns a string representation of this DoubleComplex number. |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public DoubleComplex()
public DoubleComplex(double r,
double i)
r - the real part of the complex number.i - the imaginary part of the complex number.public DoubleComplex(DoubleComplex c)
c - the DoubleComplex to copy.| Method Detail |
|---|
public void set(double r,
double i)
r - the new real part of the complex number.i - the new imaginary part of the complex number.public void setReal(double r)
r - the new real part of the complex number.public void setImag(double i)
i - the new imaginary part of the complex number.
public void polar(double mod,
double arg)
mod - the modulus.arg - the argument in radians.public double getReal()
public double getImag()
public double getArg()
public double getMod()
public boolean equals(java.lang.Object o)
equals in class java.lang.Objecto - the object to compare with.
public int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||