optionList Class Reference

List of finite volume options. More...

Inheritance diagram for optionList:
[legend]
Collaboration diagram for optionList:
[legend]

Public Member Functions

 TypeName ("optionList")
 Runtime type information. More...
 
 optionList (const fvPatch &p)
 Construct null. More...
 
 optionList (const fvPatch &, const dictionary &)
 Construct from mesh and dictionary. More...
 
virtual ~optionList ()
 Destructor. More...
 
void reset (const dictionary &dict)
 Reset the source list. More...
 
template<class Type >
tmp< faMatrix< Type > > operator() (const areaScalarField &h, GeometricField< Type, faPatchField, areaMesh > &field)
 Return source for equation. More...
 
template<class Type >
tmp< faMatrix< Type > > operator() (const areaScalarField &h, GeometricField< Type, faPatchField, areaMesh > &field, const word &fieldName)
 Return source for equation with specified name. More...
 
template<class Type >
tmp< faMatrix< Type > > operator() (const areaScalarField &h, const areaScalarField &rho, GeometricField< Type, faPatchField, areaMesh > &field)
 Return source for equation. More...
 
template<class Type >
tmp< faMatrix< Type > > operator() (const areaScalarField &h, const areaScalarField &rho, GeometricField< Type, faPatchField, areaMesh > &field, const word &fieldName)
 Return source for equation with specified name. More...
 
template<class Type >
tmp< faMatrix< Type > > operator() (const areaScalarField &rho, GeometricField< Type, faPatchField, areaMesh > &field, const dimensionSet &ds)
 Return source for equation with specified name and dimensios. More...
 
template<class Type >
tmp< faMatrix< Type > > d2dt2 (GeometricField< Type, faPatchField, areaMesh > &field)
 Return source for equation with second time derivative. More...
 
template<class Type >
tmp< faMatrix< Type > > d2dt2 (GeometricField< Type, faPatchField, areaMesh > &field, const word &fieldName)
 Return source for equation with second time derivative. More...
 
template<class Type >
void constrain (faMatrix< Type > &eqn)
 Apply constraints to equation. More...
 
template<class Type >
void correct (GeometricField< Type, faPatchField, areaMesh > &field)
 Apply correction to field. More...
 
virtual bool read (const dictionary &dict)
 Read dictionary. More...
 
virtual bool writeData (Ostream &os) const
 Write data to Ostream. More...
 
template<class Type >
Foam::tmp< Foam::faMatrix< Type > > source (GeometricField< Type, faPatchField, areaMesh > &field, const areaScalarField &h, const word &fieldName, const dimensionSet &ds)
 
template<class Type >
Foam::tmp< Foam::faMatrix< Type > > operator() (const areaScalarField &h, GeometricField< Type, faPatchField, areaMesh > &field)
 
template<class Type >
Foam::tmp< Foam::faMatrix< Type > > operator() (const areaScalarField &h, GeometricField< Type, faPatchField, areaMesh > &field, const word &fieldName)
 
template<class Type >
Foam::tmp< Foam::faMatrix< Type > > operator() (const areaScalarField &h, const areaScalarField &rho, GeometricField< Type, faPatchField, areaMesh > &field)
 
template<class Type >
Foam::tmp< Foam::faMatrix< Type > > operator() (const areaScalarField &h, const areaScalarField &rho, GeometricField< Type, faPatchField, areaMesh > &field, const word &fieldName)
 
template<class Type >
Foam::tmp< Foam::faMatrix< Type > > operator() (const areaScalarField &rho, GeometricField< Type, faPatchField, areaMesh > &field, const dimensionSet &ds)
 
template<class Type >
Foam::tmp< Foam::faMatrix< Type > > d2dt2 (GeometricField< Type, faPatchField, areaMesh > &field)
 
template<class Type >
Foam::tmp< Foam::faMatrix< Type > > d2dt2 (GeometricField< Type, faPatchField, areaMesh > &field, const word &fieldName)
 
template<class Type >
Foam::tmp< Foam::fvMatrix< Type > > source (GeometricField< Type, fvPatchField, volMesh > &field, const word &fieldName, const dimensionSet &ds)
 
template<class Type >
Foam::tmp< Foam::fvMatrix< Type > > operator() (GeometricField< Type, fvPatchField, volMesh > &field)
 
template<class Type >
Foam::tmp< Foam::fvMatrix< Type > > operator() (GeometricField< Type, fvPatchField, volMesh > &field, const word &fieldName)
 
template<class Type >
Foam::tmp< Foam::fvMatrix< Type > > operator() (const volScalarField &rho, GeometricField< Type, fvPatchField, volMesh > &field)
 
template<class Type >
Foam::tmp< Foam::fvMatrix< Type > > operator() (const volScalarField &rho, GeometricField< Type, fvPatchField, volMesh > &field, const word &fieldName)
 
template<class Type >
Foam::tmp< Foam::fvMatrix< Type > > operator() (const volScalarField &alpha, const volScalarField &rho, GeometricField< Type, fvPatchField, volMesh > &field)
 
template<class Type >
Foam::tmp< Foam::fvMatrix< Type > > operator() (const volScalarField &alpha, const volScalarField &rho, GeometricField< Type, fvPatchField, volMesh > &field, const word &fieldName)
 
template<class Type >
Foam::tmp< Foam::fvMatrix< Type > > operator() (const geometricOneField &alpha, const geometricOneField &rho, GeometricField< Type, fvPatchField, volMesh > &field)
 
template<class Type >
Foam::tmp< Foam::fvMatrix< Type > > operator() (const volScalarField &alpha, const geometricOneField &rho, GeometricField< Type, fvPatchField, volMesh > &field)
 
template<class Type >
Foam::tmp< Foam::fvMatrix< Type > > operator() (const geometricOneField &alpha, const volScalarField &rho, GeometricField< Type, fvPatchField, volMesh > &field)
 
template<class Type >
Foam::tmp< Foam::fvMatrix< Type > > d2dt2 (GeometricField< Type, fvPatchField, volMesh > &field)
 
template<class Type >
Foam::tmp< Foam::fvMatrix< Type > > d2dt2 (GeometricField< Type, fvPatchField, volMesh > &field, const word &fieldName)
 
- Public Member Functions inherited from PtrList< option >
constexpr PtrList () noexcept
 Default construct. More...
 
 PtrList (const label len)
 Construct with specified size, each element initialized to nullptr. More...
 
 PtrList (const PtrList< option > &list)
 Copy construct using 'clone()' method on each element. More...
 
 PtrList (PtrList< option > &&list)
 Move construct. More...
 
 PtrList (UList< option * > &list)
 Take ownership of pointers in the list, set old pointers to null. More...
 
 PtrList (const PtrList< option > &list, const CloneArg &cloneArgs)
 Copy construct using 'clone()' method on each element. More...
 
 PtrList (PtrList< option > &list, bool reuse)
 Construct as copy or re-use as specified. More...
 
 PtrList (const SLPtrList< option > &list)
 Copy construct using 'clone()' on each element of SLPtrList<T> More...
 
 PtrList (Istream &is, const INew &inew)
 Construct from Istream using given Istream constructor class. More...
 
 PtrList (Istream &is)
 Construct from Istream using default Istream constructor class. More...
 
 ~PtrList ()
 Destructor. More...
 
PtrList< option > clone (Args &&... args) const
 Make a copy by cloning each of the list elements. More...
 
Foam::PtrList< option > clone (Args &&... args) const
 
const option * set (const label i) const
 Return const pointer to element (can be nullptr),. More...
 
autoPtr< option > set (const label i, option *ptr)
 Set element to given pointer and return old element (can be null) More...
 
autoPtr< option > set (const label i, autoPtr< option > &ptr)
 Set element to given autoPtr and return old element. More...
 
autoPtr< option > set (const label i, autoPtr< option > &&ptr)
 Set element to given autoPtr and return old element. More...
 
autoPtr< option > set (const label i, std::unique_ptr< option > &&ptr)
 Set element to given unique_ptr and return old element. More...
 
autoPtr< option > set (const label i, const refPtr< option > &ptr)
 Set element to given refPtr and return old element. More...
 
autoPtr< option > set (const label i, const tmp< option > &ptr)
 Set element to given tmp and return old element. More...
 
void clear ()
 Clear the PtrList. Delete allocated entries and set size to zero. More...
 
void resize (const label newLen)
 Adjust size of PtrList. More...
 
void setSize (const label newLen)
 Same as resize() More...
 
void emplace_append (Args &&... args)
 Construct and append an element to the end of the list. More...
 
void append (option *ptr)
 Append an element to the end of the list. More...
 
void append (autoPtr< option > &ptr)
 Move append an element to the end of the list. More...
 
void append (autoPtr< option > &&ptr)
 Move append an element to the end of the list. More...
 
void append (std::unique_ptr< option > &&ptr)
 Move append an element to the end of the list. More...
 
void append (const refPtr< option > &ptr)
 Move or clone append a refPtr to the end of the list. More...
 
void append (const tmp< option > &ptr)
 Move or clone append a tmp to the end of the list. More...
 
autoPtr< option > emplace (const label i, Args &&... args)
 Construct and set an element. More...
 
Foam::autoPtr< option > emplace (const label i, Args &&... args)
 
autoPtr< option > release (const label i)
 Release ownership of the pointer at the given position. More...
 
void transfer (PtrList< option > &list)
 Transfer into this list and annul the argument list. More...
 
void operator= (const PtrList< option > &list)
 Copy assignment. More...
 
void operator= (PtrList< option > &&list)
 Move assignment. More...
 

Protected Member Functions

const dictionaryoptionsDict (const dictionary &dict) const
 Return the "options" sub-dictionary if present otherwise return dict. More...
 
bool readOptions (const dictionary &dict)
 Read options dictionary. More...
 
void checkApplied () const
 Check that all sources have been applied. More...
 
template<class Type >
tmp< faMatrix< Type > > source (GeometricField< Type, faPatchField, areaMesh > &field, const areaScalarField &h, const word &fieldName, const dimensionSet &ds)
 Return source for equation with specified name and dimensions. More...
 
 optionList (const optionList &)=delete
 No copy construct. More...
 
void operator= (const optionList &)=delete
 No copy assignment. More...
 
- Protected Member Functions inherited from PtrList< option >
void readIstream (Istream &is, const INew &inew)
 Read from Istream using Istream constructor class. More...
 
void free ()
 Delete the allocated entries, but retain the list size. More...
 

Protected Attributes

const fvMeshmesh_
 Reference to the mesh database. More...
 
const fvPatchpatch_
 Reference to the patch. More...
 
label checkTimeIndex_
 Time index to check that all defined sources have been applied. More...
 

Friends

Ostreamoperator<< (Ostream &os, const optionList &options)
 Ostream operator. More...
 

Detailed Description

List of finite volume options.

SourceFile optionList.C

Definition at line 66 of file faOptionList.H.

Constructor & Destructor Documentation

◆ optionList() [1/3]

optionList ( const optionList )
protecteddelete

No copy construct.

◆ optionList() [2/3]

optionList ( const fvPatch p)

Construct null.

Definition at line 104 of file faOptionList.C.

◆ optionList() [3/3]

optionList ( const fvPatch p,
const dictionary dict 
)

Construct from mesh and dictionary.

Definition at line 90 of file faOptionList.C.

References dict.

◆ ~optionList()

virtual ~optionList ( )
inlinevirtual

Destructor.

Definition at line 128 of file faOptionList.H.

Member Function Documentation

◆ optionsDict()

const Foam::dictionary & optionsDict ( const dictionary dict) const
protected

Return the "options" sub-dictionary if present otherwise return dict.

Definition at line 44 of file faOptionList.C.

References dict.

◆ readOptions()

bool readOptions ( const dictionary dict)
protected

Read options dictionary.

Definition at line 59 of file faOptionList.C.

References optionList::checkTimeIndex_, dict, forAll, optionList::mesh_, option::name(), option::read(), fvMesh::time(), and TimeState::timeIndex().

Here is the call graph for this function:

◆ checkApplied()

void checkApplied ( ) const
protected

Check that all sources have been applied.

Definition at line 74 of file faOptionList.C.

References option::checkApplied(), and forAll.

Referenced by optionList::constrain().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ source() [1/3]

tmp<faMatrix<Type> > source ( GeometricField< Type, faPatchField, areaMesh > &  field,
const areaScalarField h,
const word fieldName,
const dimensionSet ds 
)
protected

Return source for equation with specified name and dimensions.

Referenced by optionList::constrain().

Here is the caller graph for this function:

◆ operator=()

void operator= ( const optionList )
protecteddelete

No copy assignment.

◆ TypeName()

TypeName ( "optionList"  )

Runtime type information.

◆ reset()

void reset ( const dictionary dict)

Reset the source list.

Definition at line 115 of file faOptionList.C.

References Foam::BitOps::count(), dict, Foam::name(), option::New(), resize(), and Foam::BitOps::set().

Here is the call graph for this function:

◆ operator()() [1/19]

tmp<faMatrix<Type> > operator() ( const areaScalarField h,
GeometricField< Type, faPatchField, areaMesh > &  field 
)

Return source for equation.

◆ operator()() [2/19]

tmp<faMatrix<Type> > operator() ( const areaScalarField h,
GeometricField< Type, faPatchField, areaMesh > &  field,
const word fieldName 
)

Return source for equation with specified name.

◆ operator()() [3/19]

tmp<faMatrix<Type> > operator() ( const areaScalarField h,
const areaScalarField rho,
GeometricField< Type, faPatchField, areaMesh > &  field 
)

Return source for equation.

◆ operator()() [4/19]

tmp<faMatrix<Type> > operator() ( const areaScalarField h,
const areaScalarField rho,
GeometricField< Type, faPatchField, areaMesh > &  field,
const word fieldName 
)

Return source for equation with specified name.

◆ operator()() [5/19]

tmp<faMatrix<Type> > operator() ( const areaScalarField rho,
GeometricField< Type, faPatchField, areaMesh > &  field,
const dimensionSet ds 
)

Return source for equation with specified name and dimensios.

◆ d2dt2() [1/6]

tmp<faMatrix<Type> > d2dt2 ( GeometricField< Type, faPatchField, areaMesh > &  field)

Return source for equation with second time derivative.

◆ d2dt2() [2/6]

tmp<faMatrix<Type> > d2dt2 ( GeometricField< Type, faPatchField, areaMesh > &  field,
const word fieldName 
)

Return source for equation with second time derivative.

◆ constrain()

void constrain ( faMatrix< Type > &  eqn)

Apply constraints to equation.

Definition at line 224 of file faOptionListTemplates.C.

References addProfiling, optionList::checkApplied(), Foam::expressions::patchExpr::debug, Foam::endl(), forAll, Foam::Info, faMatrix< Type >::psi(), and optionList::source().

Referenced by KirchhoffShell::solveDisplacement(), and thermalShell::solveEnergy().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ correct()

void correct ( GeometricField< Type, faPatchField, areaMesh > &  field)

Apply correction to field.

Definition at line 257 of file faOptionListTemplates.C.

References addProfiling, option::applyToField(), option::correct(), Foam::expressions::patchExpr::debug, Foam::endl(), field(), forAll, Foam::Info, option::isActive(), option::name(), and option::setApplied().

Referenced by KirchhoffShell::solveDisplacement(), and thermalShell::solveEnergy().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ read()

bool read ( const dictionary dict)
virtual

Read dictionary.

Definition at line 147 of file faOptionList.C.

References dict.

Referenced by options::read().

Here is the caller graph for this function:

◆ writeData()

bool writeData ( Ostream os) const
virtual

Write data to Ostream.

Definition at line 153 of file faOptionList.C.

References forAll, IOstream::good(), and Foam::nl.

Referenced by Foam::operator<<().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ source() [2/3]

Foam::tmp<Foam::faMatrix<Type> > source ( GeometricField< Type, faPatchField, areaMesh > &  field,
const areaScalarField h,
const word fieldName,
const dimensionSet ds 
)

Definition at line 34 of file faOptionListTemplates.C.

References addProfiling, option::addSup(), option::applyToField(), Foam::expressions::patchExpr::debug, Foam::endl(), field(), forAll, Foam::constant::universal::h, Foam::Info, option::isActive(), option::name(), tmp< T >::ref(), and option::setApplied().

Here is the call graph for this function:

◆ operator()() [6/19]

Foam::tmp<Foam::faMatrix<Type> > operator() ( const areaScalarField h,
GeometricField< Type, faPatchField, areaMesh > &  field 
)

Definition at line 77 of file faOptionListTemplates.C.

References field(), and Foam::constant::universal::h.

Here is the call graph for this function:

◆ operator()() [7/19]

Foam::tmp<Foam::faMatrix<Type> > operator() ( const areaScalarField h,
GeometricField< Type, faPatchField, areaMesh > &  field,
const word fieldName 
)

Definition at line 88 of file faOptionListTemplates.C.

References Foam::dimArea, Foam::dimTime, field(), and Foam::constant::universal::h.

Here is the call graph for this function:

◆ operator()() [8/19]

Foam::tmp<Foam::faMatrix<Type> > operator() ( const areaScalarField h,
const areaScalarField rho,
GeometricField< Type, faPatchField, areaMesh > &  field 
)

Definition at line 100 of file faOptionListTemplates.C.

References field(), Foam::constant::universal::h, and rho.

Here is the call graph for this function:

◆ operator()() [9/19]

Foam::tmp<Foam::faMatrix<Type> > operator() ( const areaScalarField h,
const areaScalarField rho,
GeometricField< Type, faPatchField, areaMesh > &  field,
const word fieldName 
)

Definition at line 112 of file faOptionListTemplates.C.

References addProfiling, option::addSup(), option::applyToField(), Foam::expressions::patchExpr::debug, Foam::dimArea, Foam::dimTime, Foam::endl(), field(), forAll, Foam::constant::universal::h, Foam::Info, option::isActive(), option::name(), rho, and option::setApplied().

Here is the call graph for this function:

◆ operator()() [10/19]

Foam::tmp<Foam::faMatrix<Type> > operator() ( const areaScalarField rho,
GeometricField< Type, faPatchField, areaMesh > &  field,
const dimensionSet ds 
)

Definition at line 160 of file faOptionListTemplates.C.

References addProfiling, option::addSup(), option::applyToField(), Foam::expressions::patchExpr::debug, Foam::dimArea, Foam::endl(), field(), forAll, Foam::Info, option::isActive(), option::name(), tmp< T >::ref(), rho, and option::setApplied().

Here is the call graph for this function:

◆ d2dt2() [3/6]

Foam::tmp<Foam::faMatrix<Type> > d2dt2 ( GeometricField< Type, faPatchField, areaMesh > &  field)

Definition at line 204 of file faOptionListTemplates.C.

References Foam::fac::d2dt2(), and field().

Here is the call graph for this function:

◆ d2dt2() [4/6]

Foam::tmp<Foam::faMatrix<Type> > d2dt2 ( GeometricField< Type, faPatchField, areaMesh > &  field,
const word fieldName 
)

Definition at line 214 of file faOptionListTemplates.C.

References Foam::dimArea, Foam::dimTime, field(), and Foam::sqr().

Here is the call graph for this function:

◆ source() [3/3]

Foam::tmp<Foam::fvMatrix<Type> > source ( GeometricField< Type, fvPatchField, volMesh > &  field,
const word fieldName,
const dimensionSet ds 
)

Definition at line 37 of file fvOptionListTemplates.C.

References addProfiling, option::addSup(), option::applyToField(), Foam::expressions::patchExpr::debug, Foam::endl(), field(), forAll, Foam::Info, option::isActive(), option::name(), tmp< T >::ref(), and option::setApplied().

Here is the call graph for this function:

◆ operator()() [11/19]

Foam::tmp<Foam::fvMatrix<Type> > operator() ( GeometricField< Type, fvPatchField, volMesh > &  field)

Definition at line 79 of file fvOptionListTemplates.C.

References field().

Here is the call graph for this function:

◆ operator()() [12/19]

Foam::tmp<Foam::fvMatrix<Type> > operator() ( GeometricField< Type, fvPatchField, volMesh > &  field,
const word fieldName 
)

Definition at line 89 of file fvOptionListTemplates.C.

References Foam::dimTime, Foam::dimVolume, and field().

Here is the call graph for this function:

◆ operator()() [13/19]

Foam::tmp<Foam::fvMatrix<Type> > operator() ( const volScalarField rho,
GeometricField< Type, fvPatchField, volMesh > &  field 
)

Definition at line 100 of file fvOptionListTemplates.C.

References field(), and rho.

Here is the call graph for this function:

◆ operator()() [14/19]

Foam::tmp<Foam::fvMatrix<Type> > operator() ( const volScalarField rho,
GeometricField< Type, fvPatchField, volMesh > &  field,
const word fieldName 
)

Definition at line 111 of file fvOptionListTemplates.C.

References addProfiling, option::addSup(), option::applyToField(), Foam::expressions::patchExpr::debug, Foam::dimTime, Foam::dimVolume, Foam::endl(), field(), forAll, Foam::Info, option::isActive(), option::name(), rho, and option::setApplied().

Here is the call graph for this function:

◆ operator()() [15/19]

Foam::tmp<Foam::fvMatrix<Type> > operator() ( const volScalarField alpha,
const volScalarField rho,
GeometricField< Type, fvPatchField, volMesh > &  field 
)

Definition at line 158 of file fvOptionListTemplates.C.

References Foam::constant::atomic::alpha, field(), and rho.

Here is the call graph for this function:

◆ operator()() [16/19]

Foam::tmp<Foam::fvMatrix<Type> > operator() ( const volScalarField alpha,
const volScalarField rho,
GeometricField< Type, fvPatchField, volMesh > &  field,
const word fieldName 
)

Definition at line 170 of file fvOptionListTemplates.C.

References addProfiling, option::addSup(), Foam::constant::atomic::alpha, option::applyToField(), Foam::expressions::patchExpr::debug, dimensioned< Type >::dimensions(), Foam::dimTime, Foam::dimVolume, Foam::endl(), field(), forAll, Foam::Info, option::isActive(), option::name(), rho, and option::setApplied().

Here is the call graph for this function:

◆ operator()() [17/19]

Foam::tmp<Foam::fvMatrix<Type> > operator() ( const geometricOneField alpha,
const geometricOneField rho,
GeometricField< Type, fvPatchField, volMesh > &  field 
)

Definition at line 219 of file fvOptionListTemplates.C.

References field().

Here is the call graph for this function:

◆ operator()() [18/19]

Foam::tmp<Foam::fvMatrix<Type> > operator() ( const volScalarField alpha,
const geometricOneField rho,
GeometricField< Type, fvPatchField, volMesh > &  field 
)

Definition at line 231 of file fvOptionListTemplates.C.

References Foam::constant::atomic::alpha, Foam::dimless, and field().

Here is the call graph for this function:

◆ operator()() [19/19]

Foam::tmp<Foam::fvMatrix<Type> > operator() ( const geometricOneField alpha,
const volScalarField rho,
GeometricField< Type, fvPatchField, volMesh > &  field 
)

Definition at line 258 of file fvOptionListTemplates.C.

References field(), and rho.

Here is the call graph for this function:

◆ d2dt2() [5/6]

Foam::tmp<Foam::fvMatrix<Type> > d2dt2 ( GeometricField< Type, fvPatchField, volMesh > &  field)

Definition at line 270 of file fvOptionListTemplates.C.

References Foam::fac::d2dt2(), and field().

Here is the call graph for this function:

◆ d2dt2() [6/6]

Foam::tmp<Foam::fvMatrix<Type> > d2dt2 ( GeometricField< Type, fvPatchField, volMesh > &  field,
const word fieldName 
)

Definition at line 280 of file fvOptionListTemplates.C.

References Foam::dimTime, Foam::dimVolume, field(), and Foam::sqr().

Here is the call graph for this function:

Friends And Related Function Documentation

◆ operator<<

Ostream& operator<< ( Ostream os,
const optionList options 
)
friend

Ostream operator.

Member Data Documentation

◆ mesh_

const fvMesh& mesh_
protected

Reference to the mesh database.

Definition at line 75 of file faOptionList.H.

Referenced by optionList::readOptions().

◆ patch_

const fvPatch& patch_
protected

Reference to the patch.

Definition at line 78 of file faOptionList.H.

◆ checkTimeIndex_

label checkTimeIndex_
protected

Time index to check that all defined sources have been applied.

Definition at line 81 of file faOptionList.H.

Referenced by optionList::readOptions().


The documentation for this class was generated from the following files: