62 rotatedBoxToCell::typeName,
63 "\n Usage: rotatedBoxToCell (originx originy originz)"
64 " (ix iy iz) (jx jy jz) (kx ky kz)\n\n"
65 " Select all cells with cellCentre within parallelopiped\n\n"
75 boxPoints[0] = origin_;
76 boxPoints[1] = origin_ + i_;
77 boxPoints[2] = origin_ + i_ + j_;
78 boxPoints[3] = origin_ + j_;
79 boxPoints[4] = origin_ + k_;
80 boxPoints[5] = origin_ + k_ + i_;
81 boxPoints[6] = origin_ + k_ + i_ + j_;
82 boxPoints[7] = origin_ + k_ + j_;
89 faceList boxFaces(cellShape(
hex, boxVerts).faces());
95 boxFaceNormals[i] = boxFaces[i].areaNormal(boxPoints);
111 const face&
f = boxFaces[i];
113 if (((ctrs[celli] - boxPoints[
f[0]]) & boxFaceNormals[i]) > 0)
186 Info<<
" Adding cells with centre within rotated box"
196 Info<<
" Removing cells with centre within rotated box"
Macros for easy insertion into run-time selection tables.
#define addNamedToRunTimeSelectionTable(baseType, thisType, argNames, lookupName)
Add to construction table with 'lookupName' as the key.
#define addToRunTimeSelectionTable(baseType, thisType, argNames)
Add to construction table with typeName as the key.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
reference ref() const
A reference to the entry (Error if not found)
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Mesh consisting of general polyhedral cells.
const vectorField & cellCentres() const
A topoSetCellSource to select cells based on cell centres inside a given parallopiped (i....
virtual void applyToSet(const topoSetSource::setAction action, topoSet &set) const
Apply specified action to the topoSet.
The topoSetCellSource is a intermediate class for handling topoSet sources for selecting cells.
Class with constructor to add usage string to table.
Base class of a source for a topoSet.
void addOrDelete(topoSet &set, const label id, const bool add) const
Add or delete id from set. Add when 'add' is true.
setAction
Enumeration defining various actions.
@ SUBTRACT
Subtract elements from current set.
@ ADD
Add elements to current set.
@ NEW
Create a new set and ADD elements to it.
const polyMesh & mesh_
Reference to the mesh.
General set of labels of mesh quantity (points, cells, faces).
A class for handling words, derived from Foam::string.
#define defineTypeNameAndDebug(Type, DebugSwitch)
Define the typeName and debug information.
labelList identity(const label len, label start=0)
Return an identity map of the given length with (map[i] == i)
List< label > labelList
A List of labels.
messageStream Info
Information stream (stdout output on master, null elsewhere)
vectorField pointField
pointField is a vectorField.
Ostream & endl(Ostream &os)
Add newline and flush stream.
void add(FieldField< Field1, typename typeOfSum< Type1, Type2 >::type > &f, const FieldField< Field1, Type1 > &f1, const FieldField< Field2, Type2 > &f2)
Field< vector > vectorField
Specialisation of Field<T> for vector.
List< face > faceList
A List of faces.
dict add("bounds", meshBb)
#define forAll(list, i)
Loop across all elements in list.