32 #ifndef CentredFitSnGradScheme_H 33 #define CentredFitSnGradScheme_H 53 template<
class Type,
class Polynomial,
class Stencil>
63 const scalar linearLimitFactor_;
66 const scalar centralWeight_;
159 #define makeCentredFitSnGradTypeScheme(SS, POLYNOMIAL, STENCIL, TYPE) \ 160 typedef Foam::fv::CentredFitSnGradScheme \ 161 <Foam::TYPE, Foam::POLYNOMIAL, Foam::STENCIL> \ 162 CentredFitSnGradScheme##TYPE##POLYNOMIAL##STENCIL##_; \ 164 defineTemplateTypeNameAndDebugWithName \ 165 (CentredFitSnGradScheme##TYPE##POLYNOMIAL##STENCIL##_, #SS, 0); \ 171 snGradScheme<TYPE>::addMeshConstructorToTable \ 172 <CentredFitSnGradScheme<TYPE, POLYNOMIAL, STENCIL>> \ 173 add##SS##STENCIL##TYPE##MeshConstructorToTable_; \ 177 #define makeCentredFitSnGradScheme(SS, POLYNOMIAL, STENCIL) \ 179 makeCentredFitSnGradTypeScheme(SS,POLYNOMIAL,STENCIL,scalar) \ 180 makeCentredFitSnGradTypeScheme(SS,POLYNOMIAL,STENCIL,vector) \ 181 makeCentredFitSnGradTypeScheme(SS,POLYNOMIAL,STENCIL,sphericalTensor) \ 182 makeCentredFitSnGradTypeScheme(SS,POLYNOMIAL,STENCIL,symmTensor) \ 183 makeCentredFitSnGradTypeScheme(SS,POLYNOMIAL,STENCIL,tensor) autoPtr< CompressibleMomentumTransportModel > New(const volScalarField &rho, const volVectorField &U, const surfaceScalarField &phi, const viscosity &viscosity)
const List< scalarList > & coeffs() const
Return reference to fit coefficients.
TypeName("CentredFitSnGradScheme")
Runtime type information.
T & ref() const
Return non-const reference or generate a fatal error.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)...
Generic GeometricField class.
const dimensionSet dimLength
tmp< GeometricField< Type, fvsPatchField, surfaceMesh > > weightedSum(const GeometricField< Type, fvPatchField, volMesh > &fld, const List< List< scalar >> &stencilWeights) const
Sum vol field contributions to create face values.
virtual tmp< surfaceScalarField > deltaCoeffs(const GeometricField< Type, fvPatchField, volMesh > &) const
Return the interpolation weighting factors for the given field.
const surfaceScalarField & nonOrthDeltaCoeffs() const
Return reference to non-orthogonal cell-centre difference.
bool readScalar(const char *buf, doubleScalar &s)
Read whole of buf as a scalar. Return true if successful.
virtual bool corrected() const
Return true if this scheme uses an explicit correction.
virtual tmp< GeometricField< Type, fvsPatchField, surfaceMesh > > correction(const GeometricField< Type, fvPatchField, volMesh > &vf) const
Return the explicit correction to the face-interpolate.
static CentredFitSnGradData< Polynomial > & New(fvMesh &mesh)
Centred fit snGrad scheme which applies an explicit correction to snGrad.
Abstract base class for snGrad schemes.
const fvMesh & mesh() const
Return mesh reference.
Mesh data needed to do the Finite Volume discretisation.
Data for centred fit snGrad schemes.
A class for managing temporary objects.