63 const wordRes& regionNameMatcher
74 if (regionNameMatcher.match(names[regioni]))
76 regionIds[
count++] = regioni;
79 regionIds.setSize(count);
88 const dictionary&
dict
91 const word subGeomName(
dict.
get<word>(
"surface"));
93 const triSurfaceMesh&
s =
100 if (regionMap.empty())
103 <<
"Found no regions in triSurface matching " <<
regionNames
108 labelList reverseRegionMap(
s.patches().size(), -1);
111 reverseRegionMap[regionMap[i]] = i;
117 if (reverseRegionMap[
s.triSurface::operator[](triI).region()] != -1)
119 isSelected[triI] =
true;
123 return s.subsetMesh(isSelected);
Macros for easy insertion into run-time selection tables.
#define addToRunTimeSelectionTable(baseType, thisType, argNames)
Add to construction table with typeName as the key.
Defines the attributes of an object for which implicit objectRegistry management is supported,...
const objectRegistry & db() const noexcept
Return the local objectRegistry.
void size(const label n)
Older name for setAddressableSize.
wordList patchNames() const
Get names of patches.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
T get(const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const
wordList names() const
The unsorted names of all objects.
const Type & lookupObject(const word &name, const bool recursive=false) const
Base class of (analytical or triangulated) surface. Encapsulates all the search routines....
On-the-fly subset of triSurfaceMesh (based on selected patches)
IOoject and searching on triSurface.
Triangulated surface description with patch information.
const geometricSurfacePatchList & patches() const noexcept
#define defineTypeNameAndDebug(Type, DebugSwitch)
Define the typeName and debug information.
#define FatalIOErrorInFunction(ios)
Report an error message using Foam::FatalIOError.
gmvFile<< "tracers "<< particles.size()<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().x()<< " ";}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().y()<< " ";}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().z()<< " ";}gmvFile<< nl;forAll(lagrangianScalarNames, i){ word name=lagrangianScalarNames[i];IOField< scalar > s(IOobject(name, runTime.timeName(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE))
IOobject io("surfaceFilmProperties", mesh.time().constant(), mesh, IOobject::READ_IF_PRESENT, IOobject::NO_WRITE, false)
unsigned int count(const UList< bool > &bools, const bool val=true)
Count number of 'true' entries.
List< word > names(const UPtrList< T > &list, const UnaryMatchPredicate &matcher)
List< word > wordList
A List of words.
List< label > labelList
A List of labels.
List< T > subset(const BoolListType &select, const UList< T > &input, const bool invert=false)
Extract elements of the input list when select is true.
List< bool > boolList
A List of bools.
errorManipArg< error, int > exit(error &err, const int errNo=1)
wordList patchNames(nPatches)
#define forAll(list, i)
Loop across all elements in list.