35 Foam::sampledMeshedSurface::sampleOnFaces
49 const labelList& elements = sampleElements_;
72 auto&
values = tvalues.ref();
80 const auto& bField = sampler.
psi().boundaryField();
86 const auto& pfld = bField[patchi];
102 values[i] = bVals[bFacei];
112 Foam::sampledMeshedSurface::sampleOnPoints
119 defaultValues_.getOrDefault<Type>
121 interpolator.
psi().name(),
126 const labelList& elements = sampleElements_;
131 auto tvalues = tmp<Field<Type>>
::New(elements.size());
132 auto&
values = tvalues.ref();
140 const label celli = elements[i];
166 const label facei = elements[i];
177 mesh().faceOwner()[facei],
const polyBoundaryMesh & pbm
void size(const label n)
Older name for setAddressableSize.
const polyMesh & mesh() const noexcept
Access to the underlying mesh.
virtual const pointField & points() const
Points of surface.
tmp< DimensionedField< TypeR, GeoMesh > > New(const tmp< DimensionedField< TypeR, GeoMesh >> &tf1, const word &name, const dimensionSet &dimensions, const bool initCopy=false)
Global function forwards to reuseTmpDimensionedField::New.
static autoPtr< sampledSurface > New(const word &name, const polyMesh &mesh, const dictionary &dict)
Return a reference to the selected surface.
#define forAll(list, i)
Loop across all elements in list.
static tmp< Field< Type > > sampleOnFaces(const interpolation< Type > &sampler, const labelUList &elements, const faceList &fcs, const pointField &pts, const Type &defaultValue=Type(Zero))
Loop for sampling volume elements to faces.
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.
virtual const faceList & faces() const
Faces of surface.
Generic templated field type.
const polyBoundaryMesh & boundaryMesh() const noexcept
Return boundary mesh.
label nInternalFaces() const noexcept
Number of internal faces.
A polyBoundaryMesh is a polyPatch list with additional search methods and registered IO...
Abstract base class for volume field interpolation.
A class representing the concept of 0 (zero) that can be used to avoid manipulating objects known to ...
bool onBoundary() const
Sampling boundary values instead of cell values.
T getOrDefault(const word &keyword, const T &deflt, enum keyType::option matchOpt=keyType::REGEX) const
Find and return a T, or return the given default value. FatalIOError if it is found and the number of...
List< label > labelList
A List of labels.
A class for managing temporary objects.
const GeometricField< Type, fvPatchField, volMesh > & psi() const noexcept
Return the field to be interpolated.