FreeFOAM The Cross-Platform CFD Toolkit
Hosted by SourceForge:
Get FreeFOAM at SourceForge.net.
            Fast, secure and Free Open Source software downloads

Septernion class used to perform translations and rotations in 3D space. More...

#include <OpenFOAM/septernion.H>


Detailed Description

Septernion class used to perform translations and rotations in 3D space.

It is composed of a translation vector and rotation quaternion and as such has seven components hence the name "septernion" from the Latin to be consistent with quaternion rather than "hepternion" derived from the Greek.

Source files

Definition at line 65 of file septernion.H.

Collaboration diagram for septernion:

List of all members.

Public Member Functions

 septernion ()
 Construct null.
 septernion (const vector &t, const quaternion &r)
 Construct given a translation vector and rotation quaternion.
 septernion (const vector &t)
 Construct a pure translation septernion given a translation vector.
 septernion (const quaternion &r)
 Construct a pure rotation septernion given a rotation quaternion.
 septernion (Istream &)
 Construct from Istream.
const vector &  t () const
const quaternion &  r () const
vector &  t ()
quaternion &  r ()
vector  transform (const vector &v) const
 Transform the given vector.
vector  invTransform (const vector &v) const
 Inverse Transform the given vector.
void  operator= (const septernion &)
void  operator*= (const septernion &)
void  operator= (const vector &)
void  operator+= (const vector &)
void  operator-= (const vector &)
void  operator= (const quaternion &)
void  operator*= (const quaternion &)
void  operator/= (const quaternion &)
void  operator*= (const scalar)
void  operator/= (const scalar)

Static Public Attributes

static const char *const  typeName = "septernion"
static const septernion  zero
static const septernion  I

Friends

Istream &  operator>> (Istream &is, septernion &)
Ostream &  operator<< (Ostream &os, const septernion &C)

Constructor & Destructor Documentation

septernion (  ) [inline]

Construct null.

Definition at line 28 of file septernionI.H.

septernion ( const vector &   t,
const quaternion &   r  
) [inline]

Construct given a translation vector and rotation quaternion.

Definition at line 31 of file septernionI.H.

septernion ( const vector &   t  ) [inline, explicit]

Construct a pure translation septernion given a translation vector.

Definition at line 37 of file septernionI.H.

septernion ( const quaternion &   r  ) [inline, explicit]

Construct a pure rotation septernion given a rotation quaternion.

Definition at line 43 of file septernionI.H.

septernion ( Istream &   is  )

Construct from Istream.

Definition at line 38 of file septernion.C.


Member Function Documentation

Foam::vector & t (  ) [inline]

Definition at line 64 of file septernionI.H.

Foam::quaternion & r (  ) [inline]

Definition at line 70 of file septernionI.H.

Foam::vector transform ( const vector &   v  ) const [inline]

Transform the given vector.

Definition at line 76 of file septernionI.H.

References dimensionSet::transform.

Foam::vector invTransform ( const vector &   v  ) const [inline]

Inverse Transform the given vector.

Definition at line 82 of file septernionI.H.

void operator= ( const septernion &   tr  ) [inline]

Definition at line 90 of file septernionI.H.

void operator*= ( const septernion &   tr  ) [inline]

Definition at line 96 of file septernionI.H.

References septernion::r(), and septernion::t().

void operator= ( const vector &   t  ) [inline]

Definition at line 103 of file septernionI.H.

void operator+= ( const vector &   t  ) [inline]

Definition at line 108 of file septernionI.H.

void operator-= ( const vector &   t  ) [inline]

Definition at line 113 of file septernionI.H.

void operator= ( const quaternion &   r  ) [inline]

Definition at line 119 of file septernionI.H.

void operator*= ( const quaternion &   r  ) [inline]

Definition at line 124 of file septernionI.H.

void operator/= ( const quaternion &   r  ) [inline]

Definition at line 129 of file septernionI.H.

void operator*= ( const scalar   s  ) [inline]

Definition at line 135 of file septernionI.H.

void operator/= ( const scalar   s  ) [inline]

Definition at line 141 of file septernionI.H.


Friends And Related Function Documentation

Istream& operator>> ( Istream &   is,
septernion &    
) [friend]
Ostream& operator<< ( Ostream &   os,
const septernion &   C  
) [friend]

Member Data Documentation

const char *const typeName = "septernion" [static]

Definition at line 80 of file septernion.H.

const Foam::septernion zero [static]

Definition at line 82 of file septernion.H.

const Foam::septernion I [static]

Definition at line 83 of file septernion.H.


The documentation for this class was generated from the following files: