61 scalar d =
mag(Cf[celli] -
x0_);
67 else if ((d >=
r1_) && (d <=
r2_))
82 const word& modelType,
109 URefName_(
"unknown-URef"),
125 const volScalarField coeff(name_ +
":coeff", w_*frequency_*blendFactor_);
144 const volScalarField coeff(name_ +
":coeff", w_*frequency_*blendFactor_);
164 const volScalarField coeff(name_ +
":coeff", w_*frequency_*blendFactor_);
179 if (!coeffs_.readIfPresent(
"UNames", fieldNames_))
181 fieldNames_.resize(1);
182 fieldNames_.first() = coeffs_.getOrDefault<
word>(
"U",
"U");
187 coeffs_.readEntry(
"frequency", frequency_.value());
188 coeffs_.readEntry(
"URef", URefName_);
189 coeffs_.readCompat<
vector>(
"origin", {{
"centre", -1806}}, x0_);
190 coeffs_.readEntry(
"radius1", r1_);
191 coeffs_.readEntry(
"radius2", r2_);
193 if (coeffs_.readIfPresent(
"w", w_))
195 Info<< name_ <<
": Setting stencil width to " << w_ <<
endl;
Macros for easy insertion into run-time selection tables.
#define addToRunTimeSelectionTable(baseType, thisType, argNames)
Add to construction table with typeName as the key.
Internal::FieldType & primitiveFieldRef(const bool updateAccessTime=true)
Return a reference to the internal field.
void correctBoundaryConditions()
Correct boundary field.
Defines the attributes of an object for which implicit objectRegistry management is supported,...
virtual bool read()
Re-read model coefficients if they have changed.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
A special matrix type and solver, designed for finite volume solutions of scalar equations....
const GeometricField< Type, fvPatchField, volMesh > & psi(const label i=0) const
Return psi.
Mesh data needed to do the Finite Volume discretisation.
const volVectorField & C() const
Return cell centres as volVectorField.
Applies sources on velocity (i.e. U) within a specified region to enable acoustic damping.
volScalarField blendFactor_
Blending factor [-].
virtual bool read(const dictionary &dict)
Read dictionary.
virtual void addSup(fvMatrix< vector > &eqn, const label fieldI)
Add implicit contribution to momentum equation.
void setBlendingFactor()
Helper function to set the blending factor.
Intermediate abstract class for handling cell-set options for the derived fvOptions.
labelList cells_
Set of cells to apply source to.
Base abstract class for handling finite volume options (i.e. fvOption).
const fvMesh & mesh_
Reference to the mesh database.
void resetApplied()
Resize/reset applied flag list for all fieldNames_ entries.
A class for handling words, derived from Foam::string.
This boundary condition applies a zero-gradient condition from the patch internal field onto the patc...
#define defineTypeNameAndDebug(Type, DebugSwitch)
Define the typeName and debug information.
A special matrix type and solver, designed for finite volume solutions of scalar equations.
Calculate the finiteVolume matrix for implicit and explicit sources.
constexpr scalar pi(M_PI)
zeroField Sp(const Foam::zero, const GeometricField< Type, fvPatchField, volMesh > &)
A no-op source.
const dimensionSet dimless
Dimensionless.
const dimensionSet dimTime(0, 0, 1, 0, 0, 0, 0)
messageStream Info
Information stream (stdout output on master, null elsewhere)
Ostream & endl(Ostream &os)
Add newline and flush stream.
dimensioned< typename typeOfMag< Type >::type > mag(const dimensioned< Type > &dt)
static constexpr const zero Zero
Global zero (0)
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for INVALID.
dimensionedScalar cos(const dimensionedScalar &ds)
#define forAll(list, i)
Loop across all elements in list.