34 template<
class Type,
class CombineOp>
38 const GeometricField<Type, fvsPatchField, surfaceMesh>& ssf,
42 typedef GeometricField<Type, fvPatchField, volMesh> volFieldType;
44 const fvMesh& mesh = ssf.mesh();
46 tmp<volFieldType> tresult
52 "cellReduce(" + ssf.name() +
')',
59 dimensioned<Type>(
"0", ssf.dimensions(),
Zero),
60 extrapolatedCalculatedFvPatchField<Type>::typeName
64 volFieldType& result = tresult.ref();
72 cop(result[celli], ssf[i]);
77 cop(result[celli], ssf[i]);
80 result.correctBoundaryConditions();
86 template<
class Type,
class CombineOp>
90 const tmp<GeometricField<Type, fvsPatchField, surfaceMesh>>& tssf,
94 tmp<GeometricField<Type, fvPatchField, volMesh>> tvf(
cellReduce(tssf, cop));
#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.
Construct a volume field from a surface field using a combine operator.
UList< label > labelUList
tmp< GeometricField< Type, fvPatchField, volMesh > > cellReduce(const GeometricField< Type, fvsPatchField, surfaceMesh > &, const CombineOp &cop)
A class for managing temporary objects.