Go to the documentation of this file.
48 <<
"Discretisation scheme not specified\n\n"
50 << MeshConstructorTablePtr_->sortedToc()
54 const word schemeName(schemeData);
61 auto* ctorPtr = MeshConstructorTable(schemeName);
70 *MeshConstructorTablePtr_
74 return ctorPtr(
mesh, schemeData);
90 <<
"Discretisation scheme not specified"
92 <<
"Valid schemes are :" <<
endl
93 << MeshConstructorTablePtr_->sortedToc()
97 const word schemeName(schemeData);
104 auto* ctorPtr = MeshFluxConstructorTable(schemeName);
113 *MeshFluxConstructorTablePtr_
117 return ctorPtr(
mesh, faceFlux, schemeData);
138 <<
" from cells to faces without explicit correction"
159 "interpolate("+vf.name()+
')',
171 for (label fi=0; fi<P.
size(); fi++)
173 sfi[fi] =
lambda[fi]*vfi[P[fi]] +
y[fi]*vfi[
N[fi]];
206 template<
class SFType>
229 <<
" from cells to faces without explicit correction"
238 const Field<Type>& vfi = vf;
241 const fvMesh&
mesh = vf.mesh();
245 tmp<GeometricField<RetType, fvsPatchField, surfaceMesh>> tsf
247 new GeometricField<RetType, fvsPatchField, surfaceMesh>
251 "interpolate("+vf.name()+
')',
256 Sf.dimensions()*vf.dimensions()
259 GeometricField<RetType, fvsPatchField, surfaceMesh>& sf = tsf.ref();
261 Field<RetType>& sfi = sf.primitiveFieldRef();
263 const typename SFType::Internal& Sfi = Sf();
265 for (label fi=0; fi<P.size(); fi++)
267 sfi[fi] = Sfi[fi] & (
lambda[fi]*(vfi[P[fi]] - vfi[
N[fi]]) + vfi[
N[fi]]);
272 typename GeometricField<RetType, fvsPatchField, surfaceMesh>::
273 Boundary& sfbf = sf.boundaryFieldRef();
278 const typename SFType::Patch& pSf = Sf.boundaryField()[
pi];
279 fvsPatchField<RetType>& psf = sfbf[
pi];
338 <<
" from cells to faces"
352 tsf.ref().oriented() = Sf.oriented();
376 const tmp<GeometricField<Type, fvPatchField, volMesh>>& tvf
390 return tSfDotinterpVf;
407 <<
" from cells to faces"
int debug
Static debugging option.
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
Defines the attributes of an object for which implicit objectRegistry management is supported,...
static tmp< surfaceInterpolationScheme< Type > > New(const fvMesh &mesh, Istream &schemeData)
Return new tmp interpolation scheme.
static tmp< GeometricField< typename innerProduct< typename SFType::value_type, Type >::type, fvsPatchField, surfaceMesh > > dotInterpolate(const SFType &Sf, const GeometricField< Type, fvPatchField, volMesh > &vf, const tmp< surfaceScalarField > &tlambdas)
Return the face-interpolate of the given cell field.
#define InfoInFunction
Report an information message using Foam::Info.
A class for handling words, derived from Foam::string.
void clear() const noexcept
static tmp< GeometricField< typename innerProduct< vector, Type >::type, fvsPatchField, surfaceMesh > > dotInterpolate(const surfaceVectorField &Sf, const GeometricField< Type, fvPatchField, volMesh > &tvf)
Interpolate field onto faces.
A class for managing temporary objects.
static tmp< GeometricField< Type, fvsPatchField, surfaceMesh > > interpolate(const GeometricField< Type, fvPatchField, volMesh > &, const tmp< surfaceScalarField > &, const tmp< surfaceScalarField > &)
Return the face-interpolate of the given cell field.
fvsPatchField< scalar > fvsPatchScalarField
Mesh data needed to do the Finite Volume discretisation.
An abstract base class with a fat-interface to all derived classes covering all possible ways in whic...
A class representing the concept of a GeometricField of 1 used to avoid unnecessary manipulations for...
Ostream & endl(Ostream &os)
Add newline and flush stream.
tmp< fvMatrix< Type > > correction(const fvMatrix< Type > &)
#define forAll(list, i)
Loop across all elements in list.
#define FatalIOErrorInLookup(ios, lookupTag, lookupName, lookupTable)
Report an error message using Foam::FatalIOError.
Generic templated field type.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
bool eof() const noexcept
True if end of input seen.
dimensionedScalar lambda("lambda", dimTime/sqr(dimLength), laminarTransport)
Mesh data needed to do the Finite Volume discretisation.
errorManipArg< error, int > exit(error &err, const int errNo=1)
Internal::FieldType & primitiveFieldRef(const bool updateAccessTime=true)
Return a reference to the internal field.
constexpr scalar pi(M_PI)
GeometricField< scalar, fvsPatchField, surfaceMesh > surfaceScalarField
Internal & ref(const bool updateAccessTime=true)
Return a reference to the dimensioned internal field.
Boundary & boundaryFieldRef(const bool updateAccessTime=true)
Return a reference to the boundary field.
Abstract base class for surface interpolation schemes.
#define FatalIOErrorInFunction(ios)
Report an error message using Foam::FatalIOError.
void size(const label n)
Older name for setAddressableSize.
const Vector< label > N(dict.get< Vector< label >>("N"))
UList< label > labelUList
A UList of labels.
GeometricField< vector, fvsPatchField, surfaceMesh > surfaceVectorField
static tmp< GeometricField< Type, faePatchField, edgeMesh > > interpolate(const GeometricField< Type, faPatchField, areaMesh > &tvf, const edgeScalarField &faceFlux, Istream &schemeData)
Interpolate field onto faces using scheme given by Istream.
typeOfRank< typename pTraits< arg1 >::cmptType, direction(pTraits< arg1 >::rank)+direction(pTraits< arg2 >::rank) - 2 >::type type
const Boundary & boundaryField() const
Return const-reference to the boundary field.