32 template<
class TrackingData>
33 inline bool Foam::patchEdgeFaceInfo::update
36 const patchEdgeFaceInfo& w2,
41 scalar dist2 =
magSqr(pt - w2.origin());
47 origin_ = w2.origin();
52 scalar diff = distSqr_ - dist2;
60 if ((diff < small) || ((distSqr_ > small) && (diff/distSqr_ < tol)))
69 origin_ = w2.origin();
77 template<
class TrackingData>
78 inline bool Foam::patchEdgeFaceInfo::update
88 distSqr_ = w2.distSqr();
89 origin_ = w2.origin();
94 scalar diff = distSqr_ - w2.distSqr();
102 if ((diff < small) || ((distSqr_ > small) && (diff/distSqr_ < tol)))
110 distSqr_ = w2.distSqr();
111 origin_ = w2.origin();
152 template<
class TrackingData>
159 template<
class TrackingData>
173 template<
class TrackingData>
192 return update(eMid, faceInfo, tol, td);
196 template<
class TrackingData>
202 const bool sameOrientation,
207 return update(edgeInfo, tol, td);
211 template<
class TrackingData>
223 return update(patch.
faceCentres()[facei], edgeInfo, tol, td);
227 template<
class TrackingData>
240 inline bool Foam::patchEdgeFaceInfo::operator==
249 inline bool Foam::patchEdgeFaceInfo::operator!=
254 return !(*
this == rhs);
bool valid(TrackingData &td) const
Check whether origin has been changed at all or.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
static const Vector< scalar > max
dimensioned< Type > max(const dimensioned< Type > &, const dimensioned< Type > &)
const Field< PointType > & faceCentres() const
Return face centres for patch.
bool operator==(const patchEdgeFaceInfo &) const
patchEdgeFaceInfo()
Construct null.
dimensionedSymmTensor sqr(const dimensionedVector &dv)
bool equal(const patchEdgeFaceInfo &, TrackingData &td) const
Same (like operator==)
bool updateFace(const polyMesh &mesh, const primitivePatch &patch, const label facei, const label edgeI, const patchEdgeFaceInfo &edgeInfo, const scalar tol, TrackingData &td)
Influence of edge on face.
const labelList & meshPoints() const
Return labelList of mesh points in patch. They are constructed.
A list of faces which address into the list of points.
const point & origin() const
An edge is a list of two point labels. The functionality it provides supports the discretisation on a...
bool updateEdge(const polyMesh &mesh, const primitivePatch &patch, const label edgeI, const label facei, const patchEdgeFaceInfo &faceInfo, const scalar tol, TrackingData &td)
Influence of face on edge.
const Field< PointType > & points() const
Return reference to global points.
const edgeList & edges() const
Return list of edges, address into LOCAL point list.
dimensioned< scalar > magSqr(const dimensioned< Type > &)
vector point
Point is a vector.
const doubleScalar e
Elementary charge.
Mesh consisting of general polyhedral cells.
dimensionSet transform(const dimensionSet &)
void transform(const polyMesh &mesh, const primitivePatch &patch, const tensor &rotTensor, const scalar tol, TrackingData &td)
Apply rotation matrix.