41#ifndef Foam_PatchToPatchInterpolation_H
42#define Foam_PatchToPatchInterpolation_H
113template<
class FromPatch,
class ToPatch>
114class PatchToPatchInterpolation
116 public PatchToPatchInterpolationBase
121 const FromPatch& fromPatch_;
124 const ToPatch& toPatch_;
136 mutable std::unique_ptr<labelList> pointAddressingPtr_;
139 mutable std::unique_ptr<FieldField<Field, scalar>> pointWeightsPtr_;
142 mutable std::unique_ptr<scalarField> pointDistancePtr_;
148 mutable std::unique_ptr<labelList> faceAddressingPtr_;
151 mutable std::unique_ptr<FieldField<Field, scalar>> faceWeightsPtr_;
154 mutable std::unique_ptr<scalarField> faceDistancePtr_;
160 PatchToPatchInterpolation(
const PatchToPatchInterpolation&) =
delete;
163 void operator=(
const PatchToPatchInterpolation&) =
delete;
166 void calcPointAddressing()
const;
169 void calcFaceAddressing()
const;
193 PatchToPatchInterpolation
195 const FromPatch& fromPatch,
196 const ToPatch& toPatch,
A field of fields is a PtrList of fields with reference counting.
Generic templated field type that is much like a Foam::List except that it is expected to hold numeri...
static scalar projectionTol() noexcept
Access to projection tolerance.
static const scalar directHitTol
Direct hit tolerance.
static scalar projectionTol_
Relative merge tolerance for projected points missing the target.
static scalar setProjectionTol(const scalar tol)
Change propagation tolerance, return previous value.
ClassName("PatchToPatchInterpolation")
Runtime type information.
PatchToPatchInterpolationBase() noexcept=default
Default construct.
bool movePoints()
Correct weighting factors for moving mesh.
intersection::direction projectionDir() const
Return direction projection to use in projection.
intersection::algorithm projectionAlgo() const
Return ype of intersection algorithm to use in projection.
const scalarField & pointDistanceToIntersection() const
Return distance to intersection for patch points.
const scalarField & faceDistanceToIntersection() const
Return distance to intersection for patch face centres.
PatchToPatchInterpolation(const FromPatch &fromPatch, const ToPatch &toPatch, const intersection::algorithm alg=intersection::FULL_RAY, const intersection::direction dir=intersection::VECTOR)
Construct from components.
tmp< Field< Type > > faceInterpolate(const tmp< Field< Type > > &tpf) const
tmp< Field< Type > > pointInterpolate(const Field< Type > &pf) const
Interpolate point field.
tmp< Field< Type > > faceInterpolate(const Field< Type > &pf) const
Interpolate face field.
~PatchToPatchInterpolation()
Destructor.
tmp< Field< Type > > pointInterpolate(const tmp< Field< Type > > &tpf) const
A class for managing temporary objects.
Macro definitions for declaring ClassName(), NamespaceName(), etc.
#define ClassName(TypeNameString)
Add typeName information from argument TypeNameString to a class.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
List< label > labelList
A List of labels.
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
errorManip< error > abort(error &err)
error FatalError
Error stream (stdout output on all processes), with additional 'FOAM FATAL ERROR' header text and sta...