Home
Downloads
Documentation
Installation
User Guide
man-pages
API Documentation
README
Release Notes
Changes
License
Support
SourceForge Project
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
src
OpenFOAM
meshes
polyMesh
polyPatches
constraint
wedge
wedgePolyPatch.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 | Copyright (C) 1991-2010 OpenCFD Ltd.
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::wedgePolyPatch
26
27
Description
28
Wedge front and back plane patch.
29
30
SourceFiles
31
wedgePolyPatch.C
32
33
\*---------------------------------------------------------------------------*/
34
35
#ifndef wedgePolyPatch_H
36
#define wedgePolyPatch_H
37
38
#include <
OpenFOAM/polyPatch.H
>
39
40
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
41
42
namespace
Foam
43
{
44
45
/*---------------------------------------------------------------------------*\
46
Class wedgePolyPatch Declaration
47
\*---------------------------------------------------------------------------*/
48
49
class
wedgePolyPatch
50
:
51
public
polyPatch
52
{
53
// Private data
54
55
//- Axis of the wedge
56
vector
axis_;
57
58
//- Centre normal between the wedge boundaries
59
vector
centreNormal_;
60
61
//- Normal to the patch
62
vector
patchNormal_;
63
64
//- Face transformation tensor
65
tensor
faceT_;
66
67
//- Neighbour-cell transformation tensor
68
tensor
cellT_;
69
70
//- Calculate the above tensors
71
void
initTransforms();
72
73
74
public
:
75
76
//- Runtime type information
77
TypeName
(
"wedge"
);
78
79
80
// Constructors
81
82
//- Construct from components
83
wedgePolyPatch
84
(
85
const
word
&
name
,
86
const
label size,
87
const
label
start
,
88
const
label
index
,
89
const
polyBoundaryMesh
& bm
90
);
91
92
//- Construct from dictionary
93
wedgePolyPatch
94
(
95
const
word
& name,
96
const
dictionary
& dict,
97
const
label index,
98
const
polyBoundaryMesh
& bm
99
);
100
101
//- Construct as copy, resetting the boundary mesh
102
wedgePolyPatch
(
const
wedgePolyPatch
&,
const
polyBoundaryMesh
&);
103
104
//- Construct given the original patch and resetting the
105
// face list and boundary mesh information
106
wedgePolyPatch
107
(
108
const
wedgePolyPatch
& pp,
109
const
polyBoundaryMesh
& bm,
110
const
label index,
111
const
label newSize,
112
const
label newStart
113
);
114
115
//- Construct and return a clone, resetting the boundary mesh
116
virtual
autoPtr<polyPatch>
clone
(
const
polyBoundaryMesh
& bm)
const
117
{
118
return
autoPtr<polyPatch>
(
new
wedgePolyPatch
(*
this
, bm));
119
}
120
121
//- Construct and return a clone, resetting the face list
122
// and boundary mesh
123
virtual
autoPtr<polyPatch>
clone
124
(
125
const
polyBoundaryMesh
& bm,
126
const
label index,
127
const
label newSize,
128
const
label newStart
129
)
const
130
{
131
return
autoPtr<polyPatch>
132
(
133
new
wedgePolyPatch
(*
this
, bm, index, newSize, newStart)
134
);
135
}
136
137
138
// Member functions
139
140
// Access
141
142
//- Return axis of the wedge
143
const
vector
&
axis
()
const
144
{
145
return
axis_;
146
}
147
148
//- Return plane normal between the wedge boundaries
149
const
vector
&
centreNormal
()
const
150
{
151
return
centreNormal_;
152
}
153
154
//- Return the normal to the patch
155
const
vector
&
patchNormal
()
const
156
{
157
return
patchNormal_;
158
}
159
160
//- Return face transformation tensor
161
const
tensor
&
faceT
()
const
162
{
163
return
faceT_;
164
}
165
166
//- Return neighbour-cell transformation tensor
167
const
tensor
&
cellT
()
const
168
{
169
return
cellT_;
170
}
171
};
172
173
174
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
175
176
}
// End namespace Foam
177
178
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
179
180
#endif
181
182
// ************************ vim: set sw=4 sts=4 et: ************************ //