createNamedFaMesh.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration |
5  \\ / A nd | www.openfoam.com
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8  Copyright (C) 2023 OpenCFD Ltd.
9 -------------------------------------------------------------------------------
10 License
11  This file is part of OpenFOAM, distributed under GPL-3.0-or-later.
12 
13 Description
14  Create a finite-area mesh for a specified region, or the defaultRegion
15 
16 Required Classes
17  - Foam::polyMesh
18 
19 Required Variables
20  - mesh [polyMesh]
21  - runTime [Time]
22 
23 Provided Variables
24  - areaRegionName [word]
25  - aMesh [faMesh]
26 
27 \*---------------------------------------------------------------------------*/
28 
29 // "getFaRegionOption.H"
31 (
32  args.getOrDefault<word>("area-region", Foam::polyMesh::defaultRegion)
33 );
34 
35 {
36  Foam::Info << "Create finite-area mesh";
38  {
39  Foam::Info << ' ' << areaRegionName;
40  }
41  Foam::Info << " for time = " << runTime.timeName() << Foam::nl;
42 }
43 
44 Foam::faMesh aMesh
45 (
47  mesh
48 );
49 
51 
52 
53 // ************************************************************************* //
Finite area mesh (used for 2-D non-Euclidian finite area method) defined using a patch of faces on a ...
Definition: faMesh.H:133
const word & regionName() const
The mesh region name or word::null if polyMesh::defaultRegion.
Definition: polyMesh.C:847
constexpr char nl
The newline &#39;\n&#39; character (0x0a)
Definition: Ostream.H:50
engineTime & runTime
Ostream & endl(Ostream &os)
Add newline and flush stream.
Definition: Ostream.H:531
T getOrDefault(const word &optName, const T &deflt) const
Get a value from the named option if present, or return default.
Definition: argListI.H:300
dynamicFvMesh & mesh
A class for handling words, derived from Foam::string.
Definition: word.H:63
static word defaultRegion
Return the default region name.
Definition: polyMesh.H:406
messageStream Info
Information stream (stdout output on master, null elsewhere)
Foam::word areaRegionName(args.getOrDefault< word >("area-region", Foam::polyMesh::defaultRegion))
Foam::argList args(argc, argv)