51 regionToCell::typeName,
52 "\n Usage: regionToCell subCellSet (x y z)\n\n"
53 " Select all cells in the connected region containing point.\n"
54 " If started inside the subCellSet keeps to it;\n"
55 " if started outside stays outside.\n"
61 void Foam::regionToCell::combine(topoSet&
set,
const bool add)
const
68 Info<<
"Loading subset " << setName_ <<
" to delimit search region."
70 cellSet subSet(
mesh_, setName_);
75 inSubset[iter.key()] =
true;
78 if (cellI != -1 && inSubset[cellI])
80 Pout<<
"Point " << insidePoint_ <<
" is inside cellSet "
82 <<
"Collecting all cells connected to " << cellI
83 <<
" and inside cellSet " << setName_ <<
endl;
87 Pout<<
"Point " << insidePoint_ <<
" is outside cellSet "
89 <<
"Collecting all cells connected to " << cellI
90 <<
" and outside cellSet " << setName_ <<
endl;
96 for (label faceI = nInt; faceI <
mesh_.
nFaces(); faceI++)
103 for (label faceI = 0; faceI < nInt; faceI++)
107 blockedFace[faceI] = (ownInSet != neiInSet);
109 for (label faceI = nInt; faceI <
mesh_.
nFaces(); faceI++)
112 bool neiInSet = neiSet[faceI-nInt];
113 blockedFace[faceI] = (ownInSet != neiInSet);
118 regionSplit regions(
mesh_, blockedFace);
126 regionI = regions[cellI];
129 reduce(regionI, maxOp<label>());
135 "regionToCell::combine(topoSet&, const bool) const"
136 ) <<
"Point " << insidePoint_
137 <<
" is not inside the mesh." <<
nl
161 const point& insidePoint
166 insidePoint_(insidePoint)
178 setName_(dict.
lookup(
"set")),
179 insidePoint_(dict.
lookup(
"insidePoint"))
191 setName_(checkIs(is)),
192 insidePoint_(checkIs(is))
212 Info<<
" Adding all cells of connected region containing point "
213 << insidePoint_ <<
" ..." <<
endl;
219 Info<<
" Removing all cells of connected region containing point "
220 << insidePoint_ <<
" ..." <<
endl;