42Foam::radiation::radiativeIntensityRay::radiativeIntensityRay
48 const scalar deltaPhi,
49 const scalar deltaTheta,
58 absorptionEmission_(absorptionEmission),
59 blackBody_(blackBody),
126 omega_ = 2.0*sinTheta*
Foam::sin(deltaTheta/2.0)*deltaPhi;
127 d_ =
vector(sinTheta*sinPhi, sinTheta*cosPhi, cosTheta);
141 if (mesh_.nSolutionD() == 2)
146 meshDir = dom_.meshOrientation();
162 dAve_ = coordRot & dAve_;
165 else if (mesh_.nSolutionD() == 1)
170 meshDir = dom_.meshOrientation();
176 if (mesh_.geometricD()[cmpt] == 1)
184 dAve_ = (dAve_ & normal)*meshDir;
185 d_ = (d_ & normal)*meshDir;
188 autoPtr<volScalarField> IDefaultPtr;
195 mesh_.time().timeName(),
222 mesh_.time().timeName(),
233 IOobject noReadHeader(IHeader);
257 qr_.boundaryFieldRef() = 0.0;
258 qem_.boundaryFieldRef() = 0.0;
259 qin_.boundaryFieldRef() = 0.0;
261 scalar maxResidual = -GREAT;
271 fvm::div(Ji, ILambda_[lambdaI],
"div(Ji,Ii_h)")
272 +
fvm::Sp(
k*omega_, ILambda_[lambdaI])
276 (
k - absorptionEmission_.aDisp(lambdaI))
277 *blackBody_.bLambda(lambdaI)
279 + absorptionEmission_.E(lambdaI)/4
291 const scalar initialRes =
294 maxResidual =
max(initialRes, maxResidual);
307 I_ += ILambda_[lambdaI];
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().
@ AUTO_WRITE
Automatically write from objectRegistry::writeObject().
Defines the attributes of an object for which implicit objectRegistry management is supported,...
bool typeHeaderOk(const bool checkType=true, const bool search=true, const bool verbose=true)
Read header (respects is_globalIOobject trait) and check its info. A void type suppresses trait and t...
static constexpr direction nComponents
Number of components in this vector space.
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
void reset(T *p=nullptr) noexcept
Delete managed object and set to new given pointer.
void relax(const scalar alpha)
Relax matrix (for steady-state solution).
autoPtr< fvSolver > solver(const dictionary &)
Construct and return the solver.
Mesh data needed to do the Finite Volume discretisation.
const Vector< label > & geometricD() const
Return the vector of geometric directions in mesh.
Model to supply absorption and emission coefficients for radiation modelling.
Class black body emission.
Finite Volume Discrete Ordinates Method. Solves the RTE equation for n directions in a participating ...
~radiativeIntensityRay()
Destructor.
scalar theta() const
Return the theta angle.
scalar correct()
Update radiative intensity on i direction.
scalar nLambda() const
Return the number of bands.
static const word intensityPrefix
scalar phi() const
Return the phi angle.
void addIntensity()
Add radiative intensities from all the bands.
A class for handling words, derived from Foam::string.
constexpr scalar pi(M_PI)
Different types of constants.
tmp< fvMatrix< Type > > div(const surfaceScalarField &flux, const GeometricField< Type, fvPatchField, volMesh > &vf, const word &name)
zeroField Sp(const Foam::zero, const GeometricField< Type, fvPatchField, volMesh > &)
A no-op source.
label max(const labelHashSet &set, label maxValue=labelMin)
Find the max value in labelHashSet, optionally limited by second argument.
dimensionedScalar pow3(const dimensionedScalar &ds)
fvMatrix< scalar > fvScalarMatrix
const dimensionSet dimTime(0, 0, 1, 0, 0, 0, 0)
GeometricField< scalar, fvPatchField, volMesh > volScalarField
tensor rotationTensor(const vector &n1, const vector &n2)
Rotational transformation tensor from vector n1 to n2.
dimensionedScalar sin(const dimensionedScalar &ds)
GeometricField< scalar, fvsPatchField, surfaceMesh > surfaceScalarField
static constexpr const zero Zero
Global zero (0).
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for expressions::valueTypeCode::INVALID.
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.
dimensionedScalar cos(const dimensionedScalar &ds)
SolverPerformance< scalar > solverPerformance
SolverPerformance instantiated for a scalar.
const dimensionSet dimMass(1, 0, 0, 0, 0, 0, 0)
#define forAll(list, i)
Loop across all elements in list.