All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
radiation.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) 2017-2021 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::fv::radiation
26 
27 Description
28  Calculates and applies the radiation source to the energy equation.
29 
30 Usage
31  Example usage:
32  \verbatim
33  radiationCoeffs
34  {
35  libs ("libradiationModels.so");
36  type radiation;
37  }
38  \endverbatim
39 
40 SourceFiles
41  radiation.C
42 
43 \*---------------------------------------------------------------------------*/
44 
45 #ifndef radiation_H
46 #define radiation_H
47 
48 #include "fvModel.H"
50 #include "radiationModel.H"
51 
52 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
53 
54 namespace Foam
55 {
56 namespace fv
57 {
58 
59 /*---------------------------------------------------------------------------*\
60  Class radiation Declaration
61 \*---------------------------------------------------------------------------*/
62 
63 class radiation
64 :
65  public fvModel
66 {
67  // Private Data
68 
69  //- The radiation model pointer
70  mutable autoPtr<radiationModel> radiation_;
71 
72 
73 public:
74 
75  //- Runtime type information
76  TypeName("radiation");
77 
78 
79  // Constructors
80 
81  //- Construct from explicit source name and mesh
82  radiation
83  (
84  const word& sourceName,
85  const word& modelType,
86  const dictionary& dict,
87  const fvMesh& mesh
88  );
89 
90  //- Disallow default bitwise copy construction
91  radiation(const radiation&) = delete;
92 
93 
94  // Member Functions
95 
96  // Checks
97 
98  //- Return the list of fields for which the option adds source term
99  // to the transport equation
100  virtual wordList addSupFields() const;
101 
102 
103  // Evaluate
104 
105  //- Add explicit contribution to compressible energy equation
106  virtual void addSup
107  (
108  const volScalarField& rho,
109  fvMatrix<scalar>& eqn,
110  const word& fieldName
111  ) const;
112 
113 
114  // Member Operators
115 
116  //- Disallow default bitwise assignment
117  void operator=(const radiation&) = delete;
118 };
119 
120 
121 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
122 
123 } // End namespace fv
124 } // End namespace Foam
125 
126 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
127 
128 #endif
129 
130 // ************************************************************************* //
dictionary dict
A list of keyword definitions, which are a keyword followed by any number of values (e...
Definition: dictionary.H:156
Finite volume model abstract base class.
Definition: fvModel.H:55
const fvMesh & mesh() const
Return const access to the mesh database.
Definition: fvModelI.H:34
A class for handling words, derived from string.
Definition: word.H:59
labelList fv(nPoints)
void operator=(const radiation &)=delete
Disallow default bitwise assignment.
virtual void addSup(const volScalarField &rho, fvMatrix< scalar > &eqn, const word &fieldName) const
Add explicit contribution to compressible energy equation.
Definition: radiation.C:82
Calculates and applies the radiation source to the energy equation.
Definition: radiation.H:62
virtual wordList addSupFields() const
Return the list of fields for which the option adds source term.
Definition: radiation.C:72
A special matrix type and solver, designed for finite volume solutions of scalar equations. Face addressing is used to make all matrix assembly and solution loops vectorise.
Definition: fvPatchField.H:72
radiation(const word &sourceName, const word &modelType, const dictionary &dict, const fvMesh &mesh)
Construct from explicit source name and mesh.
Definition: radiation.C:52
Mesh data needed to do the Finite Volume discretisation.
Definition: fvMesh.H:78
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
Definition: PtrList.H:52
Namespace for OpenFOAM.
TypeName("radiation")
Runtime type information.