noThermo.C
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) 2011-2015 OpenFOAM Foundation
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 \*---------------------------------------------------------------------------*/
27 
28 #include "noThermo.H"
30 #include "volFields.H"
31 
32 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
33 
34 namespace Foam
35 {
36 namespace regionModels
37 {
38 namespace thermalBaffleModels
39 {
40 
41 // * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
42 
44 
47 
48 // * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * //
49 
50 bool noThermo::read()
51 {
52  return regionModel1D::read();
53 }
54 
55 
56 // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
57 
58 noThermo::noThermo(const word& modelType, const fvMesh& mesh)
59 :
61 {}
62 
63 
64 noThermo::noThermo
65 (
66  const word& modelType,
67  const fvMesh& mesh,
68  const dictionary& dict
69 )
70 :
71  thermalBaffleModel(modelType, mesh, dict)
72 {}
73 
74 
75 // * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * //
76 
78 {}
79 
80 // * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * * //
81 
83 {}
84 
85 
87 {}
88 
89 
91 {
93  << "Cp field not available for " << type()
94  << abort(FatalError);
95 
96  return tmp<volScalarField>
97  (
98  new volScalarField
99  (
100  IOobject
101  (
102  "noThermo::Cp",
103  time().timeName(),
104  primaryMesh(),
108  ),
109  primaryMesh(),
111  )
112  );
113 }
114 
115 const volScalarField& noThermo::kappaRad() const
116 {
118  << "kappa field not available for " << type()
119  << abort(FatalError);
120  return volScalarField::null();
121 }
122 
123 
124 const volScalarField& noThermo::rho() const
125 {
127  << "rho field not available for " << type()
128  << abort(FatalError);
129  return volScalarField::null();
130 }
131 
132 
133 const volScalarField& noThermo::kappa() const
134 {
136  << "K field not available for " << type()
137  << abort(FatalError);
138  return volScalarField::null();
139 }
140 
141 
142 const volScalarField& noThermo::T() const
143 {
145  << "T field not available for " << type()
146  << abort(FatalError);
147  return volScalarField::null();
148 }
149 
150 
151 const solidThermo& noThermo::thermo() const
152 {
154  << "T field not available for " << type()
155  << abort(FatalError);
156  return NullObjectRef<solidThermo>();
157 }
158 
159 
160 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
161 
162 } // End namespace thermalBaffleModels
163 } // End namespace regionModels
164 } // End namespace Foam
165 
166 // ************************************************************************* //
dictionary dict
virtual void preEvolveRegion()
Pre-evolve film.
Definition: noThermo.C:75
error FatalError
Error stream (stdout output on all processes), with additional &#39;FOAM FATAL ERROR&#39; header text and sta...
A list of keyword definitions, which are a keyword followed by a number of values (eg...
Definition: dictionary.H:129
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
Definition: error.H:598
virtual const volScalarField & kappa() const
Return thermal conductivity [W/m/K].
Definition: noThermo.C:126
Ignore writing from objectRegistry::writeObject()
Macros for easy insertion into run-time selection tables.
GeometricField< scalar, fvPatchField, volMesh > volScalarField
Definition: volFieldsFwd.H:81
word timeName
Definition: getTimeIndex.H:3
fileName::Type type(const fileName &name, const bool followLink=true)
Return the file type: DIRECTORY or FILE, normally following symbolic links.
Definition: POSIX.C:799
const dimensionSet dimVolume(pow3(dimLength))
Definition: dimensionSets.H:58
dynamicFvMesh & mesh
virtual const solidThermo & thermo() const
Return const reference to the solidThermo.
Definition: noThermo.C:144
addToRunTimeSelectionTable(thermalBaffleModel, noThermo, mesh)
A class for handling words, derived from Foam::string.
Definition: word.H:63
virtual const volScalarField & rho() const
Return density [Kg/m3].
Definition: noThermo.C:117
errorManip< error > abort(error &err)
Definition: errorManip.H:139
Fundamental solid thermodynamic properties.
Definition: solidThermo.H:48
virtual void evolveRegion()
Evolve the film equations.
Definition: noThermo.C:79
const dimensionSet dimEnergy
static const GeometricField< scalar, fvPatchField, volMesh > & null()
Return a null geometric field.
virtual const tmp< volScalarField > Cp() const
Return the film specific heat capacity [J/kg/K].
Definition: noThermo.C:83
Dummy surface pyrolysis model for &#39;none&#39;.
Definition: noThermo.H:51
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.
virtual bool read()
Read control parameters from dictionary.
Mesh data needed to do the Finite Volume discretisation.
Definition: fvMesh.H:78
Nothing to be read.
virtual bool read()
Read control parameters from dictionary.
Definition: noThermo.C:43
const dimensionSet dimTime(0, 0, 1, 0, 0, 0, 0)
Definition: dimensionSets.H:51
const fvMesh & primaryMesh() const noexcept
Return the reference to the primary mesh database.
Definition: regionModel.H:239
A class for managing temporary objects.
Definition: HashPtrTable.H:50
Defines the attributes of an object for which implicit objectRegistry management is supported...
Definition: IOobject.H:172
virtual const volScalarField & T() const
Return the film mean temperature [K].
Definition: noThermo.C:135
Do not request registration (bool: false)
const Time & time() const noexcept
Return the reference to the time database.
Definition: regionModel.H:244
Namespace for OpenFOAM.
virtual const volScalarField & kappaRad() const
Return solid absorptivity [1/m].
Definition: noThermo.C:108
static constexpr const zero Zero
Global zero (0)
Definition: zero.H:127