78 patchType_(ptf.patchType_)
89 internalField_(ptf.internalField_),
91 patchType_(ptf.patchType_)
105 patchType_(ptf.patchType_)
114 return patch_.boundaryMesh().mesh()();
123 if (!patchType_.empty())
134 return patchInternalField(primitiveField());
148 if (iF.
size() != primitiveField().size())
151 <<
"given internal field does not correspond to the mesh. "
152 <<
"Field size: " << iF.
size()
153 <<
" mesh size: " << primitiveField().size()
169 return patchInternalField(iF, patch().meshPoints());
182 if (iF.
size() != primitiveField().size())
185 <<
"given internal field does not correspond to the mesh. "
187 <<
" mesh size: " << primitiveField().size()
191 if (pF.
size() != size())
194 <<
"given patch field does not correspond to the mesh. "
195 <<
"Field size: " << pF.
size()
196 <<
" mesh size: " << size()
201 const labelList& mp = patch().meshPoints();
205 iF[mp[pointi]] += pF[pointi];
220 if (iF.
size() != primitiveField().size())
223 <<
"given internal field does not correspond to the mesh. "
224 <<
"Field size: " << iF.
size()
225 <<
" mesh size: " << primitiveField().size()
229 if (pF.
size() != size())
232 <<
"given patch field does not correspond to the mesh. "
233 <<
"Field size: " << pF.
size()
234 <<
" mesh size: " << size()
239 const labelList& mp = patch().meshPoints();
244 iF[mp[pointi]] += pF[pointi];
259 if (iF.
size() != primitiveField().size())
262 <<
"given internal field does not correspond to the mesh. "
263 <<
"Field size: " << iF.
size()
264 <<
" mesh size: " << primitiveField().size()
271 <<
"given patch field does not correspond to the meshPoints. "
272 <<
"Field size: " << pF.
size()
273 <<
" meshPoints size: " << size()
277 forAll(meshPoints, pointi)
279 iF[meshPoints[pointi]] = pF[pointi];
292 setInInternalField(iF, pF, patch().meshPoints());
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
Generic templated field type.
void evaluate()
Evaluate boundary conditions.
virtual bool check(const char *operation) const
Check IOstream status for given operation.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
Ostream & writeEntry(const keyType &key, const T &value)
Write a keyword/value entry.
virtual bool write(const token &tok)=0
Write token to stream or otherwise handle it.
void size(const label n)
Older name for setAddressableSize.
commsTypes
Types of communications.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
bool readIfPresent(const word &keyword, T &val, enum keyType::option matchOpt=keyType::REGEX) const
virtual bool write()
Write the output fields.
Registry of regIOobjects.
Foam::pointPatchFieldMapper.
Abstract base class for point-mesh patch fields.
tmp< Field< Type > > patchInternalField() const
Return field created from appropriate internal field values.
const objectRegistry & db() const
Return local objectRegistry.
void addToInternalField(Field< Type1 > &iF, const Field< Type1 > &pF) const
Given the internal field and a patch field,.
void setInInternalField(Field< Type1 > &iF, const Field< Type1 > &pF, const labelList &meshPoints) const
Given the internal field and a patch field,.
Basic pointPatch represents a set of points from the mesh.
A class for managing temporary objects.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
OBJstream os(runTime.globalPath()/outputName)
fileName::Type type(const fileName &name, const bool followLink=true)
Return the file type: DIRECTORY or FILE, normally following symbolic links.
errorManip< error > abort(error &err)
tmp< DimensionedField< TypeR, GeoMesh > > New(const tmp< DimensionedField< TypeR, GeoMesh > > &tdf1, const word &name, const dimensionSet &dimensions)
Global function forwards to reuseTmpDimensionedField::New.
#define forAll(list, i)
Loop across all elements in list.