56 "snGradCorr("+vf.
name()+
')',
74 const auto& owner =
mesh.owner();
75 const auto& neighbour =
mesh.neighbour();
84 const face& fi = faces[facei];
86 const vector nf(Sf[facei]/magSf[facei]);
97 const Type pvfe(0.5*(pvf[fi[pj]] + pvf[fi[
pi]]));
104 fgrad /= magSf[facei];
107 vector dCorr(
C[neighbour[facei]] -
C[owner[facei]]);
108 dCorr /= (nf & dCorr);
110 sfCorr[facei] = dCorr&fgrad;
113 tsfCorr.
ref().boundaryFieldRef() =
Zero;
135 "snGradCorr("+vf.
name()+
')',
147 for (
direction cmpt = 0; cmpt < pTraits<Type>::nComponents; ++cmpt)
constexpr scalar pi(M_PI)
Graphite solid properties.
const dimensionSet & dimensions() const noexcept
Return dimensions.
Generic templated field type that is much like a Foam::List except that it is expected to hold numeri...
Generic GeometricField class.
void replace(const direction d, const GeometricField< cmptType, PatchField, GeoMesh > &gcf)
Replace specified field component with content from another field.
tmp< GeometricField< cmptType, PatchField, GeoMesh > > component(const direction) const
Return a component of the field.
@ NO_READ
Nothing to be read.
@ NO_WRITE
Ignore writing from objectRegistry::writeObject().
Defines the attributes of an object for which implicit objectRegistry management is supported,...
const word & name() const noexcept
Return the object name.
const fileName & instance() const noexcept
Read access to instance path component.
static FOAM_NO_DANGLING_REFERENCE const volPointInterpolation & New(const fvMesh &mesh, Args &&... args)
void size(const label n)
Older name for setAddressableSize.
label fcIndex(const label i) const noexcept
The forward circular index. The next index in the list which returns to the first at the end of the l...
A face is a list of labels corresponding to mesh vertices.
Mesh data needed to do the Finite Volume discretisation.
Surface gradient scheme with full explicit non-orthogonal correction.
virtual tmp< GeometricField< Type, fvsPatchField, surfaceMesh > > correction(const GeometricField< Type, fvPatchField, volMesh > &) const
Return the explicit correction to the faceCorrectedSnGrad for the given field using the gradients of ...
faceCorrectedSnGrad(const fvMesh &mesh)
Construct from mesh.
tmp< GeometricField< Type, fvsPatchField, surfaceMesh > > fullGradCorrection(const GeometricField< Type, fvPatchField, volMesh > &) const
Return the explicit correction to the faceCorrectedSnGrad for the given field using the gradient of t...
const fvMesh & mesh() const
Return const reference to mesh.
typeOfRank< typenamepTraits< arg1 >::cmptType, direction(pTraits< arg1 >::rank)+direction(pTraits< arg2 >::rank)>::type type
A traits class, which is primarily used for primitives and vector-space.
A class for managing temporary objects.
T & ref() const
Return non-const reference to the contents of a non-null managed pointer.
List< face > faceList
List of faces.
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
Field< vector > vectorField
Specialisation of Field<T> for vector.
static constexpr const zero Zero
Global zero (0).
vectorField pointField
pointField is a vectorField.
#define forAll(list, i)
Loop across all elements in list.