gaussFaConvectionScheme.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-------------------------------------------------------------------------------
10License
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
26Class
27 Foam::fa::gaussConvectionScheme
28
29Description
30 Basic second-order convection using face-gradients and Gauss' theorem.
31
32SourceFiles
33 gaussFaConvectionScheme.C
34 gaussFaConvectionSchemes.C
35
36\*---------------------------------------------------------------------------*/
37
38#ifndef gaussFaConvectionScheme_H
39#define gaussFaConvectionScheme_H
40
41#include "faConvectionScheme.H"
43
44// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
45
46namespace Foam
47{
48
49// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
50
51namespace fa
52{
53
54/*---------------------------------------------------------------------------*\
55 Class gaussConvectionScheme Declaration
56\*---------------------------------------------------------------------------*/
57
58template<class Type>
60:
61 public fa::convectionScheme<Type>
62{
63 // Private data
64
66
67
68 // Private Member Functions
69
70 //- No copy construct
72
73 //- No copy assignment
74 void operator=(const gaussConvectionScheme&) = delete;
75
76
77public:
78
79 //- Runtime type information
80 TypeName("Gauss");
81
82
83 // Constructors
84
85 //- Construct from flux and interpolation scheme
87 (
88 const faMesh& mesh,
89 const edgeScalarField& faceFlux,
91 )
92 :
93 convectionScheme<Type>(mesh, faceFlux),
94 tinterpScheme_(scheme)
95 {}
96
97 //- Construct from flux and Istream
99 (
100 const faMesh& mesh,
101 const edgeScalarField& faceFlux,
102 Istream& is
103 )
104 :
105 convectionScheme<Type>(mesh, faceFlux),
106 tinterpScheme_
107 (
108 edgeInterpolationScheme<Type>::New(mesh, faceFlux, is)
109 )
110 {}
111
112
113 // Member Functions
114
116 (
117 const edgeScalarField&,
119 ) const;
120
122 (
123 const edgeScalarField&,
125 ) const;
126
128 (
129 const edgeScalarField&,
131 ) const;
132};
133
134
135// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
136
137} // End namespace fa
138
139// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
140
141} // End namespace Foam
142
143// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
144
145#ifdef NoRepository
147#endif
148
149// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
150
151#endif
152
153// ************************************************************************* //
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
Definition: Istream.H:64
Abstract base class for edge interpolation schemes.
Finite area mesh (used for 2-D non-Euclidian finite area method) defined using a patch of faces on a ...
Definition: faMesh.H:100
Abstract base class for finite area calculus convection schemes.
static tmp< convectionScheme< Type > > New(const faMesh &mesh, const edgeScalarField &faceFlux, Istream &schemeData)
Return a pointer to a new convectionScheme created on freestore.
const faMesh & mesh() const
Return mesh reference.
Basic second-order convection using face-gradients and Gauss' theorem.
tmp< faMatrix< Type > > famDiv(const edgeScalarField &, const GeometricField< Type, faPatchField, areaMesh > &) const
gaussConvectionScheme(const faMesh &mesh, const edgeScalarField &faceFlux, Istream &is)
Construct from flux and Istream.
gaussConvectionScheme(const faMesh &mesh, const edgeScalarField &faceFlux, const tmp< edgeInterpolationScheme< Type > > &scheme)
Construct from flux and interpolation scheme.
tmp< GeometricField< Type, faPatchField, areaMesh > > facDiv(const edgeScalarField &, const GeometricField< Type, faPatchField, areaMesh > &) const
TypeName("Gauss")
Runtime type information.
A class for managing temporary objects.
Definition: tmp.H:65
Namespace for OpenFOAM.
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition: typeInfo.H:73