Go to the documentation of this file.
57 int main(
int argc,
char *argv[])
61 "Conformal Voronoi 2D automatic mesh generator"
92 const bool extrude = extrusionDict.
get<
bool>(
"extrude");
93 const bool overwrite =
args.
found(
"overwrite");
108 mesh.insertSurfacePointPairs();
109 mesh.boundaryConform();
123 Info<<
"Begin filtering short edges:" <<
endl;
128 Info<<
"Meshed surface after edge filtering :" <<
endl;
129 sef.fMesh().writeStats(
Info);
131 if (
mesh.meshControls().meshedSurfaceOutput())
133 Info<<
"Write .obj file of the 2D mesh: MeshedSurface.obj" <<
endl;
134 sef.fMesh().
write(
"MeshedSurface.obj");
140 Info<<
"Begin constructing a polyMesh:" <<
endl;
163 std::move(poly2DMesh.points()),
164 std::move(poly2DMesh.faces()),
165 std::move(poly2DMesh.owner()),
166 std::move(poly2DMesh.neighbour())
169 Info<<
"Constructing patches." <<
endl;
171 label countPatches = 0;
175 if (poly2DMesh.patchSizes()[patchi] != 0)
179 poly2DMesh.patchNames()[patchi],
180 poly2DMesh.patchSizes()[patchi],
181 poly2DMesh.patchStarts()[patchi],
183 pMesh.boundaryMesh(),
195 Info<<
"Begin extruding the polyMesh:" <<
endl;
203 extruder.addFrontBackPatches();
207 extruder.setRefinement(meshMod);
211 pMesh.updateMesh(morphMap());
221 pMesh.setInstance(
"constant");
226 Info<<
"Finished extruding in = "
This class filters short edges generated by the CV2D mesher.
IOdictionary is derived from dictionary and IOobject to give the dictionary automatic IO functionalit...
void createMesh()
Create the mesh.
Defines the attributes of an object for which implicit objectRegistry management is supported,...
A class for handling file names.
virtual bool write(const bool valid=true) const
Write mesh using IO settings from time.
static word defaultRegion
Return the default region name.
static word timeName(const scalar t, const int precision=precision_)
Direct mesh changes based on v1.3 polyTopoChange syntax.
static void addNote(const string ¬e)
Add extra notes for the usage information.
Ostream & endl(Ostream &os)
Add newline and flush stream.
T get(const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const
T get(const label index) const
Get a value from the argument at index.
Mesh consisting of general polyhedral cells.
#define forAll(list, i)
Loop across all elements in list.
virtual bool write(const bool valid=true) const
Write using setting from DB.
messageStream Info
Information stream (stdout output on master, null elsewhere)
Conformal-Voronoi 2D automatic mesher with grid or read initial points and point position relaxation ...
A patch is a list of labels that address the faces in the global face list.
runTime controlDict().readEntry("adjustTimeStep"
void setSize(const label newLen)
Same as resize()
static autoPtr< extrudeModel > New(const dictionary &dict)
Select null constructed.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
virtual bool loop()
Return true if run should continue and if so increment time.
virtual bool write(const token &tok)=0
Write token to stream or otherwise handle it.
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
const word & system() const
Return system name.
const word & executable() const noexcept
Name of executable without the path.
Convert a primitivePatch into a 2D polyMesh.
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
static const word null
An empty word.
const polyBoundaryMesh & patches
double cpuTimeIncrement() const
Return CPU time (in seconds) since last call to cpuTimeIncrement()
static void noParallel()
Remove the parallel options.
Given a 2D mesh insert all the topology changes to extrude. Does not work in parallel.
const word & constant() const
Return constant name.
static void addOption(const word &optName, const string ¶m="", const string &usage="", bool advanced=false)
Add an option to validOptions with usage information.
Foam::argList args(argc, argv)
bool found(const word &optName) const
Return true if the named option is found.