66 "radiationProperties",
67 mesh.time().constant(),
86void Foam::radiation::radiationModel::initialise()
90 solverFreq_ =
max(1, getOrDefault<label>(
"solverFreq", 1));
92 if (this->
found(
"absorptionEmissionModel"))
94 absorptionEmission_.reset
100 if (this->
found(
"scatterModel"))
105 if (this->
found(
"sootModel"))
115Foam::radiation::radiationModel::radiationModel(
const volScalarField&
T)
121 "radiationProperties",
141Foam::radiation::radiationModel::radiationModel
151 radiation_(getOrDefault(
"radiation", true)),
152 coeffs_(subOrEmptyDict(
type +
"Coeffs")),
155 absorptionEmission_(nullptr),
168Foam::radiation::radiationModel::radiationModel
179 "radiationProperties",
190 radiation_(getOrDefault(
"radiation", true)),
191 coeffs_(subOrEmptyDict(
type +
"Coeffs")),
194 absorptionEmission_(nullptr),
214 readEntry(
"radiation", radiation_);
215 coeffs_ = subOrEmptyDict(
type() +
"Coeffs");
217 solverFreq_ = getOrDefault<label>(
"solverFreq", 1);
218 solverFreq_ =
max(1, solverFreq_);
234 if (firstIter_ || (time_.timeIndex() % solverFreq_ == 0))
260 -
Rp()*T3*(
T_ - 4.0*
he/Cpv)
309 if (!absorptionEmission_)
312 <<
"Requested radiation absorptionEmission model, but model is "
316 return *absorptionEmission_;
326 <<
"Requested radiation sootModel model, but model is "
IOdictionary is derived from dictionary and IOobject to give the dictionary automatic IO functionalit...
IOdictionary(const IOobject &io, const dictionary *fallback=nullptr)
Construct given an IOobject and optional fallback dictionary content.
readOption readOpt() const noexcept
Get the read option.
@ NO_READ
Nothing to be read.
@ MUST_READ
Reading required.
@ NO_WRITE
Ignore writing from objectRegistry::writeObject().
Defines the attributes of an object for which implicit objectRegistry management is supported,...
const Time & time() const noexcept
Return Time associated with the objectRegistry.
Abstract base-class for fluid and solid thermodynamic properties.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
dictionary subOrEmptyDict(const word &keyword, enum keyType::option matchOpt=keyType::REGEX, const bool mandatory=false) const
Find and return a sub-dictionary as a copy, otherwise return an empty dictionary.
bool readEntry(const word &keyword, T &val, enum keyType::option matchOpt=keyType::REGEX, IOobjectOption::readOption readOpt=IOobjectOption::MUST_READ) const
Find entry and assign to T val. FatalIOError if it is found and the number of tokens is incorrect,...
dictionary()
Default construct, a top-level empty dictionary.
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...
Mesh data needed to do the Finite Volume discretisation.
constant condensation/saturation model.
Model to supply absorption and emission coefficients for radiation modelling.
static autoPtr< absorptionEmissionModel > New(const dictionary &dict, const fvMesh &mesh)
Selector.
Top level model for radiation modelling.
const Time & time_
Reference to the time database.
const absorptionEmissionModel & absorptionEmission() const
Access to absorptionEmission model.
const fvMesh & mesh_
Reference to the mesh database.
virtual ~radiationModel()
Destructor.
virtual void calculate()=0
Solve radiation equation(s).
static const word externalRadHeatFieldName_
Static name external radiative fluxes.
label solverFreq_
Radiation solver frequency - number flow solver iterations per.
virtual void correct()
Main update/correction routine.
static const word relfectedFluxName_
Static name for reflected solar fluxes.
virtual bool read()=0
Read radiationProperties dictionary.
dictionary coeffs_
Radiation model dictionary.
Switch radiation_
Radiation model on/off flag.
virtual tmp< fvScalarMatrix > ST(const dimensionedScalar &rhoCp, volScalarField &T) const
Temperature source term.
autoPtr< sootModel > soot_
Soot model.
virtual tmp< volScalarField > Rp() const =0
Source term component (for power of T^4).
autoPtr< scatterModel > scatter_
Scatter model.
autoPtr< absorptionEmissionModel > absorptionEmission_
Absorption/emission model.
const volScalarField & T() const noexcept
Return access to the temperature field.
static const word primaryFluxName_
Static name for primary solar fluxes.
const volScalarField & T_
Reference to the temperature field.
const sootModel & soot() const
Access to soot Model.
virtual tmp< fvScalarMatrix > Sh(const basicThermo &thermo, const volScalarField &he) const
Energy source term.
bool firstIter_
Flag to enable radiation model to be evaluated on first iteration.
virtual tmp< volScalarField::Internal > Ru() const =0
Source term component (constant).
static autoPtr< scatterModel > New(const dictionary &dict, const fvMesh &mesh)
Base class for soot models.
static autoPtr< sootModel > New(const dictionary &dict, const fvMesh &mesh)
Selector.
virtual bool read()
Read object.
Basic thermodynamics type based on the use of fitting functions for cp, h, s obtained from the templa...
A class for managing temporary objects.
A class for handling words, derived from Foam::string.
#define defineTypeNameAndDebug(Type, DebugSwitch)
Define the typeName and debug information.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
Calculate the finiteVolume matrix for implicit and explicit sources.
Different types of constants.
zeroField Sp(const Foam::zero, const GeometricField< Type, fvPatchField, volMesh > &)
A no-op source.
Namespace for radiation modelling.
label max(const labelHashSet &set, label maxValue=labelMin)
Find the max value in labelHashSet, optionally limited by second argument.
dimensionedScalar pow3(const dimensionedScalar &ds)
GeometricField< scalar, fvPatchField, volMesh > volScalarField
fileName::Type type(const fileName &name, const bool followLink=true)
Return the file type: DIRECTORY or FILE, normally following symbolic links.
errorManip< error > abort(error &err)
error FatalError
Error stream (stdout output on all processes), with additional 'FOAM FATAL ERROR' header text and sta...
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
#define defineRunTimeSelectionTable(baseType, argNames)
Define run-time selection table.