/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Copyright (C) 2021 OpenCFD Ltd.
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
OpenFOAM is free software: you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
for more details.
You should have received a copy of the GNU General Public License
along with OpenFOAM. If not, see .
Class
Foam::faMeshReconstructor
Description
A bare-bones reconstructor for finiteArea meshes when processor
meshes are available (in parallel) but an equivalent serial faMesh
is needed for reconstruction or decomposition.
In these situations, a serial version of the faMesh is needed,
but preferably without reconstructing the entire volume mesh.
It uses the finiteVolume faceProcAddressing in addition to
the geometric information available from the underlying polyMesh.
The resulting equivalent faMesh can be used for basic operations,
but caution should be exercised before attempting large operations.
SourceFiles
faMeshReconstructor.C
\*---------------------------------------------------------------------------*/
#ifndef faMeshReconstructor_H
#define faMeshReconstructor_H
#include "faMesh.H"
#include "primitivePatch.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
namespace Foam
{
// Forward Declarations
class Time;
/*---------------------------------------------------------------------------*\
Class faMeshReconstructor Declaration
\*---------------------------------------------------------------------------*/
class faMeshReconstructor
{
// Private Data
//- The processor-specific faMesh
const faMesh& procMesh_;
// Addressing
//- Processor face addressing, derived from finite volume information
labelList faFaceProcAddr_;
//- Processor boundary addressing
labelList faBoundaryProcAddr_;
//- Processor point addressing
labelList faPointProcAddr_;
//- Processor edge addressing
labelList faEdgeProcAddr_;
// Equivalent surface information
//- Faces labels for a single patch
labelList singlePatchFaceLabels_;
//- Faces for a single patch
faceList singlePatchFaces_;
//- Support points for a single patch
pointField singlePatchPoints_;
//- Lists of edge-labels (per edge patch) for the single patch
labelListList singlePatchEdgeLabels_;
// Demand-driven data
//- Primitive patch
mutable autoPtr serialPatchPtr_;
//- Time database for serial meshes
autoPtr