Takes the description of the block and the list of curved edges and creates a list of points on edges together with the weighting factors. More...
Public Member Functions | |
blockDescriptor (const cellShape &, const pointField &vertices, const blockEdgeList &, const blockFaceList &, const Vector< label > &density, const UList< gradingDescriptors > &expand, const word &zoneName="") | |
Construct from components. Optional cellSet/zone name. More... | |
blockDescriptor (const dictionary &dict, const label index, const pointField &vertices, const blockEdgeList &, const blockFaceList &, Istream &) | |
Construct from Istream. More... | |
const pointField & | vertices () const |
Reference to point field defining the block mesh. More... | |
const blockFaceList & | faces () const |
Return reference to the list of curved faces. More... | |
const cellShape & | blockShape () const |
Return the block shape. More... | |
const Vector< label > & | density () const |
Return the mesh density (number of cells) in the i,j,k directions. More... | |
const word & | zoneName () const |
Return the (optional) zone name. More... | |
label | nPoints () const |
Return the number of points. More... | |
label | nCells () const |
Return the number of cells. More... | |
const FixedList< label, 6 > & | curvedFaces () const |
Curved-face labels for each block-face (-1 for flat faces) More... | |
label | nCurvedFaces () const |
Number of curved faces in this block. More... | |
const point & | blockPoint (const label i) const |
Return block point for local label i. More... | |
label | pointLabel (const label i, const label j, const label k) const |
Vertex label offset for a particular i,j,k position. More... | |
label | facePointLabel (const label facei, const label i, const label j) const |
Face vertex label offset for a particular i,j,k position. More... | |
bool | vertex (const label i, const label j, const label k) const |
Return true if point i,j,k addresses a block vertex. More... | |
bool | edge (const label i, const label j, const label k) const |
Return true if point i,j,k addresses a block edge. More... | |
label | edgesPointsWeights (pointField(&edgePoints)[12], scalarList(&edgeWeights)[12]) const |
Calculate the points and weights for all edges. More... | |
bool | flatFaceOrEdge (const label i, const label j, const label k) const |
Return true if point i,j,k addresses a block flat face or edge. More... | |
FixedList< pointField, 6 > | facePoints (const pointField &points) const |
Return the list of face-points for all of the faces of the block. More... | |
void | correctFacePoints (FixedList< pointField, 6 > &) const |
Correct the location of the given face-points. More... | |
void | operator= (const blockDescriptor &)=delete |
Disallow default bitwise assignment. More... | |
Static Public Member Functions | |
static void | write (Ostream &, const label blocki, const dictionary &) |
Write block index with dictionary lookup. More... | |
Friends | |
Ostream & | operator<< (Ostream &, const blockDescriptor &) |
Takes the description of the block and the list of curved edges and creates a list of points on edges together with the weighting factors.
For a given block, the correspondence between the ordering of vertex labels and face labels is shown below. For vertex numbering in the sequence 0 to 7 (block, centre): faces 0 (f0) and 1 are left and right, respectively; faces 2 and 3 are front and back; and faces 4 and 5 are bottom and top:
7 ---- 6 f5 |\ |\ f3 | | 4 ---- 5 \ | 3 |--- 2 | \ | \| \| f2 f4 0 ---- 1 Z f0 ----- f1 | Y | / O --- X
Definition at line 80 of file blockDescriptor.H.
blockDescriptor | ( | const cellShape & | bshape, |
const pointField & | vertices, | ||
const blockEdgeList & | edges, | ||
const blockFaceList & | faces, | ||
const Vector< label > & | density, | ||
const UList< gradingDescriptors > & | expand, | ||
const word & | zoneName = "" |
||
) |
Construct from components. Optional cellSet/zone name.
Definition at line 152 of file blockDescriptor.C.
References Foam::exit(), Foam::FatalError, and FatalErrorInFunction.
blockDescriptor | ( | const dictionary & | dict, |
const label | index, | ||
const pointField & | vertices, | ||
const blockEdgeList & | edges, | ||
const blockFaceList & | faces, | ||
Istream & | is | ||
) |
Construct from Istream.
Definition at line 184 of file blockDescriptor.C.
References token::BEGIN_LIST, blockMesh::checkBlockFaceOrientation, Foam::exit(), Foam::FatalIOError, FatalIOErrorInFunction, token::info(), token::isPunctuation(), token::isWord(), token::pToken(), Istream::putBack(), List< T >::size(), dictionary::subOrEmptyDict(), and token::wordToken().
|
inline |
Reference to point field defining the block mesh.
Definition at line 28 of file blockDescriptorI.H.
Referenced by projectFace::project().
|
inline |
Return reference to the list of curved faces.
Definition at line 34 of file blockDescriptorI.H.
Referenced by block::New().
|
inline |
Return the block shape.
Definition at line 40 of file blockDescriptorI.H.
Referenced by Foam::operator<<(), and projectFace::project().
|
inline |
Return the mesh density (number of cells) in the i,j,k directions.
Definition at line 46 of file blockDescriptorI.H.
Referenced by block::cells(), Foam::faceNij(), Foam::facePoint(), Foam::facePointN(), Foam::operator<<(), and projectFace::project().
|
inline |
Return the (optional) zone name.
Definition at line 52 of file blockDescriptorI.H.
Referenced by Foam::operator<<().
|
inline |
Return the number of points.
Definition at line 58 of file blockDescriptorI.H.
|
inline |
Return the number of cells.
Definition at line 69 of file blockDescriptorI.H.
Referenced by block::cells().
|
inline |
Curved-face labels for each block-face (-1 for flat faces)
Definition at line 81 of file blockDescriptorI.H.
|
inline |
Number of curved faces in this block.
Definition at line 87 of file blockDescriptorI.H.
|
inline |
Return block point for local label i.
Definition at line 93 of file blockDescriptorI.H.
References blockDescriptor::pointLabel().
|
inline |
Vertex label offset for a particular i,j,k position.
Definition at line 100 of file blockDescriptorI.H.
References blockDescriptor::facePointLabel().
Referenced by blockDescriptor::blockPoint(), block::cells(), Foam::facePoint(), Foam::facePointN(), and blockDescriptor::facePoints().
|
inline |
Face vertex label offset for a particular i,j,k position.
Definition at line 116 of file blockDescriptorI.H.
References blockDescriptor::vertex().
Referenced by blockDescriptor::facePoints(), and blockDescriptor::pointLabel().
Return true if point i,j,k addresses a block vertex.
Definition at line 150 of file blockDescriptorI.H.
References blockDescriptor::edge().
Referenced by blockDescriptor::facePointLabel().
Return true if point i,j,k addresses a block edge.
Definition at line 163 of file blockDescriptorI.H.
References blockDescriptor::flatFaceOrEdge().
Referenced by blockDescriptor::vertex().
Foam::label edgesPointsWeights | ( | pointField(&) | edgePoints[12], |
scalarList(&) | edgeWeights[12] | ||
) | const |
Calculate the points and weights for all edges.
Return the number of curved edges
Definition at line 114 of file blockDescriptorEdges.C.
Return true if point i,j,k addresses a block flat face or edge.
Definition at line 176 of file blockDescriptorI.H.
Referenced by blockDescriptor::edge().
Foam::FixedList< Foam::pointField, 6 > facePoints | ( | const pointField & | points | ) | const |
Return the list of face-points for all of the faces of the block.
Definition at line 308 of file blockDescriptor.C.
References blockDescriptor::correctFacePoints(), blockDescriptor::facePointLabel(), k, blockDescriptor::pointLabel(), and FixedList< T, Size >::setSize().
Foam::label correctFacePoints | ( | FixedList< pointField, 6 > & | facePoints | ) | const |
Correct the location of the given face-points.
to lie on the faces of the block
Definition at line 365 of file blockDescriptor.C.
References forAll, and blockDescriptor::write().
Referenced by Foam::faceCorr(), and blockDescriptor::facePoints().
|
static |
Write block index with dictionary lookup.
Definition at line 385 of file blockDescriptor.C.
References dictionary::subDictPtr(), and Foam::blockMeshTools::write().
Referenced by blockDescriptor::correctFacePoints().
|
delete |
Disallow default bitwise assignment.
|
friend |