1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
5 \\ / A nd | Copyright (C) 2004-2010 OpenCFD Ltd.
7 -------------------------------------------------------------------------------
9 This file is part of OpenFOAM.
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.
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
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/>.
28 Wedge front and back plane patch.
33 \*---------------------------------------------------------------------------*/
35 #ifndef wedgePolyPatch_H
36 #define wedgePolyPatch_H
38 #include "polyPatch.H"
40 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
45 /*---------------------------------------------------------------------------*\
46 Class wedgePolyPatch Declaration
47 \*---------------------------------------------------------------------------*/
58 //- Centre normal between the wedge boundaries
61 //- Normal to the patch
64 //- Face transformation tensor
67 //- Neighbour-cell transformation tensor
70 //- Calculate the above tensors
71 void initTransforms();
76 //- Runtime type information
82 //- Construct from components
89 const polyBoundaryMesh& bm
92 //- Construct from dictionary
96 const dictionary& dict,
98 const polyBoundaryMesh& bm
101 //- Construct as copy, resetting the boundary mesh
102 wedgePolyPatch(const wedgePolyPatch&, const polyBoundaryMesh&);
104 //- Construct given the original patch and resetting the
105 // face list and boundary mesh information
108 const wedgePolyPatch& pp,
109 const polyBoundaryMesh& bm,
115 //- Construct given the original patch and a map
118 const wedgePolyPatch& pp,
119 const polyBoundaryMesh& bm,
121 const labelUList& mapAddressing,
125 //- Construct and return a clone, resetting the boundary mesh
126 virtual autoPtr<polyPatch> clone(const polyBoundaryMesh& bm) const
128 return autoPtr<polyPatch>(new wedgePolyPatch(*this, bm));
131 //- Construct and return a clone, resetting the face list
133 virtual autoPtr<polyPatch> clone
135 const polyBoundaryMesh& bm,
141 return autoPtr<polyPatch>
143 new wedgePolyPatch(*this, bm, index, newSize, newStart)
147 //- Construct and return a clone, resetting the face list
149 virtual autoPtr<polyPatch> clone
151 const polyBoundaryMesh& bm,
153 const labelUList& mapAddressing,
157 return autoPtr<polyPatch>
159 new wedgePolyPatch(*this, bm, index, mapAddressing, newStart)
168 //- Return axis of the wedge
169 const vector& axis() const
174 //- Return plane normal between the wedge boundaries
175 const vector& centreNormal() const
177 return centreNormal_;
180 //- Return the normal to the patch
181 const vector& patchNormal() const
186 //- Return face transformation tensor
187 const tensor& faceT() const
192 //- Return neighbour-cell transformation tensor
193 const tensor& cellT() const
200 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
202 } // End namespace Foam
204 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
208 // ************************************************************************* //