Go to the documentation of this file.
38 #ifndef porosityModel_H
39 #define porosityModel_H
137 inline label
fieldIndex(
const label index)
const;
152 const word& modelName,
156 const word& cellZoneName
165 const word& modelType,
226 inline bool active()
const;
274 virtual bool global()
const
virtual ~porosityModel()=default
Destructor.
A class for handling words, derived from Foam::string.
const labelList & cellZoneIDs() const
Return const access to the cell zone IDs.
virtual void calcTransformModelData()=0
Transform the model data wrt mesh changes.
const dictionary dict_
Dictionary used for model construction.
A class for handling file names.
const dimensionedScalar mu
Atomic mass unit.
A class for managing temporary objects.
const word & name() const
Return const access to the porosity model name.
virtual bool read()
Read object.
declareRunTimeSelectionTable(autoPtr, porosityModel, mesh,(const word &modelName, const word &name, const fvMesh &mesh, const dictionary &dict, const word &cellZoneName),(modelName, name, mesh, dict, cellZoneName))
Selection table.
bool active_
Porosity active flag.
bool typeGlobal< porosityModel >()
Template function for obtaining global status.
Forward declarations of fvMatrix specializations.
labelList cellZoneIDs_
Cell zone IDs.
dictionary coeffs_
Model coefficients dictionary.
virtual void calcForce(const volVectorField &U, const volScalarField &rho, const volScalarField &mu, vectorField &force) const =0
Calculate the porosity force.
A class for handling keywords in dictionaries.
virtual void transformModelData()
Transform the model data wrt mesh changes.
virtual tmp< vectorField > force(const volVectorField &U, const volScalarField &rho, const volScalarField &mu)
Return the force over the cell zone(s)
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
iNew(const fvMesh &mesh, const word &name)
virtual fileName filePath() const
Return complete path + object name if the file exists.
void adjustNegativeResistance(dimensionedVector &resist)
Adjust negative resistance values to be multiplier of max value.
autoPtr< porosityModel > operator()(Istream &is) const
TypeName("porosityModel")
Runtime type information.
virtual void correct(fvVectorMatrix &UEqn) const =0
fileName globalFilePath(const word &typeName, const bool search=true) const
Helper for filePath that searches up if in parallel.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Mesh data needed to do the Finite Volume discretisation.
virtual bool writeData(Ostream &os) const
Write.
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
Top level model for porosity models.
regIOobject is an abstract class derived from IOobject to handle automatic object registration with t...
Macros to ease declaration of run-time selection tables.
label fieldIndex(const label index) const
Return label index.
fileName::Type type(const fileName &name, const bool followLink=true)
Return the file type: DIRECTORY or FILE, normally following symbolic links.
virtual bool global() const
Is object global.
static const word null
An empty word.
bool active() const
Return const access to the porosity active flag.
const coordinateSystem & csys() const
Local coordinate system.
A special matrix type and solver, designed for finite volume solutions of scalar equations....
Return pointer to new porosityModel object created on the freestore.
virtual void addResistance(fvVectorMatrix &UEqn)
Add resistance.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
static autoPtr< porosityModel > New(const word &name, const fvMesh &mesh, const dictionary &dict, const word &cellZoneName=word::null)
Selector.
autoPtr< coordinateSystem > csysPtr_
Local coordinate system.
keyType zoneName_
Name(s) of cell-zone.
const dictionary & dict() const
Return dictionary used for model construction.
const fvMesh & mesh_
Reference to the mesh database.
Base class for coordinate system specification, the default coordinate system type is cartesian .