36 template<
class FromPatch,
class ToPatch>
44 if (pf.
size() != fromPatch_.nPoints())
47 <<
"given field does not correspond to patch. Patch size: " 48 << fromPatch_.nPoints() <<
" field size: " << pf.
size()
60 fromPatch_.localFaces();
70 if (addr[pointi] > -1)
73 fromPatchLocalFaces[addr[pointi]];
77 result[pointi] += curWeights[wI]*pf[hitFacePoints[wI]];
86 template<
class FromPatch,
class ToPatch>
100 template<
class FromPatch,
class ToPatch>
108 if (ff.
size() != fromPatch_.size())
111 <<
"given field does not correspond to patch. Patch size: " 112 << fromPatch_.size() <<
" field size: " << ff.
size()
123 const labelListList& fromPatchFaceFaces = fromPatch_.faceFaces();
133 if (addr[facei] > -1)
136 fromPatchFaceFaces[addr[facei]];
139 result[facei] += ff[addr[facei]]*curWeights[0];
141 for (
label wI = 1; wI < curWeights.size(); wI++)
143 result[facei] += ff[hitFaceFaces[wI - 1]]*curWeights[wI];
152 template<
class FromPatch,
class ToPatch>
#define forAll(list, i)
Loop across all elements in list.
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 clear() const
If object pointer points to valid object:
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
T & ref() const
Return non-const reference or generate a fatal error.
void size(const label)
Override size to be inconsistent with allocated storage.
tmp< Field< Type > > pointInterpolate(const Field< Type > &pf) const
Interpolate point field.
Pre-declare SubField and related Field type.
errorManip< error > abort(error &err)
A class for managing temporary objects.
tmp< Field< Type > > faceInterpolate(const Field< Type > &pf) const
Interpolate face field.