edgeInterpolate.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) 2016-2017 Wikki Ltd
9 -------------------------------------------------------------------------------
10 License
11  This file is part of OpenFOAM.
12 
13  OpenFOAM is free software: you can redistribute it and/or modify it
14  under the terms of the GNU General Public License as published by
15  the Free Software Foundation, either version 3 of the License, or
16  (at your option) any later version.
17 
18  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
19  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
20  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21  for more details.
22 
23  You should have received a copy of the GNU General Public License
24  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
25 
26 InNamespace
27  Foam::fac
28 
29 Description
30 
31 SourceFiles
32  edgeInterpolate.C
33 
34 \*---------------------------------------------------------------------------*/
35 
36 #ifndef edgeInterpolate_H
37 #define edgeInterpolate_H
38 
39 #include "tmp.H"
40 #include "areaFieldsFwd.H"
41 #include "edgeFieldsFwd.H"
43 
44 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
45 
46 namespace Foam
47 {
48 
49 /*---------------------------------------------------------------------------*\
50  Namespace fa functions Declaration
51 \*---------------------------------------------------------------------------*/
52 
53 namespace fac
54 {
55  //- Return weighting factors for scheme given from Istream
56  template<class Type>
57  static tmp<edgeInterpolationScheme<Type>> scheme
58  (
59  const edgeScalarField& faceFlux,
60  Istream& schemeData
61  );
62 
63  //- Return weighting factors for scheme given by name in dictionary
64  template<class Type>
65  static tmp<edgeInterpolationScheme<Type>> scheme
66  (
67  const edgeScalarField& faceFlux,
68  const word& name
69  );
70 
71 
72  //- Return weighting factors for scheme given from Istream
73  template<class Type>
74  static tmp<edgeInterpolationScheme<Type>> scheme
75  (
76  const faMesh& mesh,
77  Istream& schemeData
78  );
79 
80  //- Return weighting factors for scheme given by name in dictionary
81  template<class Type>
82  static tmp<edgeInterpolationScheme<Type>> scheme
83  (
84  const faMesh& mesh,
85  const word& name
86  );
87 
88 
89  //- Interpolate field onto faces using scheme given by Istream
90  template<class Type>
91  static tmp<GeometricField<Type, faePatchField, edgeMesh>> interpolate
92  (
93  const GeometricField<Type, faPatchField, areaMesh>& tvf,
94  const edgeScalarField& faceFlux,
95  Istream& schemeData
96  );
97 
98  //- Interpolate field onto faces using scheme given by name in faSchemes
99  template<class Type>
100  static tmp<GeometricField<Type, faePatchField, edgeMesh>> interpolate
101  (
102  const GeometricField<Type, faPatchField, areaMesh>& tvf,
103  const edgeScalarField& faceFlux,
104  const word& name
105  );
106 
107  //- Interpolate field onto faces using scheme given by name in faSchemes
108  template<class Type>
109  static tmp<GeometricField<Type, faePatchField, edgeMesh>> interpolate
110  (
111  const tmp<GeometricField<Type, faPatchField, areaMesh>>& tvf,
112  const edgeScalarField& faceFlux,
113  const word& name
114  );
115 
116  //- Interpolate field onto faces using scheme given by name in faSchemes
117  template<class Type>
118  static tmp<GeometricField<Type, faePatchField, edgeMesh>> interpolate
119  (
120  const GeometricField<Type, faPatchField, areaMesh>& tvf,
121  const tmp<edgeScalarField>& faceFlux,
122  const word& name
123  );
124 
125  //- Interpolate field onto faces using scheme given by name in faSchemes
126  template<class Type>
127  static tmp<GeometricField<Type, faePatchField, edgeMesh>> interpolate
128  (
129  const tmp<GeometricField<Type, faPatchField, areaMesh>>& tvf,
130  const tmp<edgeScalarField>& faceFlux,
131  const word& name
132  );
133 
134 
135  //- Interpolate field onto faces using scheme given by Istream
136  template<class Type>
137  static tmp<GeometricField<Type, faePatchField, edgeMesh>> interpolate
138  (
139  const GeometricField<Type, faPatchField, areaMesh>& tvf,
140  Istream& schemeData
141  );
142 
143  //- Interpolate field onto faces using scheme given by name in faSchemes
144  template<class Type>
145  static tmp<GeometricField<Type, faePatchField, edgeMesh>> interpolate
146  (
147  const GeometricField<Type, faPatchField, areaMesh>& tvf,
148  const word& name
149  );
150 
151  //- Interpolate field onto faces using scheme given by name in faSchemes
152  template<class Type>
153  static tmp<GeometricField<Type, faePatchField, edgeMesh>> interpolate
154  (
155  const tmp<GeometricField<Type, faPatchField, areaMesh>>& tvf,
156  const word& name
157  );
158 
159 
160  //- Interpolate tmp field onto faces using central differencing
161  template<class Type>
162  static tmp<GeometricField<Type, faePatchField, edgeMesh>> interpolate
163  (
164  const tmp<GeometricField<Type, faPatchField, areaMesh>>& tvf
165  );
166 
167  //- Interpolate field onto faces using central differencing
168  template<class Type>
169  static tmp<GeometricField<Type, faePatchField, edgeMesh>> interpolate
170  (
171  const GeometricField<Type, faPatchField, areaMesh>& tvf
172  );
173 }
174 
175 
176 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
177 
178 } // End namespace Foam
179 
180 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
181 
182 #ifdef NoRepository
183  #include "edgeInterpolate.C"
184 #endif
185 
186 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
187 
188 #endif
189 
190 // ************************************************************************* //
edgeInterpolationScheme.H
edgeInterpolate.C
areaFieldsFwd.H
Forwards and collection of common area field types.
Foam::edgeScalarField
GeometricField< scalar, faePatchField, edgeMesh > edgeScalarField
Definition: edgeFieldsFwd.H:52
mesh
dynamicFvMesh & mesh
Definition: createDynamicFvMesh.H:6
Foam
Namespace for OpenFOAM.
Definition: atmBoundaryLayer.C:33
fac
Calculate the second temporal derivative.
tmp.H
Foam::name
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for INVALID.
Definition: exprTraits.C:59
edgeFieldsFwd.H
Forwards for edge field types.
Foam::fac::interpolate
static tmp< GeometricField< Type, faePatchField, edgeMesh > > interpolate(const GeometricField< Type, faPatchField, areaMesh > &tvf, const edgeScalarField &faceFlux, Istream &schemeData)
Interpolate field onto faces using scheme given by Istream.
Foam::fac::scheme
static tmp< edgeInterpolationScheme< Type > > scheme(const edgeScalarField &faceFlux, Istream &schemeData)
Return weighting factors for scheme given from Istream.