37 Foam::sampledPatchInternalField::sampleOnFaces
42 const auto& vField = sampler.
psi();
46 auto&
values = tvalues.ref();
52 mappers_[i].map().distribute(interpVals);
74 Foam::sampledPatchInternalField::sampleOnPoints
85 Field<Type> allPatchVals(sz);
91 const mapDistribute& distMap = mappers_[i].map();
99 Field<Type> patchVals(
mesh().nCells());
113 distMap.distribute(patchVals);
117 SubList<Type>(allPatchVals, patchVals.size(), sz) = patchVals;
118 sz += patchVals.size();
124 labelList meshFaceLabels(allPatchVals.size());
131 meshFaceLabels[sz++] =
pp.start()+i;
137 IndirectList<face>(
mesh().faces(), meshFaceLabels),
141 return PrimitivePatchInterpolation<indirectPrimitivePatch>
144 ).faceToPointInterpolate(allPatchVals);
const labelList patchIDs(pbm.indices(polyPatchNames, true))
void size(const label n)
Older name for setAddressableSize.
label max(const labelHashSet &set, label maxValue=labelMin)
Find the max value in labelHashSet, optionally limited by second argument.
scalarField samples(nIntervals, Zero)
const labelList & patchStart() const
The offset into patchIndex, patchFaceLabels.
PrimitivePatch< IndirectList< face >, const pointField & > indirectPrimitivePatch
A PrimitivePatch with an IndirectList for the faces, const reference for the point field...
static autoPtr< sampledSurface > New(const word &name, const polyMesh &mesh, const dictionary &dict)
Return a reference to the selected surface.
const labelList & patchFaceLabels() const
For each face, the patch local face ID.
#define forAll(list, i)
Loop across all elements in list.
List< T > values(const HashTable< T, Key, Hash > &tbl, const bool doSort=false)
List of values from HashTable, optionally sorted.
virtual Type interpolate(const vector &position, const label celli, const label facei=-1) const =0
Interpolate field to the given point in the given cell.
Generic templated field type.
const polyBoundaryMesh & boundaryMesh() const noexcept
Return boundary mesh.
label size() const noexcept
The number of entries in the list.
label size() const
The surface size is the number of faces.
Abstract base class for volume field interpolation.
Field< vector > vectorField
Specialisation of Field<T> for vector.
iterator end() noexcept
Return an iterator to end traversing the UList.
List< label > labelList
A List of labels.
A class for managing temporary objects.
uindirectPrimitivePatch pp(UIndirectList< face >(mesh.faces(), faceLabels), mesh.points())
const GeometricField< Type, fvPatchField, volMesh > & psi() const noexcept
Return the field to be interpolated.