nonConformalCyclicFvPatch.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration | Website: https://openfoam.org
5  \\ / A nd | Copyright (C) 2021-2024 OpenFOAM Foundation
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8 License
9  This file is part of OpenFOAM.
10 
11  OpenFOAM is free software: you can redistribute it and/or modify it
12  under the terms of the GNU General Public License as published by
13  the Free Software Foundation, either version 3 of the License, or
14  (at your option) any later version.
15 
16  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
19  for more details.
20 
21  You should have received a copy of the GNU General Public License
22  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
23 
24 Class
25  Foam::nonConformalCyclicFvPatch
26 
27 Description
28  Non-conformal cyclic FV patch. As nonConformalCoupledFvPatch, but the
29  neighbouring patch is local and known and is made available by this class.
30 
31 See also
32  Foam::nonConformalCyclicPolyPatch
33  Foam::nonConformalCoupledFvPatch
34 
35 SourceFiles
36  nonConformalCyclicFvPatch.C
37 
38 \*---------------------------------------------------------------------------*/
39 
40 #ifndef nonConformalCyclicFvPatch_H
41 #define nonConformalCyclicFvPatch_H
42 
43 #include "cyclicFvPatch.H"
46 
47 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
48 
49 namespace Foam
50 {
51 
52 class nonConformalErrorFvPatch;
53 
54 /*---------------------------------------------------------------------------*\
55  Class nonConformalCyclicFvPatch Declaration
56 \*---------------------------------------------------------------------------*/
57 
59 :
60  public cyclicFvPatch,
62 {
63  // Private Data
64 
65  //- Reference to the polyPatch
66  const nonConformalCyclicPolyPatch& nonConformalCyclicPolyPatch_;
67 
68 
69 public:
70 
71  //- Runtime type information
72  TypeName(nonConformalCyclicPolyPatch::typeName_());
73 
74 
75  // Constructors
76 
77  //- Construct from polyPatch and fvBoundaryMesh
79  (
80  const polyPatch& patch,
81  const fvBoundaryMesh& bm
82  );
83 
84 
85  //- Destructor
87 
88 
89  // Member Functions
90 
91  // Access
92 
93  //- Inherit the cyclic patch method
95 
96  //- Poly patch
98 
99  //- Inherit the cyclic owner method
100  using cyclicFvPatch::owner;
101 
102  //- Inherit the cyclic neighbour method
104 
105  //- Inherit the cyclic transform method
107 
108  //- Neighbour patch
109  const nonConformalCyclicFvPatch& nbrPatch() const;
110 
111  //- Is this patch coupled? Returns true. For NCC patches the poly
112  // mesh is considered non-coupled whilst the finite volume mesh is
113  // considered coupled.
114  virtual bool coupled() const;
115 
116  //- Return the start label of this patch in the polyMesh face list.
117  // Raises an error unless the patch is empty.
118  virtual label start() const;
119 
120  //- Return the size
121  virtual label size() const;
122 
123  //- Return the face-cells
124  virtual const labelUList& faceCells() const;
125 
126 
127  //- Make patch weighting factors
128  void makeWeights(scalarField&) const;
129 
130  //- Return delta (P to N) vectors across coupled patch
131  virtual tmp<vectorField> delta() const;
132 };
133 
134 
135 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
136 
137 } // End namespace Foam
138 
139 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
140 
141 #endif
142 
143 // ************************************************************************* //
virtual bool neighbour() const
Does the coupled side own the patch ?
Cyclic-plane patch.
Definition: cyclicFvPatch.H:55
virtual bool owner() const
Does this side own the patch ?
virtual const transformer & transform() const
Return transformation between the coupled patches.
Foam::fvBoundaryMesh.
const polyPatch & patch() const
Return the polyPatch.
Definition: fvPatch.H:120
Non-conformal coupled FV patch. As nonConformalFvPatch, but is also coupled to another non-conformal ...
Non-conformal cyclic FV patch. As nonConformalCoupledFvPatch, but the neighbouring patch is local and...
void makeWeights(scalarField &) const
Make patch weighting factors.
const nonConformalCyclicPolyPatch & nonConformalCyclicPatch() const
Poly patch.
virtual label size() const
Return the size.
virtual bool coupled() const
Is this patch coupled? Returns true. For NCC patches the poly.
virtual tmp< vectorField > delta() const
Return delta (P to N) vectors across coupled patch.
TypeName(nonConformalCyclicPolyPatch::typeName_())
Runtime type information.
nonConformalCyclicFvPatch(const polyPatch &patch, const fvBoundaryMesh &bm)
Construct from polyPatch and fvBoundaryMesh.
virtual const labelUList & faceCells() const
Return the face-cells.
virtual label start() const
Return the start label of this patch in the polyMesh face list.
const nonConformalCyclicFvPatch & nbrPatch() const
Neighbour patch.
Non-conformal cyclic poly patch. As nonConformalCoupledPolyPatch, but the neighbouring patch is local...
const fvPatch & patch() const
Reference to the fvPatch.
A patch is a list of labels that address the faces in the global face list.
Definition: polyPatch.H:70
A class for managing temporary objects.
Definition: tmp.H:55
Namespace for OpenFOAM.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Definition: label.H:59