calc
Class MoreVektorOps

java.lang.Object
  extended by calc.MoreVektorOps

public class MoreVektorOps
extends java.lang.Object

More unusual, but in this case useful Vector operations. Standard operations are defined in VektorOps. Here more "exotic" operations can be found. They are implemented as static functions.


Constructor Summary
MoreVektorOps()
           
 
Method Summary
static Vektor halfway(Vektor a, Vektor b)
          Intermediate point between a and b.
static Vektor identicalVektor(Vektor A)
          Returns the same vector as the input vector.
static Vektor mirrorX(Vektor A)
          Mirrors the vector at the YZ-plane.
static Vektor mirrorY(Vektor A)
          Mirrors the vector at the XZ-plane.
static Vektor mirrorZ(Vektor A)
          Mirrors the vector at the XY-plane.
static Vektor orthoVektor(Vektor A, Vektor B, Vektor C, double u, double v, double w)
           
static Vektor reziprokVektorA(Vektor ATilde, Vektor BTilde, Vektor CTilde)
          Gives the first reciprocal lattice vector.
static Vektor reziprokVektorB(Vektor ATilde, Vektor BTilde, Vektor CTilde)
          Gives the second reciprocal lattice vector.
static Vektor reziprokVektorC(Vektor ATilde, Vektor BTilde, Vektor CTilde)
          Gives the third reciprocal lattice vector.
static Vektor triVektor(Vektor A, Vektor B, Vektor C, double u, double v, double w)
          Linear combination of reciprocal base vectors.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MoreVektorOps

public MoreVektorOps()
Method Detail

reziprokVektorA

public static Vektor reziprokVektorA(Vektor ATilde,
                                     Vektor BTilde,
                                     Vektor CTilde)
Gives the first reciprocal lattice vector. The first reciprocal lattice vector, as defined by A = (b x c) / (a.(b x c))

Parameters:
ATilde - Vektor a in the spatial lattice.
BTilde - Vektor c in the spatial lattice.
CTilde - Vektor c in the spatial lattice.
Returns:
Vektor A in the reciprocal lattice.

reziprokVektorB

public static Vektor reziprokVektorB(Vektor ATilde,
                                     Vektor BTilde,
                                     Vektor CTilde)
Gives the second reciprocal lattice vector. The second reciprocal lattice vector, as defined by B = (c x a) / (a.(b x c))

Parameters:
ATilde - Vektor a in the spatial lattice.
BTilde - Vektor c in the spatial lattice.
CTilde - Vektor c in the spatial lattice.
Returns:
Vektor B in the reciprocal lattice.

reziprokVektorC

public static Vektor reziprokVektorC(Vektor ATilde,
                                     Vektor BTilde,
                                     Vektor CTilde)
Gives the third reciprocal lattice vector. The first reciprocal lattice vector, as defined by C = (a x b) / (a.(b x c))

Parameters:
ATilde - Vektor a in the spatial lattice.
BTilde - Vektor c in the spatial lattice.
CTilde - Vektor c in the spatial lattice.
Returns:
Vektor C in the reciprocal lattice.

triVektor

public static Vektor triVektor(Vektor A,
                               Vektor B,
                               Vektor C,
                               double u,
                               double v,
                               double w)
Linear combination of reciprocal base vectors. Gives the Vector, which is calculated by D = u*A + v*B + w*C;

Parameters:
A - base vector A
B - base vector B
C - base vector C
u - linear coefficient u
v - linear coefficient v
w - linear coefficient w
Returns:
Linear combination of A, B and C

orthoVektor

public static Vektor orthoVektor(Vektor A,
                                 Vektor B,
                                 Vektor C,
                                 double u,
                                 double v,
                                 double w)

identicalVektor

public static Vektor identicalVektor(Vektor A)
Returns the same vector as the input vector. Definetely an unneccesary operation, but sometimes useful to handle vector names less messy.

Parameters:
A -
Returns:
A, the same as the input vector.

halfway

public static Vektor halfway(Vektor a,
                             Vektor b)
Intermediate point between a and b. The return vector is calculated by c = (a + b)/2

Parameters:
a - One point
b - Another point
Returns:
The point exactly in between

mirrorX

public static Vektor mirrorX(Vektor A)
Mirrors the vector at the YZ-plane. That means A_x is replaced with -A_x

Parameters:
A - a vector
Returns:
mirrored A

mirrorY

public static Vektor mirrorY(Vektor A)
Mirrors the vector at the XZ-plane. That means A_y is replaced with -A_y

Parameters:
A - a vector
Returns:
mirrored A

mirrorZ

public static Vektor mirrorZ(Vektor A)
Mirrors the vector at the XY-plane. That means A_z is replaced with -A_z

Parameters:
A - a vector
Returns:
mirrored A