Determination and storage of the possible independent transforms introduced by coupledPolyPatches, as well as all of the possible permutations of these transforms generated by the presence of multiple coupledPolyPatches, i.e. more than one cyclic boundary. Note that any given point can be on maximum 3 transforms only (and these transforms have to be perpendicular) More...
Classes | |
class | less |
Less function class used in sorting encoded transforms and indices. More... | |
Public Member Functions | |
ClassName ("globalIndexAndTransform") | |
globalIndexAndTransform (const polyMesh &mesh) | |
Construct from components. More... | |
label | encodeTransformIndex (const labelList &permutationIndices) const |
Generate a transform index from the permutation indices of. More... | |
labelList | decodeTransformIndex (const label transformIndex) const |
Decode transform index. More... | |
label | addToTransformIndex (const label transformIndex, const label patchi, const bool isSendingSide=true, const scalar tol=SMALL) const |
Add patch transformation to transformIndex. Return new. More... | |
label | mergeTransformIndex (const label transformIndex0, const label transformIndex1) const |
Combine two transformIndices. More... | |
label | minimumTransformIndex (const label transformIndex0, const label transformIndex1) const |
Combine two transformIndices. More... | |
label | subtractTransformIndex (const label transformIndex0, const label transformIndex1) const |
Subtract two transformIndices. More... | |
labelPair | encode (const label index, const label transformIndex) const |
Encode index and bare index as components on own processor. More... | |
labelPair | encode (const label proci, const label index, const label transformIndex) const |
Encode index and bare index as components on given processor. More... | |
label | index (const labelPair &globalIAndTransform) const |
Index carried by the object. More... | |
label | processor (const labelPair &globalIAndTransform) const |
Which processor does this come from? More... | |
label | transformIndex (const labelPair &globalIAndTransform) const |
Transform carried by the object. More... | |
label | nIndependentTransforms () const |
Return the number of independent transforms. More... | |
const List< vectorTensorTransform > & | transforms () const |
Return access to the stored independent transforms. More... | |
const List< vectorTensorTransform > & | transformPermutations () const |
Return access to the permuted transforms. More... | |
label | nullTransformIndex () const |
Return the transformIndex (index in transformPermutations) More... | |
const List< labelPair > & | patchTransformSign () const |
Return access to the per-patch transform-sign pairs. More... | |
const vectorTensorTransform & | transform (label transformIndex) const |
Access the overall (permuted) transform corresponding. More... | |
labelList | transformIndicesForPatches (const labelHashSet &patchIs) const |
Access the all of the indices of the transform. More... | |
pointField | transformPatches (const labelHashSet &patchIs, const point &pt) const |
Apply all of the transform permutations. More... | |
Determination and storage of the possible independent transforms introduced by coupledPolyPatches, as well as all of the possible permutations of these transforms generated by the presence of multiple coupledPolyPatches, i.e. more than one cyclic boundary. Note that any given point can be on maximum 3 transforms only (and these transforms have to be perpendicular)
Also provides global index encoding and decoding for entity (i.e. cell) index, processor index and transform index (0 or positive integer) to a labelPair.
Definition at line 60 of file globalIndexAndTransform.H.
|
explicit |
Construct from components.
Definition at line 449 of file globalIndexAndTransform.C.
References polyMesh::boundaryMesh(), mapDistributeBase::constructSize(), globalMeshData::coupledPatch(), Foam::ensightOutput::debug, mapDistribute::distribute(), Foam::endl(), Pair< T >::first(), forAll, globalMeshData::globalCoPointSlaves(), globalMeshData::globalCoPointSlavesMap(), polyMesh::globalData(), vectorTensorTransform::hasR(), Foam::Info, PrimitivePatch< FaceList, PointField >::meshPoints(), Foam::constant::atomic::mp, primitiveMesh::nPoints(), globalIndexAndTransform::nullTransformIndex(), patches, polyMesh::points(), pp(), vectorTensorTransform::R(), and vectorTensorTransform::t().
ClassName | ( | "globalIndexAndTransform" | ) |
|
inline |
Generate a transform index from the permutation indices of.
the independent transforms. Permutations indices must only be -1, 0 or +1.
Definition at line 70 of file globalIndexAndTransformI.H.
References Foam::abort(), Foam::constant::physicoChemical::b, Foam::FatalError, FatalErrorInFunction, forAll, Foam::mag(), and UList< T >::size().
|
inline |
Decode transform index.
Definition at line 106 of file globalIndexAndTransformI.H.
References forAll, and Foam::Zero.
|
inline |
Add patch transformation to transformIndex. Return new.
transformIndex. (by default the patch is the sending, not the receiving, patch)
Definition at line 124 of file globalIndexAndTransformI.H.
References Foam::endl(), Foam::exit(), Foam::FatalError, FatalErrorInFunction, Pair< T >::first(), vectorTensorTransform::hasR(), Foam::labelMin, Foam::mag(), IOstream::name(), vectorTensorTransform::R(), R, Pair< T >::second(), Foam::sign(), vectorTensorTransform::t(), and Foam::tr().
|
inline |
Combine two transformIndices.
|
inline |
Combine two transformIndices.
Definition at line 235 of file globalIndexAndTransformI.H.
References forAll.
|
inline |
Subtract two transformIndices.
Definition at line 279 of file globalIndexAndTransformI.H.
References forAll.
|
inline |
Encode index and bare index as components on own processor.
Definition at line 297 of file globalIndexAndTransformI.H.
|
inline |
Encode index and bare index as components on given processor.
Definition at line 307 of file globalIndexAndTransformI.H.
References Foam::abort(), Foam::exit(), Foam::FatalError, FatalErrorInFunction, and Foam::labelMax.
|
inline |
Index carried by the object.
Definition at line 341 of file globalIndexAndTransformI.H.
References Pair< T >::first().
Referenced by mapDistribute::mapDistribute().
|
inline |
Which processor does this come from?
Definition at line 350 of file globalIndexAndTransformI.H.
References Pair< T >::second().
Referenced by mapDistribute::mapDistribute().
|
inline |
Transform carried by the object.
Definition at line 359 of file globalIndexAndTransformI.H.
References Pair< T >::second().
Referenced by mapDistribute::mapDistribute().
|
inline |
Return the number of independent transforms.
Definition at line 367 of file globalIndexAndTransformI.H.
|
inline |
Return access to the stored independent transforms.
Definition at line 374 of file globalIndexAndTransformI.H.
|
inline |
Return access to the permuted transforms.
Definition at line 381 of file globalIndexAndTransformI.H.
Referenced by mapDistribute::mapDistribute().
|
inline |
Return the transformIndex (index in transformPermutations)
of the identity transform
Definition at line 387 of file globalIndexAndTransformI.H.
Referenced by globalIndexAndTransform::globalIndexAndTransform().
|
inline |
Return access to the per-patch transform-sign pairs.
Definition at line 394 of file globalIndexAndTransformI.H.
|
inline |
Access the overall (permuted) transform corresponding.
to the transformIndex
Definition at line 401 of file globalIndexAndTransformI.H.
|
inline |
Access the all of the indices of the transform.
permutations corresponding the transforms of the listed patch indices. This only allows a maximum of three transformations (since routine is used to transform points and any given point can only be on 3 or less transforms)
Definition at line 410 of file globalIndexAndTransformI.H.
References Foam::constant::physicoChemical::b, HashTable< T, Key, Hash >::empty(), Foam::exit(), Foam::FatalError, FatalErrorInFunction, Pair< T >::first(), Foam::mag(), Foam::pow(), Pair< T >::second(), Foam::sign(), Foam::sum(), and Foam::Zero.
|
inline |
Apply all of the transform permutations.
corresponding the transforms of the listed patch indices to the supplied point
Definition at line 583 of file globalIndexAndTransformI.H.
References forAll, and UList< T >::size().