Go to the documentation of this file.
45 #ifndef pointPatchField_H
46 #define pointPatchField_H
61 class pointPatchFieldMapper;
64 template<
class Type>
class pointPatchField;
65 template<
class Type>
class calculatedPointPatchField;
68 Ostream&
operator<<(Ostream&,
const pointPatchField<Type>&);
81 const pointPatch& patch_;
84 const DimensionedField<Type, pointMesh>& internalField_;
135 (
dynamic_cast<const pointPatchFieldType&
>(ptf),
p, iF, m)
217 const word& actualPatchType,
243 template<
class Type2>
278 return internalField_;
284 return internalField_;
322 template<
class Type1>
330 template<
class Type1>
339 template<
class Type1>
348 template<
class Type1>
358 template<
class Type1>
368 template<
class Type1>
467 friend Ostream& operator<< <Type>
470 const pointPatchField<Type>&
512 #define addToPointPatchFieldRunTimeSelection(PatchTypeField, typePatchTypeField) \
513 addToRunTimeSelectionTable \
516 typePatchTypeField, \
519 addToRunTimeSelectionTable \
522 typePatchTypeField, \
525 addToRunTimeSelectionTable \
528 typePatchTypeField, \
534 #define makePointPatchTypeField(PatchTypeField,typePatchTypeField) \
535 defineTypeNameAndDebug(typePatchTypeField, 0); \
536 addToPointPatchFieldRunTimeSelection(PatchTypeField, typePatchTypeField)
540 #define makeTemplatePointPatchTypeField(PatchTypeField, typePatchTypeField) \
541 defineNamedTemplateTypeNameAndDebug(typePatchTypeField, 0); \
542 addToPointPatchFieldRunTimeSelection(PatchTypeField, typePatchTypeField)
545 #define makePointPatchFields(type) \
546 makeTemplatePointPatchTypeField \
548 pointPatchScalarField, \
549 type##PointPatchScalarField \
551 makeTemplatePointPatchTypeField \
553 pointPatchVectorField, \
554 type##PointPatchVectorField \
556 makeTemplatePointPatchTypeField \
558 pointPatchSphericalTensorField, \
559 type##PointPatchSphericalTensorField \
561 makeTemplatePointPatchTypeField \
563 pointPatchSymmTensorField, \
564 type##PointPatchSymmTensorField \
566 makeTemplatePointPatchTypeField \
568 pointPatchTensorField, \
569 type##PointPatchTensorField \
573 #define makePointPatchFieldsTypeName(type) \
574 defineNamedTemplateTypeNameAndDebug(type##PointPatchScalarField, 0); \
575 defineNamedTemplateTypeNameAndDebug(type##PointPatchVectorField, 0); \
576 defineNamedTemplateTypeNameAndDebug \
578 type##PointPatchSphericalTensorField, 0 \
580 defineNamedTemplateTypeNameAndDebug(type##PointPatchSymmTensorField, 0); \
581 defineNamedTemplateTypeNameAndDebug(type##PointPatchTensorField, 0)
584 #define makePointPatchFieldTypedefs(type) \
585 typedef type##PointPatchField<scalar> type##PointPatchScalarField; \
586 typedef type##PointPatchField<vector> type##PointPatchVectorField; \
587 typedef type##PointPatchField<sphericalTensor> \
588 type##PointPatchSphericalTensorField; \
589 typedef type##PointPatchField<symmTensor> type##PointPatchSymmTensorField;\
590 typedef type##PointPatchField<tensor> type##PointPatchTensorField;
word & patchType()
Optional patch type.
void addToInternalField(Field< Type1 > &iF, const Field< Type1 > &pF) const
Given the internal field and a patch field,.
virtual void operator+=(const pointPatchField< Type > &)
virtual void operator*=(const Field< scalar > &)
virtual void operator/=(const pointPatchField< scalar > &)
const Field< Type > & primitiveField() const
Return internal field reference.
A class for handling words, derived from Foam::string.
virtual void operator-=(const Field< Type > &)
virtual void operator==(const pointPatchField< Type > &)
virtual void operator+=(const Field< Type > &)
A class for managing temporary objects.
virtual void evaluate(const Pstream::commsTypes commsType=Pstream::commsTypes::blocking)
Evaluate the patch field.
static autoPtr< pointPatchField< Type > > NewCalculatedType(const pointPatchField< Type2 > &)
Return a pointer to a new calculatedPointPatchField created on.
const objectRegistry & db() const
Return local objectRegistry.
virtual void operator/=(const Field< scalar > &)
virtual void operator=(const Type &)
pointPatchField(const pointPatch &, const DimensionedField< Type, pointMesh > &)
Construct from patch and internal field.
static const word & calculatedType()
Return the type of the calculated form of pointPatchField.
Basic pointPatch represents a set of points from the mesh.
Abstract base class for point-mesh patch fields.
void setInInternalField(Field< Type1 > &iF, const Field< Type1 > &pF, const labelList &meshPoints) const
Given the internal field and a patch field,.
const pointPatch & patch() const
Return patch.
Foam::pointPatchFieldMapper.
Registry of regIOobjects.
virtual void operator+=(const Type &)
virtual void operator=(const pointPatchField< Type > &)
virtual void operator-=(const Type &)
Ostream & operator<<(Ostream &, const boundaryPatch &p)
Write boundaryPatch as dictionary entries (without surrounding braces)
virtual void rmap(const pointPatchField< Type > &, const labelList &)
Reverse map the given pointPatchField onto this pointPatchField.
virtual void operator/=(const scalar)
virtual void operator=(const Field< Type > &)
virtual const word & constraintType() const
Return the constraint type this pointPatchField implements.
Generic templated field type.
virtual void operator-=(const pointPatchField< Type > &)
const word & patchType() const
Optional patch type.
calculatedPointPatchField< Type > Calculated
const DimensionedField< Type, pointMesh > & internalField() const
Return dimensioned internal field reference.
A calculated boundary condition for pointField.
virtual void write(Ostream &) const
Write.
declareRunTimeSelectionTable(autoPtr, pointPatchField, pointPatch,(const pointPatch &p, const DimensionedField< Type, pointMesh > &iF),(p, iF))
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
label size() const
Return size.
virtual void initEvaluate(const Pstream::commsTypes commsType=Pstream::commsTypes::blocking)
Initialise evaluation of the patch field (do nothing)
static int disallowGenericPointPatchField
Debug switch to disallow the use of genericPointPatchField.
static autoPtr< pointPatchField< Type > > New(const word &, const pointPatch &, const DimensionedField< Type, pointMesh > &)
Return a pointer to a new patchField created on freestore given.
virtual label size() const =0
Return size.
bool updated() const
Return true if the boundary condition has already been updated.
commsTypes
Types of communications.
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
virtual autoPtr< pointPatchField< Type > > clone() const =0
Construct and return a clone.
virtual void operator*=(const pointPatchField< scalar > &)
virtual bool coupled() const
Return true if this patch field is coupled.
static const word null
An empty word.
virtual void updateCoeffs()
Update the coefficients associated with the patch field.
tmp< Field< Type > > patchInternalField() const
Return field created from appropriate internal field values.
void negate()
Negate the field inplace.
virtual void operator*=(const scalar)
virtual bool fixesValue() const
Return true if this patch field fixes a value.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
virtual void operator==(const Field< Type > &)
virtual void operator==(const Type &)
TypeName("pointPatchField")
Runtime type information.
virtual void autoMap(const pointPatchFieldMapper &)
Map (and resize as needed) from self given a mapping object.
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...