VMD

This is a Python binding to the C++ class Mantid::Kernel::VMD.

class mantid.kernel.VMD((object)self)
__init__((object)self) → None :
Default constructor gives an object with 1 dimension
__init__( (object)self, (float)val0, (float)val1) -> None :
Constructs a 2 dimensional vector at the point given
__init__( (object)self, (float)val0, (float)val1, (float)val2) -> None :
Constructs a 3 dimensional vector at the point given
__init__( (object)self, (float)val0, (float)val1, (float)val2, (float)val3) -> None :
Constructs a 4 dimensional vector at the point given
__init__( (object)self, (float)val0, (float)val1, (float)val2, (float)val3, (float)val4) -> None :
Constructs a 5 dimensional vector at the point given
__init__( (object)self, (float)val0, (float)val1, (float)val2, (float)val3, (float)val4, (float)val5) -> None :
Constructs a 6 dimensional vector at the point given
angle((VMD)self, (VMD)other) → float :

Returns the angle between the vectors in radians (0 < theta < pi). If the dimensions do not match a RuntimeError is raised

cross_prod((VMD)self, (VMD)other) → VMD :

Returns the cross product of this vector with another. If the number of dimensions do not match a RuntimeError is raised

getNumDims((VMD)self) → int :

Returns the number of dimensions the contained in the vector

norm((VMD)self) → float :

Returns the length of the vector

norm2((VMD)self) → float :

Returns the the squared length of the vector

normalize((VMD)self) → float :

Normalizes the length of the vector to unity and returns the length before it was normalized

scalar_prod((VMD)self, (VMD)other) → float :

Returns the scalar product of this vector with another. If the number of dimensions do not match a RuntimeError is raised