47 mesh_.pointsInstance(),
61 mesh_.pointsInstance(),
71 calcLeastSquaresVectors();
83 void Foam::leastSquaresVectors::calcLeastSquaresVectors()
87 Info<<
"leastSquaresVectors::calcLeastSquaresVectors() :" 88 <<
"Calculating least square gradient vectors" 105 label own = owner[facei];
106 label nei = neighbour[facei];
108 vector d = C[nei] - C[own];
115 surfaceVectorField::GeometricBoundaryField& blsP =
130 const vector& d = pd[patchFacei];
132 dd[faceCells[patchFacei]] +=
sqr(d)/
magSqr(d);
144 label own = owner[facei];
145 label nei = neighbour[facei];
147 vector d = C[nei] - C[own];
149 pVectors_[facei] = (invDd[own] & d)/
magSqr(d);
150 nVectors_[facei] = -(invDd[nei] & d)/
magSqr(d);
165 const vector& d = pd[patchFacei];
167 patchLsP[patchFacei] = (invDd[faceCells[patchFacei]] & d)/
magSqr(d);
173 Info<<
"leastSquaresVectors::calcLeastSquaresVectors() :" 174 <<
"Finished calculating least square gradient vectors" 182 calcLeastSquaresVectors();
Mesh data needed to do the Finite Volume discretisation.
GeometricBoundaryField & boundaryField()
Return reference to GeometricBoundaryField.
const fvPatch & patch() const
Return patch.
leastSquaresVectors(const fvMesh &)
Construct given an fvMesh.
Templated 3D symmetric tensor derived from VectorSpace adding construction from 6 components...
dimensioned< scalar > magSqr(const dimensioned< Type > &)
virtual tmp< vectorField > delta() const
Return cell-centre to face-centre vector.
virtual ~leastSquaresVectors()
Destructor.
const labelUList & faceCells() const
Return face-cell addressing.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
const labelUList & owner() const
Internal face owner.
Graphite solid properties.
virtual const labelUList & faceCells() const
Return faceCells.
static const SymmTensor zero
const dimensionSet dimLength(0, 1, 0, 0, 0, 0, 0)
const fvMesh & mesh() const
const polyPatch & patch() const
Return the polyPatch.
Least-squares gradient scheme vectors.
dimensionedSphericalTensor inv(const dimensionedSphericalTensor &dt)
Ostream & endl(Ostream &os)
Add newline and flush stream.
IOobject defines the attributes of an object for which implicit objectRegistry management is supporte...
const volVectorField & C() const
Return cell centres as volVectorField.
A class representing the concept of 0 used to avoid unnecessary manipulations for objects that are kn...
virtual bool movePoints()
Delete the least square vectors when the mesh moves.
Templated abstract base-class for optional mesh objects used to automate their allocation to the mesh...
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
const dimensionSet dimless(0, 0, 0, 0, 0, 0, 0)
A finiteVolume patch using a polyPatch and a fvBoundaryMesh.
const labelUList & neighbour() const
Internal face neighbour.
dimensionedSymmTensor sqr(const dimensionedVector &dv)
An abstract base class with a fat-interface to all derived classes covering all possible ways in whic...
defineTypeNameAndDebug(combustionModel, 0)