42 patchType_(word::null)
73 patchType_(ptf.patchType_)
84 internalField_(ptf.internalField_),
86 patchType_(ptf.patchType_)
100 patchType_(ptf.patchType_)
109 return patch_.boundaryMesh().mesh()();
118 if (patchType_.size())
121 << token::END_STATEMENT <<
nl;
130 return patchInternalField(primitiveField());
135 template<
class Type1>
144 if (iF.
size() != primitiveField().size())
147 <<
"given internal field does not correspond to the mesh. " 148 <<
"Field size: " << iF.
size()
149 <<
" mesh size: " << primitiveField().size()
158 template<
class Type1>
165 return patchInternalField(iF, patch().meshPoints());
170 template<
class Type1>
178 if (iF.
size() != primitiveField().size())
181 <<
"given internal field does not correspond to the mesh. " 182 <<
"Field size: " << iF.
size()
183 <<
" mesh size: " << primitiveField().size()
187 if (pF.
size() != size())
190 <<
"given patch field does not correspond to the mesh. " 191 <<
"Field size: " << pF.
size()
192 <<
" mesh size: " << size()
201 iF[mp[pointi]] += pF[pointi];
207 template<
class Type1>
216 if (iF.
size() != primitiveField().size())
219 <<
"given internal field does not correspond to the mesh. " 220 <<
"Field size: " << iF.
size()
221 <<
" mesh size: " << primitiveField().size()
225 if (pF.
size() != size())
228 <<
"given patch field does not correspond to the mesh. " 229 <<
"Field size: " << pF.
size()
230 <<
" mesh size: " << size()
239 label pointi = points[i];
240 iF[mp[pointi]] += pF[pointi];
246 template<
class Type1>
255 if (iF.
size() != primitiveField().size())
258 <<
"given internal field does not correspond to the mesh. " 259 <<
"Field size: " << iF.
size()
260 <<
" mesh size: " << primitiveField().size()
267 <<
"given patch field does not correspond to the meshPoints. " 268 <<
"Field size: " << pF.
size()
269 <<
" meshPoints size: " << size()
273 forAll(meshPoints, pointi)
275 iF[meshPoints[pointi]] = pF[pointi];
281 template<
class Type1>
288 setInInternalField(iF, pF, patch().meshPoints());
315 os.check(
"Ostream& operator<<(Ostream&, const pointPatchField<Type>&)");
void addToInternalField(Field< Type1 > &iF, const Field< Type1 > &pF) const
Given the internal field and a patch field,.
#define forAll(list, i)
Loop across all elements in list.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
pointPatchField(const pointPatch &, const DimensionedField< Type, pointMesh > &)
Construct from patch and internal field.
A list of keyword definitions, which are a keyword followed by any number of values (e...
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
commsTypes
Types of communications.
void size(const label)
Override size to be inconsistent with allocated storage.
Foam::pointPatchFieldMapper.
void setInInternalField(Field< Type1 > &iF, const Field< Type1 > &pF, const labelList &meshPoints) const
Given the internal field and a patch field,.
const objectRegistry & db() const
Return local objectRegistry.
Abstract base class for point-mesh patch fields.
Pre-declare SubField and related Field type.
A class for handling words, derived from string.
errorManip< error > abort(error &err)
An Ostream is an abstract base class for all output systems (streams, files, token lists...
Ostream & writeKeyword(const keyType &)
Write the keyword followed by an appropriate indentation.
fileName::Type type(const fileName &)
Return the file type: DIRECTORY or FILE.
Basic pointPatch represents a set of points from the mesh.
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
virtual void write(Ostream &) const
Write.
A class for managing temporary objects.
Registry of regIOobjects.
virtual void evaluate(const Pstream::commsTypes commsType=Pstream::blocking)
Evaluate the patch field.
T lookupOrDefault(const word &, const T &, bool recursive=false, bool patternMatch=true) const
Find and return a T,.
tmp< Field< Type > > patchInternalField() const
Return field created from appropriate internal field values.
const dimensionedScalar mp
Proton mass.