|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.ObjectJSci.maths.vectors.MathVector
JSci.maths.vectors.AbstractComplexVector
JSci.maths.vectors.Complex3Vector
An optimised implementation of a 3D complex vector.
| Field Summary | |
protected double |
xim
|
protected double |
xre
|
protected double |
yim
|
protected double |
yre
|
protected double |
zim
|
protected double |
zre
|
| Fields inherited from class JSci.maths.vectors.MathVector |
N |
| Constructor Summary | |
Complex3Vector()
Constructs an empty 3-vector. |
|
Complex3Vector(Complex x,
Complex y,
Complex z)
Constructs a 3-vector. |
|
Complex3Vector(double xRe,
double xIm,
double yRe,
double yIm,
double zRe,
double zIm)
|
|
| Method Summary | |
AbelianGroup.Member |
add(AbelianGroup.Member vec)
Returns the addition of this vector and another. |
AbstractComplexVector |
add(AbstractComplexVector vec)
Returns the addition of this vector and another. |
AbstractComplexVector |
add(AbstractDoubleVector vec)
Returns the addition of this vector and another. |
AbstractComplexVector |
add(AbstractIntegerVector vec)
Returns the addition of this vector and another. |
AbstractComplexVector |
conjugate()
Returns the complex conjugate of this vector. |
boolean |
equals(java.lang.Object obj)
Compares two complex vectors for equality. |
Complex |
getComponent(int n)
Returns a component of this vector. |
double |
getImagComponent(int n)
|
double |
getRealComponent(int n)
|
AbstractDoubleVector |
imag()
Returns the imaginary part of this complex 3-vector. |
double |
infNorm()
Returns the l -norm. |
AbstractComplexVector |
mapComponents(ComplexMapping mapping)
Applies a function on all the vector components. |
Complex3Vector |
multiply(Complex3Vector vec)
Returns the vector product of this vector and another. |
AbelianGroup.Member |
negate()
Returns the negative of this vector. |
double |
norm()
Returns the l2-norm (magnitude). |
AbstractDoubleVector |
real()
Returns the real part of this complex 3-vector. |
AbstractComplexVector |
scalarDivide(Complex z)
Returns the division of this vector by a scalar. |
AbstractComplexVector |
scalarDivide(double k)
Returns the division of this vector by a scalar. |
VectorSpace.Member |
scalarDivide(Field.Member x)
Returns the division of this vector by a scalar. |
AbstractComplexVector |
scalarMultiply(Complex z)
Returns the multiplication of this vector by a scalar. |
AbstractComplexVector |
scalarMultiply(double k)
Returns the multiplication of this vector by a scalar. |
Module.Member |
scalarMultiply(Ring.Member x)
Returns the multiplication of this vector by a scalar. |
Complex |
scalarProduct(AbstractComplexVector vec)
Returns the scalar product of this vector and another. |
Complex |
scalarProduct(Complex3Vector vec)
Returns the scalar product of this vector and another. |
Complex |
scalarProduct(HilbertSpace.Member vec)
Returns the scalar product of this vector and another. |
void |
setComponent(int n,
Complex z)
Sets the value of a component of this vector. |
void |
setComponent(int n,
double x,
double y)
Sets the value of a component of this vector. |
AbelianGroup.Member |
subtract(AbelianGroup.Member vec)
Returns the subtraction of this vector by another. |
AbstractComplexVector |
subtract(AbstractComplexVector vec)
Returns the subtraction of this vector by another. |
AbstractComplexVector |
subtract(AbstractDoubleVector vec)
Returns the subtraction of this vector by another. |
AbstractComplexVector |
subtract(AbstractIntegerVector vec)
Returns the subtraction of this vector by another. |
java.lang.String |
toString()
Returns a comma delimited string representing the value of this vector. |
| Methods inherited from class JSci.maths.vectors.AbstractComplexVector |
hashCode, normalize |
| Methods inherited from class JSci.maths.vectors.MathVector |
dimension, getInvalidComponentMsg |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
protected double xre
protected double xim
protected double yre
protected double yim
protected double zre
protected double zim
| Constructor Detail |
public Complex3Vector()
public Complex3Vector(Complex x,
Complex y,
Complex z)
x - x coordinate.y - y coordinate.z - z coordinate.
public Complex3Vector(double xRe,
double xIm,
double yRe,
double yIm,
double zRe,
double zIm)
| Method Detail |
public boolean equals(java.lang.Object obj)
equals in class AbstractComplexVectorobj - a complex 3-vectorpublic java.lang.String toString()
toString in class AbstractComplexVectorpublic AbstractDoubleVector real()
real in class AbstractComplexVectorpublic AbstractDoubleVector imag()
imag in class AbstractComplexVectorpublic Complex getComponent(int n)
getComponent in class AbstractComplexVectorn - index of the vector component
VectorDimensionException - If attempting to access an invalid component.public double getRealComponent(int n)
getRealComponent in class AbstractComplexVectorpublic double getImagComponent(int n)
getImagComponent in class AbstractComplexVector
public void setComponent(int n,
Complex z)
setComponent in class AbstractComplexVectorn - index of the vector componentz - a complex number
VectorDimensionException - If attempting to access an invalid component.
public void setComponent(int n,
double x,
double y)
setComponent in class AbstractComplexVectorn - index of the vector componentx - the real part of a complex numbery - the imaginary part of a complex number
VectorDimensionException - If attempting to access an invalid component.public double norm()
norm in interface BanachSpace.Membernorm in class AbstractComplexVectorpublic double infNorm()
-norm.
infNorm in class AbstractComplexVectorpublic AbelianGroup.Member negate()
public AbstractComplexVector conjugate()
conjugate in class AbstractComplexVectorpublic AbelianGroup.Member add(AbelianGroup.Member vec)
vec - a group memberpublic AbstractComplexVector add(AbstractComplexVector vec)
add in class AbstractComplexVectorvec - a complex vectorpublic AbstractComplexVector add(AbstractDoubleVector vec)
public AbstractComplexVector add(AbstractIntegerVector vec)
public AbelianGroup.Member subtract(AbelianGroup.Member vec)
vec - a group memberpublic AbstractComplexVector subtract(AbstractComplexVector vec)
subtract in class AbstractComplexVectorvec - a complex vectorpublic AbstractComplexVector subtract(AbstractDoubleVector vec)
public AbstractComplexVector subtract(AbstractIntegerVector vec)
public Module.Member scalarMultiply(Ring.Member x)
x - a ring memberpublic AbstractComplexVector scalarMultiply(Complex z)
scalarMultiply in class AbstractComplexVectorz - a complex number
public AbstractComplexVector scalarMultiply(double k)
scalarMultiply in class AbstractComplexVectork - a double
public VectorSpace.Member scalarDivide(Field.Member x)
x - a field memberpublic AbstractComplexVector scalarDivide(Complex z)
scalarDivide in class AbstractComplexVectorz - a complex number
java.lang.ArithmeticException - If divide by zero.public AbstractComplexVector scalarDivide(double k)
scalarDivide in class AbstractComplexVectork - a double
java.lang.ArithmeticException - If divide by zero.public Complex scalarProduct(HilbertSpace.Member vec)
vec - a Hilbert space vectorpublic Complex scalarProduct(AbstractComplexVector vec)
scalarProduct in class AbstractComplexVectorvec - a complex vector
VectorDimensionException - If the vectors are different sizes.public Complex scalarProduct(Complex3Vector vec)
vec - a complex 3-vectorpublic Complex3Vector multiply(Complex3Vector vec)
vec - a complex 3-vectorpublic AbstractComplexVector mapComponents(ComplexMapping mapping)
mapComponents in class AbstractComplexVectormapping - a user-defined function
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||