49 #ifndef Foam_faePatchField_H 50 #define Foam_faePatchField_H 64 class faPatchFieldMapper;
67 template<
class Type>
class faePatchField;
68 template<
class Type>
class calculatedFaePatchField;
71 Ostream& operator<<(Ostream&, const faePatchField<Type>&);
285 (dynamic_cast<const faePatchFieldType&>(ptf),
p, iF, m)
391 template<
class DerivedPatchField,
class... Args>
392 static tmp<faePatchField<Type>>
Clone 394 const DerivedPatchField& pf,
398 return tmp<faePatchField<Type>>
400 new DerivedPatchField(pf, std::forward<Args>(
args)...)
407 static tmp<faePatchField<Type>>
New 409 const word& patchFieldType,
411 const DimensionedField<Type, edgeMesh>&
418 static tmp<faePatchField<Type>>
New 420 const word& patchFieldType,
421 const word& actualPatchType,
423 const DimensionedField<Type, edgeMesh>&
428 static tmp<faePatchField<Type>>
New 430 const faePatchField<Type>&,
432 const DimensionedField<Type, edgeMesh>&,
433 const faPatchFieldMapper&
438 static tmp<faePatchField<Type>>
New 454 template<
class AnyType>
468 return internalField_;
474 return internalField_;
503 const faPatchFieldMapper&
509 const faePatchField<Type>&,
534 virtual void write(Ostream&
os)
const;
537 void check(
const faePatchField<Type>&)
const;
542 virtual void operator=(
const UList<Type>&);
544 virtual void operator=(
const faePatchField<Type>&);
545 virtual void operator+=(
const faePatchField<Type>&);
546 virtual void operator-=(
const faePatchField<Type>&);
547 virtual void operator*=(
const faePatchField<scalar>&);
548 virtual void operator/=(
const faePatchField<scalar>&);
553 virtual void operator*=(
const Field<scalar>&);
554 virtual void operator/=(
const Field<scalar>&);
565 virtual void operator==(
const faePatchField<Type>&);
virtual bool coupled() const
True if the patch field is coupled.
virtual void initEvaluateLocal(const Pstream::commsTypes commsType=Pstream::commsTypes::buffered)
Initialise the evaluation of the patch field after a local.
void setUpdated(bool state) noexcept
Set updated state. This is a no-op for faePatchField.
virtual void readDict(const dictionary &dict)
Read dictionary entries.
virtual void write(Ostream &os) const
Write.
static const word & emptyType() noexcept
The type name for empty patch fields.
static const word & calculatedType() noexcept
The type name for calculated patch fields.
commsTypes
Communications types.
A list of keyword definitions, which are a keyword followed by a number of values (eg...
Template invariant parts for faePatchField.
virtual void autoMap(const faPatchFieldMapper &)
Map (and resize as needed) from self given a mapping object.
bool updated() const noexcept
True if the boundary condition has already been updated. This is always true for faePatchField.
void writeEntry(const word &keyword, Ostream &os) const
Write the field as a dictionary entry.
bool readValueEntry(const dictionary &dict, IOobjectOption::readOption readOpt=IOobjectOption::LAZY_READ)
Read the "value" entry into *this.
virtual void evaluate(const Pstream::commsTypes commsType=Pstream::commsTypes::buffered)
Evaluate the patch field, generally a no-op.
virtual ~faePatchField()=default
Destructor.
const DimensionedField< Type, edgeMesh > & internalField() const noexcept
Return const-reference to the dimensioned internal field.
static tmp< faePatchField< Type > > Clone(const DerivedPatchField &pf, Args &&... args)
Clone a patch field, optionally with internal field reference etc.
const word calculatedType
A calculated patch field type.
declareRunTimeSelectionTable(tmp, faePatchField, patch,(const faPatch &p, const DimensionedField< Type, edgeMesh > &iF),(p, iF))
faPatch Patch
The patch type for the patch field.
Generic templated field type.
DimensionedField< Type, edgeMesh > Internal
The internal field type associated with the patch field.
A class for handling words, derived from Foam::string.
virtual void operator*=(const faePatchField< scalar > &)
bool manipulatedMatrix() const noexcept
True if the matrix has already been manipulated. Currently ignored (always false) for faePatchField...
virtual void evaluateLocal(const Pstream::commsTypes commsType=Pstream::commsTypes::buffered)
Evaluate the patch field after a local operation (e.g. *=)
virtual tmp< faePatchField< Type > > clone() const
Clone patch field with its own internal field reference.
const objectRegistry & db() const
The associated objectRegistry.
static tmp< faePatchField< Type > > NewCalculatedType(const faPatch &p)
Return a pointer to a new calculatedFaePatchField created on.
Macros for creating faePatchField types.
const faPatch & patch() const noexcept
Return the patch.
faePatchFieldBase(const faPatch &p)
Construct from patch.
bool operator!=(const faePatchField< Type > &) const =delete
An Ostream is an abstract base class for all output systems (streams, files, token lists...
virtual void rmap(const faePatchField< Type > &, const labelList &)
Reverse map the given faePatchField onto this faePatchField.
const word emptyType
An empty patch field type.
OBJstream os(runTime.globalPath()/outputName)
virtual void initEvaluate(const Pstream::commsTypes commsType=Pstream::commsTypes::buffered)
Initialise the evaluation of the patch field, generally a no-op.
Finite area patch class. Used for 2-D non-Euclidian finite area method.
void setManipulated(bool state) noexcept
Set matrix manipulated state. This is a no-op for faePatchField.
virtual ~faePatchFieldBase()=default
Destructor.
virtual void operator=(const UList< Type > &)
void check(const faePatchField< Type > &) const
Check against given patch field.
calculatedFaePatchField< Type > Calculated
Type for a calculated patch.
virtual void operator/=(const faePatchField< scalar > &)
TypeName("faePatchField")
Runtime type information.
virtual void operator==(const faePatchField< Type > &)
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
void writeValueEntry(Ostream &os) const
Write *this field as a "value" entry.
faePatchField(const faPatch &, const DimensionedField< Type, edgeMesh > &)
Construct from patch and internal field.
static tmp< faePatchField< Type > > New(const word &patchFieldType, const faPatch &, const DimensionedField< Type, edgeMesh > &)
Return a pointer to a new patchField created on freestore given.
Reading is optional [identical to READ_IF_PRESENT].
faePatchField<Type> abstract base class. This class gives a fat-interface to all derived classes cove...
virtual void operator+=(const faePatchField< Type > &)
Type value_type
The value_type for the patch field.
List< label > labelList
A List of labels.
A class for managing temporary objects.
Registry of regIOobjects.
"buffered" : (MPI_Bsend, MPI_Recv)
static int disallowGenericPatchField
Debug switch to disallow the use of generic faePatchField.
Foam::argList args(argc, argv)
A FieldMapper for finite-area patch fields.
void checkPatch(const faePatchFieldBase &rhs) const
Check that patches are identical.
virtual void operator-=(const faePatchField< Type > &)
virtual bool fixesValue() const
True if the patch field fixes a value.
const Field< Type > & primitiveField() const noexcept
Return const-reference to the internal field values.
Author Zeljko Tukovic, FMENA Hrvoje Jasak, Wikki Ltd.
readOption
Enumeration defining read preferences.