50 shapeToCell::typeName,
51 "\n Usage: shapeToCell tet|pyr|prism|hex|tetWedge|wedge|splitHex\n\n"
52 " Select all cells of given cellShape.\n"
53 " (splitHex hardcoded with internal angle < 10 degrees)\n"
65 if (shape_ ==
"splitHex")
67 for (label celli = 0; celli <
mesh_.
nCells(); ++celli)
105 if (!cellModel::ptr(shape_) && shape_ !=
"splitHex")
132 if (!cellModel::ptr(shape_) && shape_ !=
"splitHex")
152 Info<<
" Adding all " << shape_ <<
" cells ..." <<
endl;
161 Info<<
" Removing all " << shape_ <<
" cells ..." <<
endl;
Macros for easy insertion into run-time selection tables.
#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,...
static bool test(const UList< face > &faces)
Mesh consisting of general polyhedral cells.
const cellShapeList & cellShapes() const
Return cell shapes.
label nCells() const noexcept
Number of mesh cells.
A topoSetCellSource to select cells based on the type of their cell shapes.
static scalar featureCos
Cos of feature angle for polyHedral to be splitHex.
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.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
List< cellShape > cellShapeList
List of cellShapes and PtrList of List of cellShape.
messageStream Info
Information stream (stdout output on master, null elsewhere)
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)
errorManipArg< error, int > exit(error &err, const int errNo=1)
dimensionedScalar cos(const dimensionedScalar &ds)
dict add("bounds", meshBb)
#define forAll(list, i)
Loop across all elements in list.
Unit conversion functions.