36 typename Foam::outerProduct<Foam::vector, Type>::type,
43 const GeometricField<Type, fvsPatchField, surfaceMesh>& ssf,
49 const fvMesh& mesh = ssf.mesh();
51 tmp<GeometricField<GradType, fvPatchField, volMesh>> tgGrad
63 extrapolatedCalculatedFvPatchField<GradType>::typeName
66 GeometricField<GradType, fvPatchField, volMesh>& gGrad = tgGrad.ref();
69 const labelUList& neighbour = mesh.neighbour();
72 Field<GradType>& igGrad = gGrad;
73 const Field<Type>& issf = ssf;
77 GradType Sfssf = Sf[facei]*issf[facei];
79 igGrad[owner[facei]] += Sfssf;
80 igGrad[neighbour[facei]] -= Sfssf;
86 mesh.boundary()[
patchi].faceCells();
90 const fvsPatchField<Type>& pssf = ssf.boundaryField()[
patchi];
94 igGrad[pFaceCells[facei]] += pSf[facei]*pssf[facei];
100 gGrad.correctBoundaryConditions();
111 typename Foam::outerProduct<Foam::vector, Type>::type,
118 const GeometricField<Type, fvPatchField, volMesh>& vsf,
124 tmp<GeometricField<GradType, fvPatchField, volMesh>> tgGrad
128 GeometricField<GradType, fvPatchField, volMesh>& gGrad = tgGrad.ref();
149 >::Boundary& gGradbf = gGrad.boundaryFieldRef();
#define forAll(list, i)
Loop across all elements in list.
rDeltaT correctBoundaryConditions()
const Boundary & boundaryField() const
Return const-reference to the boundary field.
static tmp< GeometricField< typename outerProduct< vector, Type >::type, fvPatchField, volMesh > > gradf(const GeometricField< Type, fvsPatchField, surfaceMesh > &, const word &name)
Return the gradient of the given field.
Abstract base class with a fat-interface to all derived classes covering all possible ways in which t...
volVectorField vectorField(fieldObject, mesh)
typeOfRank< typename pTraits< arg1 >::cmptType, direction(pTraits< arg1 >::rank)+direction(pTraits< arg2 >::rank) >::type type
Generic GeometricField class.
UList< label > labelUList
virtual tmp< GeometricField< typename outerProduct< vector, Type >::type, fvPatchField, volMesh > > calcGrad(const GeometricField< Type, fvPatchField, volMesh > &vsf, const word &name) const
Return the gradient of the given field to the gradScheme::grad.
Mesh data needed to do the Finite Volume discretisation.
autoPtr< BasicCompressibleMomentumTransportModel > New(const volScalarField &rho, const volVectorField &U, const surfaceScalarField &phi, const typename BasicCompressibleMomentumTransportModel::transportModel &transport)
static void correctBoundaryConditions(const GeometricField< Type, fvPatchField, volMesh > &, GeometricField< typename outerProduct< vector, Type >::type, fvPatchField, volMesh > &)
Correct the boundary values of the gradient using the patchField.
const Mesh & mesh() const
Return mesh.
static tmp< GeometricField< Type, fvsPatchField, surfaceMesh > > interpolate(const GeometricField< Type, fvPatchField, volMesh > &tvf, const surfaceScalarField &faceFlux, Istream &schemeData)
Interpolate field onto faces using scheme given by Istream.
const dimensionSet dimLength(0, 1, 0, 0, 0, 0, 0)
fileType type(const fileName &, const bool checkVariants=true, const bool followLink=true)
Return the file type: directory or file.
A class for managing temporary objects.