Go to the documentation of this file.
38 Info<<
nl <<
"Building tether potentials." <<
endl;
42 label tetherMapIndex = 0;
44 forAll(tetherSiteIdList, t)
46 word tetherPotentialName = tetherSiteIdList[t];
54 <<
"No matching entry found in siteIdList for tether name "
55 << tetherPotentialName
58 else if (!tetherPotentialDict.
found(tetherPotentialName))
61 <<
nl <<
"tether potential specification subDict "
62 << tetherPotentialName <<
" not found"
73 tetherPotentialDict.
subDict(tetherPotentialName)
78 idMap_[tetherId] = tetherMapIndex;
104 buildPotentials(siteIdList, tetherPotentialDict, tetherSiteIdList);
125 readTetherPotentialDict(siteIdList, tetherPotentialDict, tetherSiteIdList);
134 return (*
this)[tetherPotentialIndex(a)];
144 return (*
this)[tetherPotentialIndex(a)].force(rIT);
154 return (*
this)[tetherPotentialIndex(a)].energy(rIT);
vector force(const label a, const vector rIT) const
points setSize(newPointi)
A class for handling words, derived from string.
autoPtr< BasicCompressibleTurbulenceModel > New(const volScalarField &rho, const volVectorField &U, const surfaceScalarField &phi, const typename BasicCompressibleTurbulenceModel::transportModel &transport, const word &propertiesName)
#define forAll(list, i)
Loop across all elements in list.
~tetherPotentialList()
Destructor.
label findIndex(const ListType &, typename ListType::const_reference, const label start=0)
Find first occurence of given element and return index,.
scalar energy(const label a, const vector rIT) const
void buildPotentials(const List< word > &siteIdList, const dictionary &tetherPotentialDict, const List< word > &tetherSiteIdList)
Ostream & endl(Ostream &os)
Add newline and flush stream.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
bool found(const word &, bool recursive=false, bool patternMatch=true) const
Search dictionary for given keyword.
A templated 1D list of pointers to objects of type <T>, where the size of the array is known and used...
void readTetherPotentialDict(const List< word > &siteIdList, const dictionary &tetherPotentialDict, const List< word > &tetherSiteIdList)
A list of keyword definitions, which are a keyword followed by any number of values (e....
errorManip< error > abort(error &err)
const tetherPotential & tetherPotentialFunction(const label a) const
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
void size(const label)
Override size to be inconsistent with allocated storage.
const dictionary & subDict(const word &) const
Find and return a sub-dictionary.