42 const word& redirectType,
86 if (this->faceValues())
100 const auto* vPtr =
dynamic_cast<const VType*
>(ptr);
103 return vPtr->boundaryField()[patchi];
106 const auto* sPtr =
dynamic_cast<const SType*
>(ptr);
109 return sPtr->boundaryField()[patchi];
112 const auto* uPtr =
dynamic_cast<const UType*
>(ptr);
115 return Field<Type>(this->size(), uPtr->value());
124 const auto* uPtr =
dynamic_cast<const UType*
>(ptr);
127 return Field<Type>(this->size(), uPtr->value());
133 <<
" failed lookup of " << name_
134 <<
" (objectRegistry "
136 <<
")\n available objects of type " << VType::typeName
138 << db.
names<VType>() << nl
139 <<
" available objects of type " << SType::typeName
142 <<
" available objects of type " << UType::typeName
144 << db.
names<UType>() << nl
146 return Field<Type>::null();
151 typedef GeometricField<Type, pointPatchField, pointMesh> PType;
157 const auto* pPtr =
dynamic_cast<const PType*
>(ptr);
160 return pPtr->boundaryField()[patchi].patchInternalField();
180 return (x2-x1)*
value(0.5*(x1+x2));
uindirectPrimitivePatch pp(UIndirectList< face >(mesh.faces(), faceLabels), mesh.points())
Generic templated field type that is much like a Foam::List except that it is expected to hold numeri...
static const Field< Type > & null() noexcept
Return a null Field (reference to a nullObject). Behaves like an empty Field.
Generic GeometricField class.
const word & name() const noexcept
Return the object name.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
virtual Ostream & beginBlock(const keyType &kw)
Write begin block group with the given name.
PatchFunction1 to lookup volField/surfaceField or pointField from an objectregistry and return its va...
virtual tmp< Field< Type > > integrate(const scalar x1, const scalar x2) const
Integrate between two values.
virtual void writeData(Ostream &os) const
Write in dictionary format.
virtual tmp< Field< Type > > value(const scalar x) const
Return Lookup value.
LookupField(const polyPatch &pp, const word &redirectType, const word &entryName, const dictionary &dict, const bool faceValues=true)
Construct from entry name, dictionary and optional registry.
const polyPatch const word const word & entryName
virtual void writeData(Ostream &os) const
Write in dictionary format.
const polyPatch const word const word const dictionary & dict
const polyPatch const word const word const dictionary const bool faceValues
virtual void writeEntries(Ostream &os) const
Write coefficient entries in dictionary format.
lookupBase(const dictionary &dict)
Construct from dictionary.
Registry of regIOobjects.
const objectRegistry & parent() const noexcept
Return the parent objectRegistry.
const regIOobject * cfindIOobject(const word &name, const bool recursive=false) const
Return const pointer to the regIOobject.
wordList names() const
The unsorted names of all objects.
const Type & lookupObject(const word &name, const bool recursive=false) const
Lookup and return const reference to the object of the given Type. Fatal if not found or the wrong ty...
const polyPatch & patch() const noexcept
Reference to the patch.
const objectRegistry & obr() const
Return the object registry (ie, the mesh).
label size() const
Number of faces or points on the patch.
label index() const noexcept
The index of this patch in the boundaryMesh.
A patch is a list of labels that address the faces in the global face list.
regIOobject is an abstract class derived from IOobject to handle automatic object registration with t...
A class for managing temporary objects.
A class for handling words, derived from Foam::string.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
OBJstream os(runTime.globalPath()/outputName)
fileName::Type type(const fileName &name, const bool followLink=true)
Return the file type: DIRECTORY or FILE, normally following symbolic links.
void rhs(fvMatrix< typename Expr::value_type > &m, const Expr &expression)
error FatalError
Error stream (stdout output on all processes), with additional 'FOAM FATAL ERROR' header text and sta...
errorManipArg< error, int > exit(error &err, const int errNo=1)
constexpr char nl
The newline '\n' character (0x0a).