67 #include "surfaceInterpolate.H"
81 public surfaceInterpolationScheme<Type>,
82 public blendedSchemeBase<Type>
135 if (Co1_ < 0 || Co2_ < 0 || Co1_ >= Co2_)
138 <<
"coefficients = " << Co1_ <<
" and " << Co2_
139 <<
" should be > 0 and Co2 > Co1"
166 if (Co1_ < 0 || Co2_ < 0 || Co1_ >= Co2_)
169 <<
"coefficients = " << Co1_ <<
" and " << Co2_
170 <<
" should be > 0 and Co2 > Co1"
195 mesh.objectRegistry::template lookupObject<volScalarField>
203 <<
"dimensions of faceFlux are not correct"
209 vf.
name() +
"BlendingFactor",
229 tmp<surfaceScalarField>
232 const VolField<Type>& vf
238 bf*tScheme1_().weights(vf)
239 + (scalar(1) - bf)*tScheme2_().weights(vf);
254 bf*tScheme1_().interpolate(vf)
255 + (scalar(1) - bf)*tScheme2_().interpolate(vf);
262 return tScheme1_().corrected() || tScheme2_().corrected();
307 return tmp<SurfaceField<Type>>
Two-scheme Courant number based blending interpolation scheme.
virtual bool corrected() const
Return true if this scheme uses an explicit correction.
tmp< SurfaceField< Type > > interpolate(const VolField< Type > &vf) const
Return the face-interpolate of the given cell field.
tmp< surfaceScalarField > weights(const VolField< Type > &vf) const
Return the interpolation weighting factors.
TypeName("CoBlended")
Runtime type information.
virtual tmp< surfaceScalarField > blendingFactor(const VolField< Type > &vf) const
Return the face-based blending factor.
CoBlended(const fvMesh &mesh, Istream &is)
Construct from mesh and Istream.
void operator=(const CoBlended &)=delete
Disallow default bitwise assignment.
virtual tmp< SurfaceField< Type > > correction(const VolField< Type > &vf) const
Return the explicit correction to the face-interpolate.
const dimensionSet & dimensions() const
Return dimensions.
Generic GeometricField class.
static tmp< GeometricField< Type, PatchField, GeoMesh > > New(const word &name, const Internal &, const PtrList< PatchField< Type >> &, const HashPtrTable< Source > &=HashPtrTable< Source >())
Return a temporary field constructed from name,.
const word & name() const
Return name.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
dimensionedScalar deltaT() const
Return time step.
Mesh data needed to do the Finite Volume discretisation.
const Time & time() const
Return the top-level database.
const surfaceScalarField & magSf() const
Return cell face area magnitudes.
Abstract base class for surface interpolation schemes.
const fvMesh & mesh() const
Return mesh reference.
static tmp< surfaceInterpolationScheme< Type > > New(const fvMesh &mesh, Istream &schemeData)
Return new tmp interpolation scheme.
const surfaceScalarField & deltaCoeffs() const
Return reference to cell-centre difference coefficients.
A class for managing temporary objects.
A class for handling words, derived from string.
#define FatalIOErrorInFunction(ios)
Report an error message using Foam::FatalIOError.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
static tmp< SurfaceField< Type > > interpolate(const VolField< Type > &tvf, const surfaceScalarField &faceFlux, Istream &schemeData)
Interpolate field onto faces using scheme given by Istream.
errorManipArg< error, int > exit(error &err, const int errNo=1)
const dimensionSet dimMassFlux
const dimensionSet dimVolumetricFlux
SurfaceField< scalar > surfaceScalarField
layerAndWeight min(const layerAndWeight &a, const layerAndWeight &b)
bool readScalar(const char *buf, doubleScalar &s)
Read whole of buf as a scalar. Return true if successful.
dimensioned< scalar > mag(const dimensioned< Type > &)
layerAndWeight max(const layerAndWeight &a, const layerAndWeight &b)