Loading...
Searching...
No Matches
thermalShellModel.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) 2019-2025 OpenCFD 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
26\*---------------------------------------------------------------------------*/
27
28#include "thermalShellModel.H"
29
30// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
31
32namespace Foam
33{
34namespace regionModels
35{
36
37// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
40
42
43// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
44
46(
47 const word& modelType,
48 const fvMesh& mesh,
49 const dictionary& dict
50)
51:
52 regionFaModel(mesh, "thermalShell", modelType, dict, true),
53 TName_(dict.getOrDefault<word>("Ts", suffixed("Ts"), keyType::LITERAL)),
55 (
57 (
58 "Tprimary", {{"T", -2506}},
59 "T",
61 )
62 ),
63 Tp_(mesh.lookupObject<volScalarField>(TprimaryName_)),
64 T_
65 (
67 (
68 TName_,
69 regionMesh().time().timeName(),
70 regionMesh().thisDb(),
73 ),
74 regionMesh()
75 ),
76 faOptions_
77 (
79 )
80{
81 if (faOptions_.optionList::empty())
82 {
83 Info<< "No finite-area options present for area:"
86}
87
88
89// * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * * //
90
92{}
93
94
95// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
96
97} // End namespace regionModels
98} // End namespace Foam
99
100// ************************************************************************* //
@ MUST_READ
Reading required.
@ AUTO_WRITE
Automatically write from objectRegistry::writeObject().
Defines the attributes of an object for which implicit objectRegistry management is supported,...
Definition IOobject.H:191
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition dictionary.H:133
T getOrDefault(const word &keyword, const T &deflt, enum keyType::option matchOpt=keyType::REGEX) const
Find and return a T, or return the given default value. FatalIOError if it is found and the number of...
T getOrDefaultCompat(const word &keyword, std::initializer_list< std::pair< const char *, int > > compat, const T &deflt, enum keyType::option matchOpt=keyType::REGEX) const
Find and return a T, or return the given default value using any compatibility names if needed.
static options & New(const fvMesh &mesh, const word &defaultAreaName=word())
Construct faOptions and register to database if not present otherwise lookup and return.
Mesh data needed to do the Finite Volume discretisation.
Definition fvMesh.H:85
A class for handling keywords in dictionaries.
Definition keyType.H:69
@ LITERAL
String literal.
Definition keyType.H:82
word suffixed(const char *base) const
Return the concatenation of base and the suffix hint.
const word & areaName() const noexcept
The finite-area mesh name (extracted from dictionary).
regionFaModel(const fvMesh &mesh, const word &regionType, const word &modelName, const dictionary &dict, bool readFields=true)
Construct from mesh and name and dict.
Intermediate class for thermal-shell finite-area models.
const word TName_
Name of shell temperature field (default: "Ts"+suffix).
thermalShellModel(const word &modelType, const fvMesh &mesh, const dictionary &dict)
Construct from type name and mesh and dict.
virtual void preEvolveRegion()
Pre-evolve region.
const word TprimaryName_
Name of volume temperature field (default: "T").
A class for handling words, derived from Foam::string.
Definition word.H:66
#define defineTypeNameAndDebug(Type, DebugSwitch)
Define the typeName and debug information.
Definition className.H:142
dynamicFvMesh & mesh
word timeName
Definition getTimeIndex.H:3
Namespace for OpenFOAM.
GeometricField< scalar, fvPatchField, volMesh > volScalarField
messageStream Info
Information stream (stdout output on master, null elsewhere).
Ostream & endl(Ostream &os)
Add newline and flush stream.
Definition Ostream.H:519
#define defineRunTimeSelectionTable(baseType, argNames)
Define run-time selection table.
dictionary dict