46 #ifndef Foam_PatchFunction1_H 47 #define Foam_PatchFunction1_H 64 Ostream& operator<<(Ostream&, const PatchFunction1<Type>&);
176 const
bool mandatory = true
184 std::initializer_list<
std::pair<const
char*,
int>> compat,
187 const
bool mandatory = true
212 const
bool mandatory = true
223 virtual
bool constant()
const {
return false; }
226 virtual bool good()
const {
return true; }
229 virtual bool uniform()
const = 0;
235 virtual tmp<Field<Type>>
value(
const scalar
x)
const;
251 virtual tmp<Field<Type>>
transform(
const Field<Type>&
fld)
const;
276 friend Ostream& operator<< <Type>
294 #define makePatchFunction1(Type) \ 296 defineNamedTemplateTypeNameAndDebug(PatchFunction1<Type>, 0); \ 298 defineTemplateRunTimeSelectionTable \ 300 PatchFunction1<Type>, \ 306 #define makePatchFunction1Type(SS, Type) \ 308 defineNamedTemplateTypeNameAndDebug(PatchFunction1Types::SS<Type>, 0); \ 310 PatchFunction1<Type>::adddictionaryConstructorToTable \ 311 <PatchFunction1Types::SS<Type>> \ 312 add##SS##Type##ConstructorToTable_; 316 #define makeConcretePatchFunction1Type(SS, Type) \ 318 defineTypeNameAndDebug(SS, 0); \ 320 PatchFunction1<Type>::adddictionaryConstructorToTable \ 321 <PatchFunction1Types::SS> \ 322 add##SS##Type##ConstructorToTable_; 326 #define makeScalarPatchFunction1(SS) \ 328 makeConcretePatchFunction1Type(SS, scalar); A class for handling keywords in dictionaries.
A list of keyword definitions, which are a keyword followed by a number of values (eg...
virtual bool uniform() const =0
Is value uniform (i.e. independent of coordinate)
virtual tmp< Field< Type > > integrate(const scalar x1, const scalar x2) const
Integrate between two (scalar) values.
virtual bool constant() const
Is value constant (i.e. independent of x)
#define declareRunTimeSelectionTable(ptrWrapper, baseType, argNames, argList, parList)
Declare a run-time selection (variables and adder classes)
coordinateScaling< Type > coordSys_
Optional local coordinate system and scaling.
A HashTable of pointers to objects of type <T>, with deallocation management of the pointers...
const polyPatch const word const word const dictionary & dict
virtual bool good() const
Can function be evaluated?
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
static autoPtr< PatchFunction1< Type > > NewCompat(const polyPatch &pp, const word &entryName, std::initializer_list< std::pair< const char *, int >> compat, const dictionary &dict, const bool faceValues=true, const bool mandatory=true)
Compatibility selector.
A class for managing references or pointers (no reference counting)
Top level data entry class for use in dictionaries. Provides a mechanism to specify a variable as a c...
vectorField pointField
pointField is a vectorField.
Abstract base class to hold the Field mapping addressing and weights.
Generic templated field type.
A class for handling words, derived from Foam::string.
void operator=(const PatchFunction1< Type > &)=delete
No copy assignment.
const polyPatch const word & type
virtual tmp< pointField > localPosition(const pointField &globalPos) const
Helper: optionally convert coordinates to local coordinates.
virtual void autoMap(const FieldMapper &mapper)
Map (and resize as needed) from self given a mapping object.
const polyPatch const word const word & entryName
virtual void writeData(Ostream &os) const
Write in dictionary format.
bool faceValues() const noexcept
Generate face or point values on patch?
An Ostream is an abstract base class for all output systems (streams, files, token lists...
Top level data entry class for use in dictionaries. Provides a mechanism to specify a variable as a c...
OBJstream os(runTime.globalPath()/outputName)
virtual tmp< Field< Type > > value(const scalar x) const
Return value as a function of (scalar) independent variable.
Helper class to wrap coordinate system and component-wise scaling.
gmvFile<< "tracers "<< particles.size()<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().x()<< ' ';}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().y()<< ' ';}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().z()<< ' ';}gmvFile<< nl;for(const word &name :lagrangianScalarNames){ IOField< scalar > fld(IOobject(name, runTime.timeName(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE))
virtual tmp< PatchFunction1< Type > > clone() const =0
Return a clone.
virtual tmp< Field< Type > > transform(const Field< Type > &fld) const
Apply optional transformation.
static autoPtr< PatchFunction1< Type > > NewIfPresent(const polyPatch &pp, const word &entryName, const dictionary &dict, const bool faceValues=true)
An optional selector.
Pointer management similar to std::unique_ptr, with some additional methods and type checking...
TypeName("PatchFunction1") declareRunTimeSelectionTable(autoPtr
Runtime type information.
A class for managing temporary objects.
A patch is a list of labels that address the faces in the global face list.
virtual void rmap(const PatchFunction1< Type > &rhs, const labelList &addr)
Reverse map the given PatchFunction1 onto this PatchFunction1.
A keyword and a list of tokens is an 'entry'.
Field< Type > returnType
The return type is a field of values.