37 template<
class FromPatch,
class ToPatch>
45 if (pf.
size() != fromPatch_.nPoints())
49 "PatchToPatchInterpolation::pointInterpolate" 50 "(const Field<Type> pf)" 51 ) <<
"given field does not correspond to patch. Patch size: " 52 << fromPatch_.nPoints() <<
" field size: " << pf.
size()
68 fromPatch_.localFaces();
78 if (addr[pointI] > -1)
81 fromPatchLocalFaces[addr[pointI]];
85 result[pointI] += curWeights[wI]*pf[hitFacePoints[wI]];
94 template<
class FromPatch,
class ToPatch>
109 template<
class FromPatch,
class ToPatch>
117 if (ff.
size() != fromPatch_.size())
121 "PatchToPatchInterpolation::faceInterpolate" 122 "(const Field<Type> ff)" 123 ) <<
"given field does not correspond to patch. Patch size: " 124 << fromPatch_.size() <<
" field size: " << ff.
size()
139 const labelListList& fromPatchFaceFaces = fromPatch_.faceFaces();
149 if (addr[faceI] > -1)
152 fromPatchFaceFaces[addr[faceI]];
155 result[faceI] += ff[addr[faceI]]*curWeights[0];
157 for (
label wI = 1; wI < curWeights.size(); wI++)
159 result[faceI] += ff[hitFaceFaces[wI - 1]]*curWeights[wI];
168 template<
class FromPatch,
class ToPatch>
void clear() const
If object pointer points to valid object:
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
void size(const label)
Override size to be inconsistent with allocated storage.
tmp< Field< Type > > faceInterpolate(const Field< Type > &pf) const
Interpolate face field.
tmp< Field< Type > > pointInterpolate(const Field< Type > &pf) const
Interpolate point field.
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
Pre-declare SubField and related Field type.
errorManip< error > abort(error &err)
#define FatalErrorIn(functionName)
Report an error message using Foam::FatalError.
Traits class for primitives.
A class for managing temporary objects.