32 Foam::scalar Foam::singleSizeGroupFvScalarFieldSource::eta()
const
34 const diameterModels::sizeGroup& fi =
35 refCast<const diameterModels::sizeGroup>(internalField());
38 const label firstIndex = fi.group().sizeGroups().first().i();
39 const label lastIndex = fi.group().sizeGroups().last().i();
40 if (index_ < firstIndex || index_ > lastIndex)
43 <<
"Size-group index " << index_ <<
" is out of range of the "
44 <<
"indices associated with phase " << internalField().group()
45 <<
" (" << firstIndex <<
" -> " << lastIndex <<
")"
49 return fi.i() == index_ ? scalar(1) : scalar(0);
61 fvScalarFieldSource(iF,
dict),
72 fvScalarFieldSource(field, iF),
95 model.
name() +
":" + this->internalField().name() +
"SourceValue",
96 this->internalField().mesh(),
124 model.
name() +
":" + this->internalField().name() +
"InternalCoeff",
125 this->internalField().mesh(),
Macros for easy insertion into run-time selection tables.
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
static tmp< DimensionedField< Type, GeoMesh, PrimitiveField > > New(const word &name, const Mesh &mesh, const dimensionSet &, const PrimitiveField< Type > &)
Return a temporary field constructed from name, mesh,.
void size(const label)
Override size to be inconsistent with allocated storage.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
A list of keywords followed by any number of values (e.g. words and numbers) or sub-dictionaries.
const word & name() const
Return const access to the source name.
Base class for finite volume sources.
Source condition for size-group fractions that sets a value of one in a single group,...
virtual void write(Ostream &) const
Write.
singleSizeGroupFvScalarFieldSource(const DimensionedField< scalar, volMesh > &, const dictionary &dict)
Construct from internal field and dictionary.
virtual tmp< DimensionedField< scalar, volMesh > > sourceValue(const fvSource &model, const DimensionedField< scalar, volMesh > &source) const
Return the source value.
virtual ~singleSizeGroupFvScalarFieldSource()
Destructor.
virtual tmp< DimensionedField< scalar, volMesh > > internalCoeff(const fvSource &model, const DimensionedField< scalar, volMesh > &source) const
Return the internal coefficient.
A class for managing temporary objects.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
void write(std::ostream &os, const bool binary, List< floatScalar > &fField)
Write floats ascii or binary.
errorManipArg< error, int > exit(error &err, const int errNo=1)
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
const dimensionSet dimless
makeTypeFieldSource(fvScalarFieldSource, turbulentIntensityKineticEnergyFvScalarFieldSource)
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
void writeEntry(Ostream &os, const HashTable< T, Key, Hash > &ht)