45 manipulatedMatrix_(
false),
46 patchType_(word::null)
62 manipulatedMatrix_(
false),
79 manipulatedMatrix_(
false),
80 patchType_(word::null)
97 manipulatedMatrix_(
false),
98 patchType_(ptf.patchType_)
105 this->map(ptf, mapper);
115 const bool valueRequired
122 manipulatedMatrix_(
false),
125 if (dict.
found(
"value"))
132 else if (!valueRequired)
140 "fvPatchField<Type>::fvPatchField" 143 "const DimensionedField<Type, volMesh>& iF," 144 "const dictionary& dict," 145 "const bool valueRequired" 148 ) <<
"Essential entry 'value' missing" 162 internalField_(ptf.internalField_),
164 manipulatedMatrix_(
false),
165 patchType_(ptf.patchType_)
180 manipulatedMatrix_(
false),
181 patchType_(ptf.patchType_)
190 return patch_.boundaryMesh().mesh();
197 if (&patch_ != &(ptf.patch_))
199 FatalErrorIn(
"PatchField<Type>::check(const fvPatchField<Type>&)")
200 <<
"different patches for fvPatchField<Type>s" 209 return patch_.deltaCoeffs()*(*
this - patchInternalField());
217 return patch_.patchInternalField(internalField_);
224 patch_.patchInternalField(internalField_, pif);
241 f = this->patchInternalField();
263 if (mapAddressing[i] < 0)
277 const labelList& localAddrs = mapAddressing[i];
279 if (!localAddrs.
size())
331 manipulatedMatrix_ =
false;
338 manipulatedMatrix_ =
true;
349 manipulatedMatrix_ =
true;
358 if (patchType_.size())
361 << token::END_STATEMENT <<
nl;
367 template<
class EntryType>
371 const word& entryName,
372 const EntryType& value1,
373 const EntryType& value2
376 if (value1 != value2)
378 os.
writeKeyword(entryName) << value2 << token::END_STATEMENT <<
nl;
386 void Foam::fvPatchField<Type>::operator=
396 void Foam::fvPatchField<Type>::operator=
407 void Foam::fvPatchField<Type>::operator+=
418 void Foam::fvPatchField<Type>::operator-=
429 void Foam::fvPatchField<Type>::operator*=
434 if (&patch_ != &ptf.
patch())
438 "PatchField<Type>::operator*=(const fvPatchField<scalar>& ptf)" 439 ) <<
"incompatible patches for patch fields" 448 void Foam::fvPatchField<Type>::operator/=
453 if (&patch_ != &ptf.
patch())
457 "PatchField<Type>::operator/=(const fvPatchField<scalar>& ptf)" 458 ) <<
" incompatible patches for patch fields" 467 void Foam::fvPatchField<Type>::operator+=
477 void Foam::fvPatchField<Type>::operator-=
487 void Foam::fvPatchField<Type>::operator*=
497 void Foam::fvPatchField<Type>::operator/=
507 void Foam::fvPatchField<Type>::operator=
517 void Foam::fvPatchField<Type>::operator+=
527 void Foam::fvPatchField<Type>::operator-=
537 void Foam::fvPatchField<Type>::operator*=
547 void Foam::fvPatchField<Type>::operator/=
558 void Foam::fvPatchField<Type>::operator==
568 void Foam::fvPatchField<Type>::operator==
578 void Foam::fvPatchField<Type>::operator==
590 Foam::Ostream& Foam::operator<<(Ostream& os, const fvPatchField<Type>& ptf)
594 os.
check(
"Ostream& operator<<(Ostream&, const fvPatchField<Type>&");
bool found(const word &, bool recursive=false, bool patternMatch=true) const
Search dictionary for given keyword.
virtual void manipulateMatrix(fvMatrix< Type > &matrix)
Manipulate matrix.
virtual tmp< Field< Type > > snGrad() const
Return patch-normal gradient.
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
gmvFile<< "tracers "<< particles.size()<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){gmvFile<< iter().position().x()<< " ";}gmvFile<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){gmvFile<< iter().position().y()<< " ";}gmvFile<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){gmvFile<< iter().position().z()<< " ";}gmvFile<< nl;forAll(lagrangianScalarNames, i){word name=lagrangianScalarNames[i];IOField< scalar > s(IOobject( name, runTime.timeName(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE ))
virtual void updateCoeffs()
Update the coefficients associated with the patch field.
void writeEntryIfDifferent(Ostream &os, const word &entryName, const EntryType &value1, const EntryType &value2) const
Helper function to write the keyword and entry only if the.
A class for handling words, derived from string.
void size(const label)
Override size to be inconsistent with allocated storage.
errorManipArg< error, int > exit(error &err, const int errNo=1)
Foam::fvPatchFieldMapper.
A special matrix type and solver, designed for finite volume solutions of scalar equations. Face addressing is used to make all matrix assembly and solution loops vectorise.
bool notNull(const T &t)
Return true if t is not a reference to the nullObject of type T.
A list of keyword definitions, which are a keyword followed by any number of values (e...
virtual void write(Ostream &) const
Write.
virtual bool check(const char *operation) const
Check IOstream status for given operation.
void setSize(const label)
Reset size of List.
virtual void rmap(const fvPatchField< Type > &, const labelList &)
Reverse map the given fvPatchField onto this fvPatchField.
virtual tmp< Field< Type > > patchInternalField() const
Return internal field next to patch as patch field.
commsTypes
Types of communications.
label size() const
Return the number of elements in the UList.
Abstract base class with a fat-interface to all derived classes covering all possible ways in which t...
Pre-declare SubField and related Field type.
errorManip< error > abort(error &err)
virtual void evaluate(const Pstream::commsTypes commsType=Pstream::blocking)
Evaluate the patch field, sets Updated to false.
fileName::Type type(const fileName &)
Return the file type: DIRECTORY or FILE.
Ostream & writeKeyword(const keyType &)
Write the keyword followed by an appropriate indentation.
gmvFile<< "tracers "<< particles.size()<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){gmvFile<< iter().position().x()<< ' ';}gmvFile<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){gmvFile<< iter().position().y()<< ' ';}gmvFile<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){gmvFile<< iter().position().z()<< ' ';}gmvFile<< nl;forAll(lagrangianScalarNames, i){const word &name=lagrangianScalarNames[i];IOField< scalar > fld(IOobject( name, runTime.timeName(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE ))
virtual label size() const =0
virtual const labelUList & directAddressing() const
#define FatalErrorIn(functionName)
Report an error message using Foam::FatalError.
virtual void autoMap(const fvPatchFieldMapper &)
Map (and resize as needed) from self given a mapping object.
void check(const fvPatchField< Type > &) const
Check fvPatchField<Type> against given fvPatchField<Type>
Traits class for primitives.
T lookupOrDefault(const word &, const T &, bool recursive=false, bool patternMatch=true) const
Find and return a T,.
Registry of regIOobjects.
const objectRegistry & db() const
Return local objectRegistry.
virtual const labelListList & addressing() const
fvPatchField(const fvPatch &, const DimensionedField< Type, volMesh > &)
Construct from patch and internal field.
An Ostream is an abstract base class for all output systems (streams, files, token lists...
virtual bool direct() const =0
A finiteVolume patch using a polyPatch and a fvBoundaryMesh.
virtual label size() const
Return size.
const fvPatch & patch() const
Return patch.
#define FatalIOErrorIn(functionName, ios)
Report an error message using Foam::FatalIOError.
A class for managing temporary objects.