31 inline void Foam::meshPhiCorrectInfo::validateFace()
const
36 <<
"Face data requested from a non-face correction info"
42 inline void Foam::meshPhiCorrectInfo::validateCell()
const
44 if (shape_ != shape::cell)
47 <<
"Cell data requested from a non-cell correction info"
57 shape_(
shape::invalid),
65 delta_(
s ==
shape::invalid ? NaN : 0)
99 template<
class TrackingData>
102 return shape_ != shape::invalid;
106 template<
class TrackingData>
119 template<
class TrackingData>
123 const label patchFacei,
130 template<
class TrackingData>
134 const label thisCelli,
141 const label neighbourPatchi = neighbourPatchAndFacei.
first();
142 const label neighbourFacei = neighbourPatchAndFacei.
second();
145 td.cellPci_[thisCelli];
147 neighbourPatchi == -1
148 ? td.internalFacePci_[neighbourFacei]
149 : td.patchFacePci_[neighbourPatchi][neighbourFacei];
153 shape_ = shape::cell;
154 deltaDVdtError() = 0;
160 neighbourPatchi == -1
161 ? (mesh.
owner()[neighbourFacei] == thisCelli ? +1 : -1)
164 deltaDVdtError() -=
s*neighbourInfo.
deltaPhi();
175 template<
class TrackingData>
180 const label neighbourCelli,
186 const label thisPatchi = thisPatchAndFacei.
first();
187 const label thisFacei = thisPatchAndFacei.
second();
191 ? td.internalFacePci_[thisFacei]
192 : td.patchFacePci_[thisPatchi][thisFacei];
194 td.cellPci_[neighbourCelli];
198 shape_ = shape::face;
206 ? (mesh.
owner()[thisFacei] == neighbourCelli ? +1 : -1)
211 *(td.dVdtError_[neighbourCelli] + neighbourInfo.
deltaDVdtError());
222 template<
class TrackingData>
234 shape_ = shape::face;
238 deltaPhi() = - neighbourInfo.
deltaPhi();
244 template<
class TrackingData>
257 inline bool Foam::meshPhiCorrectInfo::operator==
262 return shape_ == rhs.shape_ && delta_ == rhs.delta_;
266 inline bool Foam::meshPhiCorrectInfo::operator!=
271 return !(*
this == rhs);
279 return os << static_cast<label>(l.shape_) <<
token::SPACE << l.delta_;
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
const Type & second() const
Return second.
const Type & first() const
Return first.
Mesh data needed to do the Finite Volume discretisation.
const labelUList & owner() const
Internal face owner.
A finiteVolume patch using a polyPatch and a fvBoundaryMesh.
bool updateCell(const fvMesh &mesh, const label thisCelli, const labelPair &neighbourPatchAndFacei, const meshPhiCorrectInfo &neighbourInfo, const scalar tol, TrackingData &td)
Influence of neighbouring face.
bool updateFace(const fvMesh &mesh, const labelPair &thisPatchAndFacei, const label neighbourCelli, const meshPhiCorrectInfo &neighbourInfo, const scalar tol, TrackingData &td)
Influence of neighbouring cell.
scalar deltaPhi() const
Return the flux correction.
shape
Enumeration to define the mesh shape the info applies to.
meshPhiCorrectInfo()
Construct null.
bool equal(const meshPhiCorrectInfo &, TrackingData &td) const
Test equality.
bool sameGeometry(const fvMesh &mesh, const meshPhiCorrectInfo &, const scalar, TrackingData &td) const
Check for identical geometrical data. Used for checking.
scalar deltaDVdtError() const
Return the volume change rate error correction.
bool valid(TrackingData &td) const
Check whether the meshPhiCorrectInfo has been changed at all.
void transform(const fvPatch &patch, const label patchFacei, const transformer &transform, TrackingData &td)
Transform across an interface.
scalar weight() const
Return the weight.
label layer() const
Return the layer index.
gmvFile<< "tracers "<< particles.size()<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().x()<< " ";}gmvFile<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().y()<< " ";}gmvFile<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().z()<< " ";}gmvFile<< nl;forAll(lagrangianScalarNames, i){ word name=lagrangianScalarNames[i];IOField< scalar > s(IOobject(name, runTime.name(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE))
bool valid(const PtrList< ModelType > &l)
errorManipArg< error, int > exit(error &err, const int errNo=1)
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
tmp< fvMatrix< Type > > operator==(const fvMatrix< Type > &, const fvMatrix< Type > &)
Istream & operator>>(Istream &, pistonPointEdgeData &)
dimensionSet transform(const dimensionSet &)
Ostream & operator<<(Ostream &os, const fvConstraints &constraints)