radiation.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) 2017 OpenFOAM Foundation
9 Copyright (C) 2021 OpenCFD Ltd.
10-------------------------------------------------------------------------------
11License
12 This file is part of OpenFOAM.
13
14 OpenFOAM is free software: you can redistribute it and/or modify it
15 under the terms of the GNU General Public License as published by
16 the Free Software Foundation, either version 3 of the License, or
17 (at your option) any later version.
18
19 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
20 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
21 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
22 for more details.
23
24 You should have received a copy of the GNU General Public License
25 along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
26
27Class
28 Foam::fv::radiation
29
30Description
31 Applies radiation sources (i.e. \c Sh)
32 to the energy equation for compressible flows.
33
34Usage
35 Minimal example by using \c constant/fvOptions:
36 \verbatim
37 radiation1
38 {
39 // Mandatory entries (unmodifiable)
40 type radiation;
41 fields (h);
42
43 // Mandatory/Optional (inherited) entries
44 ...
45 }
46 \endverbatim
47
48 where the entries mean:
49 \table
50 Property | Description | Type | Reqd | Dflt
51 type | Type name: radiation | word | yes | -
52 fields | Name of operand energy field | word | yes | -
53 \endtable
54
55 The inherited entries are elaborated in:
56 - \link fvOption.H \endlink
57
58SourceFiles
59 radiation.C
60
61\*---------------------------------------------------------------------------*/
62
63#ifndef radiation_H
64#define radiation_H
65
66#include "fvOption.H"
68#include "radiationModel.H"
69
70// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
71
72namespace Foam
73{
74namespace fv
75{
76
77/*---------------------------------------------------------------------------*\
78 Class radiation Declaration
79\*---------------------------------------------------------------------------*/
80
81class radiation
82:
83 public fv::option
84{
85 // Private Data
86
87 //- The radiation model pointer
88 autoPtr<Foam::radiation::radiationModel> radiation_;
89
90
91 // Private Member Functions
92
93 //- No copy construct
94 radiation(const radiation&) = delete;
95
96 //- No copy assignment
97 void operator=(const radiation&) = delete;
99
100public:
101
102 //- Runtime type information
103 TypeName("radiation");
104
105
106 // Constructors
107
108 //- Construct from explicit source name and mesh
110 (
111 const word& sourceName,
112 const word& modelType,
113 const dictionary& dict,
114 const fvMesh& mesh
115 );
116
117
118 // Member Functions
119
120 // Evaluate
121
122 //- Add explicit contribution to compressible momentum equation
123 virtual void addSup
124 (
125 const volScalarField& rho,
126 fvMatrix<scalar>& eqn,
127 const label fieldi
128 );
129
130
131 // IO
132
133 //- Read source dictionary
134 virtual bool read(const dictionary& dict);
135};
136
137
138// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
139
140} // End namespace fv
141} // End namespace Foam
142
143// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
144
145#endif
146
147// ************************************************************************* //
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
Definition: autoPtr.H:66
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:126
A special matrix type and solver, designed for finite volume solutions of scalar equations....
Definition: fvMatrix.H:121
Mesh data needed to do the Finite Volume discretisation.
Definition: fvMesh.H:91
Base abstract class for handling finite volume options (i.e. fvOption).
Definition: fvOption.H:127
const fvMesh & mesh() const noexcept
Return const access to the mesh database.
Definition: fvOptionI.H:37
Applies radiation sources (i.e. Sh) to the energy equation for compressible flows.
Definition: radiation.H:101
virtual void addSup(const volScalarField &rho, fvMatrix< scalar > &eqn, const label fieldi)
Add explicit contribution to compressible momentum equation.
Definition: radiation.C:77
virtual bool read(const dictionary &dict)
Read source dictionary.
Definition: radiation.C:70
TypeName("radiation")
Runtime type information.
A class for handling words, derived from Foam::string.
Definition: word.H:68
autoPtr< radiation::radiationModel > radiation(radiation::radiationModel::New(T))
Namespace for OpenFOAM.
labelList fv(nPoints)
dictionary dict
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition: typeInfo.H:73