Go to the documentation of this file.
45 const VolFieldType&
fld = *(iter.val());
54 <<
" a field named " << sampleFldName
55 <<
" already exists on the mesh"
60 label sz = sflds.size();
82 Log <<
" created " << sflds[sz].name()
83 <<
" to sample " <<
fld.name() <<
endl;
93 const interpolationCellPoint<Type>& interpolator,
94 GeometricField<Type, fvPatchField, volMesh>&
fld
98 Field<Type> sampledValues(getPatchDataMapPtr_().constructSize());
100 forAll(cellToWalls_, celli)
102 const labelList& cData = cellToWalls_[celli];
106 const point& samplePt = cellToSamples_[celli][i];
107 sampledValues[cData[i]] = interpolator.interpolate(samplePt, celli);
112 getPatchDataMapPtr_().reverseDistribute
114 getPatchDataMapPtr_().constructSize(),
118 typename GeometricField<Type, fvPatchField, volMesh>::
119 Boundary& fldBf =
fld.boundaryFieldRef();
122 label nPatchFaces = 0;
123 for (
const label patchi : patchSet_)
125 fvPatchField<Type>& pfld = fldBf[patchi];
127 Field<Type> newFld(pfld.size());
130 newFld[i] = sampledValues[nPatchFaces++];
148 const word& fldName = reverseFieldMap_[sflds[i].name()];
149 const VolFieldType&
fld = obr_.lookupObject<VolFieldType>(fldName);
158 sampleBoundaryField(interpolator, sflds[i]);
List< label > labelList
A List of labels.
Defines the attributes of an object for which implicit objectRegistry management is supported,...
const objectRegistry & obr_
A class for handling words, derived from Foam::string.
Ostream & endl(Ostream &os)
writeOption writeOpt() const noexcept
HashTable< const Type * > lookupClass(const bool strict=false) const
Given cell centre values and point (vertex) values decompose into tetrahedra and linear interpolate w...
void sampleBoundaryField(const interpolationCellPoint< Type > &interpolator, GeometricField< Type, fvPatchField, volMesh > &fld) const
A list of pointers to objects of type <T>, with allocation/deallocation management of the pointers....
gmvFile<< "tracers "<< particles.size()<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().x()<< ' ';}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().y()<< ' ';}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().z()<< ' ';}gmvFile<< nl;for(const word &name :lagrangianScalarNames){ IOField< scalar > fld(IOobject(name, runTime.timeName(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE))
bool found(const word &name, const bool recursive=false) const
Type interpolate(const cellPointWeight &cpw) const
This boundary condition is not designed to be evaluated; it is assmued that the value is assigned via...
virtual void rename(const word &newName)
void sampleFields(PtrList< GeometricField< Type, fvPatchField, volMesh >> &) const
readOption readOpt() const noexcept
A HashTable similar to std::unordered_map.
void createFields(PtrList< GeometricField< Type, fvPatchField, volMesh >> &) const
HashTable< word > fieldMap_
forAllConstIters(mixture.phases(), phase)
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
vector point
Point is a vector.
Generic GeometricField class.
#define WarningInFunction