preserveBafflesConstraint.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) 2015-2016 OpenFOAM Foundation
9 Copyright (C) 2018 OpenCFD Ltd.
10-------------------------------------------------------------------------------
11License
12 This file is part of OpenFOAM.
13
14 OpenFOAM is free software: you can redistribute it and/or modify it
15 under the terms of the GNU General Public License as published by
16 the Free Software Foundation, either version 3 of the License, or
17 (at your option) any later version.
18
19 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
20 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
21 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
22 for more details.
23
24 You should have received a copy of the GNU General Public License
25 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
26
27Class
28 Foam::decompositionConstraints::preserveBaffles
29
30Description
31 Detects baffles and keeps owner and neighbour on same processor.
32
33 \heading Dictionary parameters
34 \table
35 Property | Description | Required | Default
36 type | preserveBaffles | yes |
37 \endtable
38
39SourceFiles
40 preserveBafflesConstraint.C
41
42\*---------------------------------------------------------------------------*/
43
44#ifndef preserveBafflesConstraint_H
45#define preserveBafflesConstraint_H
46
48
49// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
50
51namespace Foam
52{
53namespace decompositionConstraints
54{
55
56/*---------------------------------------------------------------------------*\
57 Class preserveBaffles Declaration
58\*---------------------------------------------------------------------------*/
59
60class preserveBaffles
61:
62 public decompositionConstraint
63{
64public:
65
66 //- Runtime type information
67 TypeName("preserveBaffles");
68
70 // Constructors
71
72 //- Construct with constraint dictionary
73 explicit preserveBaffles(const dictionary& dict);
74
75 //- Construct from components
77
78
79 //- Destructor
80 virtual ~preserveBaffles() = default;
81
82
83 // Member Functions
84
85 //- Add my constraints to list of constraints
86 virtual void add
87 (
88 const polyMesh& mesh,
89 boolList& blockedFace,
90 PtrList<labelList>& specifiedProcessorFaces,
91 labelList& specifiedProcessor,
92 List<labelPair>& explicitConnections
93 ) const;
94
95 //- Apply any additional post-decomposition constraints
96 virtual void apply
97 (
98 const polyMesh& mesh,
99 const boolList& blockedFace,
100 const PtrList<labelList>& specifiedProcessorFaces,
101 const labelList& specifiedProcessor,
102 const List<labelPair>& explicitConnections,
103 labelList& decomposition
104 ) const;
105};
106
107
108// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
109
110} // End namespace decompositionConstraints
111} // End namespace Foam
112
113// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
114
115#endif
116
117// ************************************************************************* //
A list of pointers to objects of type <T>, with allocation/deallocation management of the pointers....
Definition: PtrList.H:73
Abstract class for handling decomposition constraints.
Detects baffles and keeps owner and neighbour on same processor.
virtual void apply(const polyMesh &mesh, const boolList &blockedFace, const PtrList< labelList > &specifiedProcessorFaces, const labelList &specifiedProcessor, const List< labelPair > &explicitConnections, labelList &decomposition) const
Apply any additional post-decomposition constraints.
virtual void add(const polyMesh &mesh, boolList &blockedFace, PtrList< labelList > &specifiedProcessorFaces, labelList &specifiedProcessor, List< labelPair > &explicitConnections) const
Add my constraints to list of constraints.
virtual ~preserveBaffles()=default
Destructor.
TypeName("preserveBaffles")
Runtime type information.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:126
Mesh consisting of general polyhedral cells.
Definition: polyMesh.H:81
dynamicFvMesh & mesh
Namespace for OpenFOAM.
dictionary dict
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition: typeInfo.H:73