47 #ifndef Foam_fvsPatchField_H 48 #define Foam_fvsPatchField_H 61 class fvPatchFieldMapper;
64 template<
class Type>
class fvsPatchField;
65 template<
class Type>
class calculatedFvsPatchField;
68 Ostream& operator<<(Ostream&, const fvsPatchField<Type>&);
194 (dynamic_cast<const fvsPatchFieldType&>(ptf),
p, iF, m)
234 const bool valueRequired=
true 277 static tmp<fvsPatchField<Type>>
New 279 const word& patchFieldType,
281 const DimensionedField<Type, surfaceMesh>&
288 static tmp<fvsPatchField<Type>>
New 290 const word& patchFieldType,
291 const word& actualPatchType,
293 const DimensionedField<Type, surfaceMesh>&
298 static tmp<fvsPatchField<Type>>
New 300 const fvsPatchField<Type>&,
324 template<
class Type2>
364 return internalField_;
370 return internalField_;
379 const fvPatchFieldMapper&
385 const fvsPatchField<Type>&,
391 virtual void write(Ostream&)
const;
397 void check(
const fvsPatchField<Type>&)
const;
402 virtual void operator=(
const UList<Type>&);
404 virtual void operator=(
const fvsPatchField<Type>&);
405 virtual void operator+=(
const fvsPatchField<Type>&);
406 virtual void operator-=(
const fvsPatchField<Type>&);
407 virtual void operator*=(
const fvsPatchField<scalar>&);
408 virtual void operator/=(
const fvsPatchField<scalar>&);
413 virtual void operator*=(
const Field<scalar>&);
414 virtual void operator/=(
const Field<scalar>&);
451 #define makeFvsPatchTypeFieldTypeName(type) \ 453 defineNamedTemplateTypeNameAndDebug(type, 0); 455 #define makeFvsPatchFieldsTypeName(type) \ 457 makeFvsPatchTypeFieldTypeName(type##FvsPatchScalarField); \ 458 makeFvsPatchTypeFieldTypeName(type##FvsPatchVectorField); \ 459 makeFvsPatchTypeFieldTypeName(type##FvsPatchSphericalTensorField); \ 460 makeFvsPatchTypeFieldTypeName(type##FvsPatchSymmTensorField); \ 461 makeFvsPatchTypeFieldTypeName(type##FvsPatchTensorField); 463 #define makeFvsPatchTypeField(PatchTypeField, typePatchTypeField) \ 465 defineNamedTemplateTypeNameAndDebug(typePatchTypeField, 0); \ 467 addToRunTimeSelectionTable \ 469 PatchTypeField, typePatchTypeField, patch \ 472 addToRunTimeSelectionTable \ 475 typePatchTypeField, \ 479 addToRunTimeSelectionTable \ 481 PatchTypeField, typePatchTypeField, dictionary \ 485 #define makeFvsPatchFields(type) \ 487 makeFvsPatchTypeField(fvsPatchScalarField, type##FvsPatchScalarField); \ 488 makeFvsPatchTypeField(fvsPatchVectorField, type##FvsPatchVectorField); \ 489 makeFvsPatchTypeField \ 491 fvsPatchSphericalTensorField, \ 492 type##FvsPatchSphericalTensorField \ 494 makeFvsPatchTypeField(fvsPatchSymmTensorField, type##FvsPatchSymmTensorField); \ 495 makeFvsPatchTypeField(fvsPatchTensorField, type##FvsPatchTensorField); 498 #define makeFvsPatchTypeFieldTypedefs(type) \ 500 typedef type##FvsPatchField<scalar> type##FvsPatchScalarField; \ 501 typedef type##FvsPatchField<vector> type##FvsPatchVectorField; \ 502 typedef type##FvsPatchField<sphericalTensor> \ 503 type##FvsPatchSphericalTensorField; \ 504 typedef type##FvsPatchField<symmTensor> type##FvsPatchSymmTensorField; \ 505 typedef type##FvsPatchField<tensor> type##FvsPatchTensorField; virtual void operator*=(const fvsPatchField< scalar > &)
virtual bool fixesValue() const
True if this patch field fixes a value.
virtual void write(Ostream &) const
Write.
virtual ~fvsPatchField()=default
Destructor.
const DimensionedField< Type, surfaceMesh > & internalField() const noexcept
Return dimensioned internal field reference.
virtual void autoMap(const fvPatchFieldMapper &)
Map (and resize as needed) from self given a mapping object.
A list of keyword definitions, which are a keyword followed by a number of values (eg...
const Field< Type > & primitiveField() const noexcept
Return internal field reference.
static int disallowGenericPatchField
Debug switch to disallow the use of generic fvsPatchField.
virtual void operator==(const fvsPatchField< Type > &)
TypeName("fvsPatchField")
Runtime type information.
A finiteVolume patch using a polyPatch and a fvBoundaryMesh.
const objectRegistry & db() const
The associated objectRegistry.
const fvPatch & patch() const noexcept
Return the patch.
static tmp< fvsPatchField< Type > > NewCalculatedType(const fvPatch &)
Return a pointer to a new calculatedFvsPatchField created on.
DimensionedField< Type, surfaceMesh > Internal
The internal field type associated with the patch field.
calculatedFvsPatchField< Type > Calculated
Type for a calculated patch.
virtual void operator/=(const fvsPatchField< scalar > &)
Generic templated field type.
virtual bool coupled() const
True if this patch field is coupled.
A class for handling words, derived from Foam::string.
void check(const fvsPatchField< Type > &) const
Check fvsPatchField<Type> against given fvsPatchField<Type>
A FieldMapper for finite-volume patch fields.
declareRunTimeSelectionTable(tmp, fvsPatchField, patch,(const fvPatch &p, const DimensionedField< Type, surfaceMesh > &iF),(p, iF))
fvsPatchFieldBase(const fvPatch &p)
Construct from patch.
fvsPatchField(const fvPatch &, const DimensionedField< Type, surfaceMesh > &)
Construct from patch and internal field.
virtual void readDict(const dictionary &dict)
Read dictionary entries.
void checkPatch(const fvsPatchFieldBase &rhs) const
Check that patches are identical.
virtual void operator-=(const fvsPatchField< Type > &)
fvPatch Patch
The patch type for the patch field.
An Ostream is an abstract base class for all output systems (streams, files, token lists...
virtual ~fvsPatchFieldBase()=default
Destructor.
virtual void rmap(const fvsPatchField< Type > &, const labelList &)
Reverse map the given fvsPatchField onto this fvsPatchField.
Template invariant parts for fvsPatchField.
virtual void operator+=(const fvsPatchField< Type > &)
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
virtual void operator=(const UList< Type > &)
Foam::calculatedFvsPatchField.
List< label > labelList
A List of labels.
A class for managing temporary objects.
Registry of regIOobjects.
static const word & calculatedType()
The type name for calculated patch fields.
An abstract base class with a fat-interface to all derived classes covering all possible ways in whic...
virtual tmp< fvsPatchField< Type > > clone() const
Construct and return a clone.
static tmp< fvsPatchField< Type > > New(const word &patchFieldType, const fvPatch &, const DimensionedField< Type, surfaceMesh > &)
Return a pointer to a new patchField created on freestore given.