Templated 3D Vector derived from VectorSpace adding construction from 3 components, element access using x(), y() and z() member functions and the inner-product (dot-product) and cross product operators. More...
Public Types | |
enum | components { X, Y, Z } |
Component labeling enumeration. More... | |
typedef Vector< label > | labelType |
Equivalent type of labels used for valid component indexing. More... | |
Public Types inherited from VectorSpace< Vector< Cmpt >, Cmpt, 3 > | |
typedef VectorSpace< Vector< Cmpt >, Cmpt, Ncmpts > | vsType |
VectorSpace type. More... | |
typedef Cmpt | cmptType |
Component type. More... | |
Public Member Functions | |
Vector () | |
Construct null. More... | |
Vector (const Foam::zero) | |
Construct initialised to zero. More... | |
template<class Cmpt2 > | |
Vector (const VectorSpace< Vector< Cmpt2 >, Cmpt2, 3 > &) | |
Construct given VectorSpace of the same rank. More... | |
Vector (const Cmpt &vx, const Cmpt &vy, const Cmpt &vz) | |
Construct given three components. More... | |
Vector (Istream &) | |
Construct from Istream. More... | |
const Cmpt & | x () const |
const Cmpt & | y () const |
const Cmpt & | z () const |
Cmpt & | x () |
Cmpt & | y () |
Cmpt & | z () |
const Vector< Cmpt > & | centre (const Foam::List< Vector< Cmpt >> &) const |
Return *this (used for point which is a typedef to Vector<scalar>. More... | |
Public Member Functions inherited from VectorSpace< Vector< Cmpt >, Cmpt, 3 > | |
VectorSpace () | |
Construct null. More... | |
VectorSpace (const Foam::zero) | |
Construct initialised to zero. More... | |
VectorSpace (Istream &) | |
Construct from Istream. More... | |
VectorSpace (const VectorSpace< Form2, Cmpt2, Ncmpts > &) | |
Construct as copy of a VectorSpace with the same size. More... | |
const Cmpt & | component (const direction) const |
Cmpt & | component (const direction) |
void | component (Cmpt &, const direction) const |
void | replace (const direction, const Cmpt &) |
const ConstBlock< SubVector, BStart > | block () const |
const VectorSpace< Vector< Cmpt >, Cmpt, Ncmpts >::template ConstBlock< SubVector, BStart > | block () const |
const Cmpt & | operator[] (const direction) const |
Cmpt & | operator[] (const direction) |
void | operator+= (const VectorSpace< Vector< Cmpt >, Cmpt, Ncmpts > &) |
void | operator-= (const VectorSpace< Vector< Cmpt >, Cmpt, Ncmpts > &) |
void | operator= (const Foam::zero) |
void | operator*= (const scalar) |
void | operator/= (const scalar) |
Static Public Attributes | |
static const direction | rank = 1 |
Rank of Vector is 1. More... | |
Static Public Attributes inherited from VectorSpace< Vector< Cmpt >, Cmpt, 3 > | |
static const direction | dim |
Dimensionality of space. More... | |
static const direction | nComponents |
Number of components in this vector space. More... | |
static const direction | mRows |
static const direction | nCols |
static const char *const | typeName |
static const char *const | componentNames [] |
static const Vector< Cmpt > | zero |
static const Vector< Cmpt > | one |
static const Vector< Cmpt > | max |
static const Vector< Cmpt > | min |
static const Vector< Cmpt > | rootMax |
static const Vector< Cmpt > | rootMin |
Additional Inherited Members | |
Static Public Member Functions inherited from VectorSpace< Vector< Cmpt >, Cmpt, 3 > | |
static direction | size () |
Return the number of elements in the VectorSpace = Ncmpts. More... | |
static Vector< Cmpt > | uniform (const Cmpt &s) |
Return a VectorSpace with all elements = s. More... | |
Public Attributes inherited from VectorSpace< Vector< Cmpt >, Cmpt, 3 > | |
Cmpt | v_ [Ncmpts] |
The components of this vector space. More... | |
Templated 3D Vector derived from VectorSpace adding construction from 3 components, element access using x(), y() and z() member functions and the inner-product (dot-product) and cross product operators.
A centre() member function which returns the Vector for which it is called is defined so that point which is a typedef to Vector<scalar> behaves as other shapes in the shape hierarchy.
enum components |
|
inline |
Construct null.
Definition at line 29 of file VectorI.H.
Referenced by Vector< vector >::Vector().
|
inline |
|
inline |
Construct given VectorSpace of the same rank.
|
inline |
|
inline |
Definition at line 75 of file VectorI.H.
Referenced by biLinearFitPolynomial::addCoeffs(), cubicUpwindFitPolynomial::addCoeffs(), linearFitPolynomial::addCoeffs(), quadraticFitPolynomial::addCoeffs(), quadraticLinearUpwindFitPolynomial::addCoeffs(), quadraticUpwindFitPolynomial::addCoeffs(), quadraticLinearFitPolynomial::addCoeffs(), triad::align(), polygonTriangulate::angle(), sixDoFRigidBodyState::angularVelocity(), plane::aPoint(), BarycentricTensor< Cmpt >::BarycentricTensor(), BarycentricTensor2D< Cmpt >::BarycentricTensor2D(), Foam::meshTools::calcBoxPointNormals(), treeBoundBox::calcExtremities(), CentredFitSnGradData< Polynomial >::calcFit(), FitData< CentredFitSnGradData< Polynomial >, extendedCentredCellToFaceStencil, Polynomial >::calcFit(), rotorDiskSource::calculate(), edgeCollapser::checkMeshQuality(), molecule::constantProperties::constantProperties(), boundBox::contains(), boundBox::containsInside(), MaxwellianThermal< CloudType >::correct(), MixedDiffuseSpecular< CloudType >::correct(), cyclicPolyPatch::coupledEdges(), cyclicPolyPatch::coupledPoints(), treeBoundBox::distanceCmp(), Foam::eigenValues(), Foam::eigenVector(), Foam::eigenVectors(), pitchForkRing::energy(), treeBoundBox::extend(), treeBoundBox::faceBits(), indexedOctree< Foam::treeDataFace >::findLine(), dynamicTreeDataPoint::findNearest(), dynamicIndexedOctree< Foam::dynamicTreeDataPoint >::findNearest(), indexedOctree< Foam::treeDataFace >::findNearest(), pitchForkRing::force(), rigidBodyModel::forwardDynamics(), repatchMesh::getNearest(), waveSuperposition::height(), cellShapeControlMesh::insert(), cellShapeControlMesh::insertFar(), triangleFuncs::intersectBb(), treeBoundBox::intersects(), Foam::inv(), Rzyx::jcalc(), Rxyz::jcalc(), Ryxz::jcalc(), cellMDLimitedGrad< Type >::limitFace(), momentOfInertia::massPropertiesSolid(), conformalVoronoiMesh::maxSurfaceProtrusion(), molecule::move(), NamedEnum< compressibleField, 8 >::names(), boundBox::nearest(), twoDPointCorrector::normalDir(), Foam::operator &(), treeDataPoint::findNearestOp::operator()(), treeDataEdge::findNearestOp::operator()(), Foam::operator*(), Foam::operator/(), Foam::operator^(), boundBox::overlaps(), searchablePlate::overlaps(), dynamicIndexedOctree< Foam::dynamicTreeDataPoint >::overlaps(), indexedOctree< Foam::treeDataFace >::overlaps(), plane::planeCoeffs(), plane::planeIntersect(), polyTopoChange::pointRemoved(), boundBox::points(), tetrahedron< Point, PointRef >::pointToBarycentric(), treeBoundBox::posBits(), particle::prepareForInteractionListReferral(), particle::prepareForNonConformalCyclicTransfer(), triad::primaryDirection(), quaternion::quaternion(), quaternion::R(), AC3DsurfaceFormat< Face >::read(), Foam::readUpto(), Foam::rotationTensor(), treeBoundBox::searchOrder(), ThermoLookupTableInjection< CloudType >::setPositionAndCell(), ReactingLookupTableInjection< CloudType >::setPositionAndCell(), ReactingMultiphaseLookupTableInjection< CloudType >::setPositionAndCell(), MomentumLookupTableInjection< CloudType >::setPositionAndCell(), triad::sortxyz(), SpatialVector< scalar >::SpatialVector(), Foam::sqr(), Foam::triIntersect::srcPointTgtTriIntersection(), treeBoundBox::subBbox(), treeBoundBox::subOctant(), surfaceDisplacementPointPatchVectorField::surfaceDisplacementPointPatchVectorField(), Tensor< scalar >::Tensor(), Foam::toPoint(), coordinateRotation::transformPrincipal(), triad::triad(), pointConstraint::unconstrainedDirections(), joint::unitQuaternion(), waveSuperposition::velocity(), vtkInsertNextOpenFOAMPoint(), wallLayerCells::wallLayerCells(), X3DsurfaceFormat< Face >::write(), WRLsurfaceFormat< Face >::write(), SMESHsurfaceFormat< Face >::write(), OBJsurfaceFormat< Face >::write(), GTSsurfaceFormat< Face >::write(), AC3DsurfaceFormat< Face >::write(), OBJedgeFormat::write(), OBJstream::write(), rigidBodyState::write(), sixDoFRigidBodyState::write(), meshToMeshMethod::writeConnectivity(), VTKsurfaceFormatCore::writeHeader(), VTKedgeFormat::writeHeader(), Foam::meshTools::writeOBJ(), coupledPolyPatch::writeOBJ(), triSurfaceTools::writeOBJ(), treeBoundBox::writeOBJ(), cellCuts::writeOBJ(), moleculeCloud::writeXYZ(), Foam::Xinterpolate(), and Foam::XstepForwardsToNextPoint().
|
inline |
Definition at line 81 of file VectorI.H.
Referenced by biLinearFitPolynomial::addCoeffs(), cubicUpwindFitPolynomial::addCoeffs(), linearFitPolynomial::addCoeffs(), quadraticFitPolynomial::addCoeffs(), quadraticLinearUpwindFitPolynomial::addCoeffs(), quadraticUpwindFitPolynomial::addCoeffs(), quadraticLinearFitPolynomial::addCoeffs(), triad::align(), polygonTriangulate::angle(), sixDoFRigidBodyState::angularVelocity(), plane::aPoint(), BarycentricTensor< Cmpt >::BarycentricTensor(), BarycentricTensor2D< Cmpt >::BarycentricTensor2D(), Foam::meshTools::calcBoxPointNormals(), treeBoundBox::calcExtremities(), CentredFitSnGradData< Polynomial >::calcFit(), FitData< CentredFitSnGradData< Polynomial >, extendedCentredCellToFaceStencil, Polynomial >::calcFit(), rotorDiskSource::calculate(), edgeCollapser::checkMeshQuality(), molecule::constantProperties::constantProperties(), boundBox::contains(), boundBox::containsInside(), MaxwellianThermal< CloudType >::correct(), MixedDiffuseSpecular< CloudType >::correct(), cyclicPolyPatch::coupledEdges(), cyclicPolyPatch::coupledPoints(), treeBoundBox::distanceCmp(), Foam::eigenValues(), Foam::eigenVector(), Foam::eigenVectors(), pitchForkRing::energy(), treeBoundBox::extend(), treeBoundBox::faceBits(), indexedOctree< Foam::treeDataFace >::findLine(), dynamicTreeDataPoint::findNearest(), dynamicIndexedOctree< Foam::dynamicTreeDataPoint >::findNearest(), indexedOctree< Foam::treeDataFace >::findNearest(), pitchForkRing::force(), rigidBodyModel::forwardDynamics(), repatchMesh::getNearest(), waveSuperposition::height(), cellShapeControlMesh::insert(), cellShapeControlMesh::insertFar(), triangleFuncs::intersectBb(), treeBoundBox::intersects(), Foam::inv(), Rxyz::jcalc(), Ryxz::jcalc(), Rzyx::jcalc(), cellMDLimitedGrad< Type >::limitFace(), momentOfInertia::massPropertiesSolid(), conformalVoronoiMesh::maxSurfaceProtrusion(), molecule::move(), NamedEnum< compressibleField, 8 >::names(), boundBox::nearest(), twoDPointCorrector::normalDir(), Foam::operator &(), treeDataPoint::findNearestOp::operator()(), treeDataEdge::findNearestOp::operator()(), Foam::operator*(), Foam::operator/(), Foam::operator^(), boundBox::overlaps(), searchablePlate::overlaps(), dynamicIndexedOctree< Foam::dynamicTreeDataPoint >::overlaps(), indexedOctree< Foam::treeDataFace >::overlaps(), plane::planeCoeffs(), plane::planeIntersect(), polyTopoChange::pointRemoved(), boundBox::points(), tetrahedron< Point, PointRef >::pointToBarycentric(), treeBoundBox::posBits(), particle::prepareForInteractionListReferral(), particle::prepareForNonConformalCyclicTransfer(), triad::primaryDirection(), quaternion::quaternion(), quaternion::R(), AC3DsurfaceFormat< Face >::read(), Foam::readUpto(), Foam::rotationTensor(), treeBoundBox::searchOrder(), triad::sortxyz(), SpatialVector< scalar >::SpatialVector(), Foam::sqr(), Foam::triIntersect::srcPointTgtTriIntersection(), treeBoundBox::subBbox(), treeBoundBox::subOctant(), surfaceDisplacementPointPatchVectorField::surfaceDisplacementPointPatchVectorField(), Tensor< scalar >::Tensor(), Foam::toPoint(), coordinateRotation::transformPrincipal(), triad::triad(), pointConstraint::unconstrainedDirections(), joint::unitQuaternion(), waveSuperposition::velocity(), vtkInsertNextOpenFOAMPoint(), wallLayerCells::wallLayerCells(), X3DsurfaceFormat< Face >::write(), WRLsurfaceFormat< Face >::write(), SMESHsurfaceFormat< Face >::write(), OBJsurfaceFormat< Face >::write(), GTSsurfaceFormat< Face >::write(), AC3DsurfaceFormat< Face >::write(), OBJedgeFormat::write(), OBJstream::write(), meshToMeshMethod::writeConnectivity(), VTKsurfaceFormatCore::writeHeader(), VTKedgeFormat::writeHeader(), Foam::meshTools::writeOBJ(), coupledPolyPatch::writeOBJ(), triSurfaceTools::writeOBJ(), treeBoundBox::writeOBJ(), cellCuts::writeOBJ(), moleculeCloud::writeXYZ(), and Foam::Xinterpolate().
|
inline |
Definition at line 87 of file VectorI.H.
Referenced by biLinearFitPolynomial::addCoeffs(), linearFitPolynomial::addCoeffs(), quadraticFitPolynomial::addCoeffs(), quadraticLinearUpwindFitPolynomial::addCoeffs(), quadraticUpwindFitPolynomial::addCoeffs(), cubicUpwindFitPolynomial::addCoeffs(), quadraticLinearFitPolynomial::addCoeffs(), triad::align(), sixDoFRigidBodyState::angularVelocity(), plane::aPoint(), BarycentricTensor< Cmpt >::BarycentricTensor(), BarycentricTensor2D< Cmpt >::BarycentricTensor2D(), Foam::meshTools::calcBoxPointNormals(), treeBoundBox::calcExtremities(), CentredFitSnGradData< Polynomial >::calcFit(), FitData< CentredFitSnGradData< Polynomial >, extendedCentredCellToFaceStencil, Polynomial >::calcFit(), rotorDiskSource::calculate(), molecule::constantProperties::constantProperties(), boundBox::contains(), boundBox::containsInside(), MaxwellianThermal< CloudType >::correct(), MixedDiffuseSpecular< CloudType >::correct(), cyclicPolyPatch::coupledEdges(), cyclicPolyPatch::coupledPoints(), treeBoundBox::distanceCmp(), Foam::eigenValues(), Foam::eigenVector(), Foam::eigenVectors(), pitchForkRing::energy(), treeBoundBox::extend(), treeBoundBox::faceBits(), indexedOctree< Foam::treeDataFace >::findLine(), dynamicTreeDataPoint::findNearest(), dynamicIndexedOctree< Foam::dynamicTreeDataPoint >::findNearest(), indexedOctree< Foam::treeDataFace >::findNearest(), pitchForkRing::force(), rigidBodyModel::forwardDynamics(), repatchMesh::getNearest(), waveSuperposition::height(), cellShapeControlMesh::insert(), cellShapeControlMesh::insertFar(), triangleFuncs::intersectBb(), treeBoundBox::intersects(), Foam::inv(), Rxyz::jcalc(), Rzyx::jcalc(), Ryxz::jcalc(), cellMDLimitedGrad< Type >::limitFace(), momentOfInertia::massPropertiesSolid(), conformalVoronoiMesh::maxSurfaceProtrusion(), NamedEnum< compressibleField, 8 >::names(), boundBox::nearest(), twoDPointCorrector::normalDir(), Foam::operator &(), treeDataPoint::findNearestOp::operator()(), treeDataEdge::findNearestOp::operator()(), Foam::operator*(), Foam::operator/(), Foam::operator^(), boundBox::overlaps(), searchablePlate::overlaps(), dynamicIndexedOctree< Foam::dynamicTreeDataPoint >::overlaps(), indexedOctree< Foam::treeDataFace >::overlaps(), plane::planeCoeffs(), plane::planeIntersect(), polyTopoChange::pointRemoved(), boundBox::points(), tetrahedron< Point, PointRef >::pointToBarycentric(), treeBoundBox::posBits(), particle::prepareForInteractionListReferral(), particle::prepareForNonConformalCyclicTransfer(), triad::primaryDirection(), quaternion::quaternion(), quaternion::R(), AC3DsurfaceFormat< Face >::read(), Foam::readUpto(), Foam::rotationTensor(), treeBoundBox::searchOrder(), triad::sortxyz(), SpatialVector< scalar >::SpatialVector(), Foam::sqr(), Foam::triIntersect::srcPointTgtTriIntersection(), treeBoundBox::subBbox(), treeBoundBox::subOctant(), surfaceDisplacementPointPatchVectorField::surfaceDisplacementPointPatchVectorField(), Tensor< scalar >::Tensor(), Foam::toPoint(), coordinateRotation::transformPrincipal(), triad::triad(), joint::unitQuaternion(), layeredEngine::update(), waveSuperposition::velocity(), vtkInsertNextOpenFOAMPoint(), wallLayerCells::wallLayerCells(), X3DsurfaceFormat< Face >::write(), WRLsurfaceFormat< Face >::write(), SMESHsurfaceFormat< Face >::write(), GTSsurfaceFormat< Face >::write(), OBJsurfaceFormat< Face >::write(), AC3DsurfaceFormat< Face >::write(), OBJedgeFormat::write(), OBJstream::write(), meshToMeshMethod::writeConnectivity(), VTKsurfaceFormatCore::writeHeader(), VTKedgeFormat::writeHeader(), Foam::meshTools::writeOBJ(), coupledPolyPatch::writeOBJ(), triSurfaceTools::writeOBJ(), treeBoundBox::writeOBJ(), cellCuts::writeOBJ(), and moleculeCloud::writeXYZ().
|
inline |
Return *this (used for point which is a typedef to Vector<scalar>.
Definition at line 116 of file VectorI.H.
Referenced by cyclicPolyPatch::coupledEdges(), Foam::meshEdge(), Foam::min(), treeDataPrimitivePatch< PatchType >::overlaps(), surfaceFeatures::setFromStatus(), extendedEdgeMesh::sortPointsAndEdges(), and Vector< vector >::z().