Classes | Public Member Functions | Static Public Member Functions | Static Public Attributes | Protected Member Functions | Protected Attributes | Friends | List of all members
particle< Type > Class Template Reference

Base particle class. More...

Inheritance diagram for particle< Type >:
Inheritance graph
[legend]
Collaboration diagram for particle< Type >:
Collaboration graph
[legend]

Classes

class  iNew
 Factory class to read-construct particles used for. More...
 
class  TrackingData
 

Public Member Functions

 TypeName ("particle")
 Runtime type information. More...
 
 particle (const polyMesh &mesh, const vector &position, const label celli, const label tetFacei, const label tetPtI)
 Construct from components. More...
 
 particle (const polyMesh &mesh, const vector &position, const label celli, bool doCellFacePt=true)
 Construct from components, tetFacei_ and tetPtI_ are not. More...
 
 particle (const polyMesh &mesh, Istream &, bool readFields=true)
 Construct from Istream. More...
 
 particle (const particle &p)
 Construct as a copy. More...
 
 particle (const particle &p, const polyMesh &mesh)
 Construct as a copy with refernce to a new mesh. More...
 
virtual autoPtr< particleclone () const
 Construct a clone. More...
 
virtual ~particle ()
 Destructor. More...
 
label getNewParticleID () const
 Get unique particle creation id. More...
 
const polyMeshmesh () const
 Return the mesh database. More...
 
const vectorposition () const
 Return current particle position. More...
 
vectorposition ()
 Return current particle position. More...
 
labelcell ()
 Return current cell particle is in. More...
 
label cell () const
 Return current cell particle is in. More...
 
labeltetFace ()
 Return current tet face particle is in. More...
 
label tetFace () const
 Return current tet face particle is in. More...
 
labeltetPt ()
 Return current tet face particle is in. More...
 
label tetPt () const
 Return current tet face particle is in. More...
 
tetIndices currentTetIndices () const
 Return the indices of the current tet that the. More...
 
tetPointRef currentTet () const
 Return the geometry of the current tet that the. More...
 
vector normal () const
 Return the normal of the tri on tetFacei_ for the. More...
 
vector oldNormal () const
 Return the normal of the tri on tetFacei_ for the. More...
 
labelface ()
 Return current face particle is on otherwise -1. More...
 
label face () const
 Return current face particle is on otherwise -1. More...
 
bool softImpact () const
 Return the impact model to be used, soft or hard (default). More...
 
scalar currentTime () const
 Return the particle current time. More...
 
void initCellFacePt ()
 Check the stored cell value (setting if necessary) and. More...
 
bool onBoundary () const
 Is the particle on the boundary/(or outside the domain)? More...
 
bool internalFace (const label facei) const
 Is this global face an internal face? More...
 
bool boundaryFace (const label facei) const
 Is this global face a boundary face? More...
 
label patch (const label facei) const
 Which patch is particle on. More...
 
label patchFace (const label patchi, const label facei) const
 Which face of this patch is this particle on. More...
 
scalar & stepFraction ()
 Return the fraction of time-step completed. More...
 
scalar stepFraction () const
 Return the fraction of time-step completed. More...
 
label origProc () const
 Return const access to the originating processor id. More...
 
labelorigProc ()
 Return the originating processor id for manipulation. More...
 
label origId () const
 Return const access to the particle id on originating processor. More...
 
labelorigId ()
 Return the particle id on originating processor for manipulation. More...
 
template<class TrackData >
label track (const vector &endPosition, TrackData &td)
 Track particle to end of trajectory. More...
 
template<class TrackData >
scalar trackToFace (const vector &endPosition, TrackData &td)
 Track particle to a given position and returns 1.0 if the. More...
 
label faceInterpolation () const
 Return the index of the face to be used in the interpolation. More...
 
virtual void transformProperties (const tensor &T)
 Transform the physical properties of the particle. More...
 
virtual void transformProperties (const vector &separation)
 Transform the physical properties of the particle. More...
 
virtual scalar wallImpactDistance (const vector &n) const
 The nearest distance to a wall that. More...
 
template<class TrackData >
void prepareForParallelTransfer (const label patchi, TrackData &td)
 Convert global addressing to the processor patch. More...
 
template<class TrackData >
void correctAfterParallelTransfer (const label patchi, TrackData &td)
 Convert processor patch addressing to the global equivalents. More...
 
void writePosition (Ostream &) const
 Write the particle position and cell. More...
 
template<class TrackData >
Foam::label track (const vector &endPosition, TrackData &td)
 
template<class TrackData >
Foam::scalar trackToFace (const vector &endPosition, TrackData &td)
 

Static Public Member Functions

static string propertyList ()
 
template<class CloudType >
static void readFields (CloudType &c)
 Read the fields associated with the owner cloud. More...
 
template<class CloudType >
static void writeFields (const CloudType &c)
 Write the fields associated with the owner cloud. More...
 

Static Public Attributes

static string propertyList_ = Foam::particle::propertyList()
 String representation of properties. More...
 
static label particleCount_ = 0
 Cumulative particle counter - used to provode unique ID. More...
 
static const scalar trackingCorrectionTol = 1e-5
 Fraction of distance to tet centre to move a particle to. More...
 
static const scalar lambdaDistanceToleranceCoeff = 1e3*SMALL
 Fraction of the cell volume to use in determining tolerance values. More...
 
static const scalar minStepFractionTol = 1e5*SMALL
 Minimum stepFraction tolerance. More...
 

Protected Member Functions

void findTris (const vector &position, DynamicList< label > &faceList, const tetPointRef &tet, const FixedList< vector, 4 > &tetAreas, const FixedList< label, 4 > &tetPlaneBasePtIs, const scalar tol) const
 Find the tet tri faces between position and tet centre. More...
 
scalar tetLambda (const vector &from, const vector &to, const label triI, const vector &tetArea, const label tetPlaneBasePtI, const label celli, const label tetFacei, const label tetPtI, const scalar tol) const
 Find the lambda value for the line to-from across the. More...
 
scalar movingTetLambda (const vector &from, const vector &to, const label triI, const vector &tetArea, const label tetPlaneBasePtI, const label celli, const label tetFacei, const label tetPtI, const scalar tol) const
 Find the lambda value for a moving tri face. More...
 
void tetNeighbour (label triI)
 Modify the tet owner data by crossing triI. More...
 
void crossEdgeConnectedFace (const label &celli, label &tetFacei, label &tetPtI, const edge &e)
 Cross the from the given face across the given edge of the. More...
 
template<class CloudType >
void hitWallFaces (const CloudType &td, const vector &from, const vector &to, scalar &lambdaMin, tetIndices &closestTetIs)
 
template<class TrackData >
void hitFace (TrackData &td)
 Overridable function to handle the particle hitting a face. More...
 
template<class TrackData >
bool hitPatch (const polyPatch &, TrackData &td, const label patchi, const scalar trackFraction, const tetIndices &tetIs)
 Overridable function to handle the particle hitting a. More...
 
template<class TrackData >
void hitWedgePatch (const wedgePolyPatch &, TrackData &td)
 Overridable function to handle the particle hitting a wedgePatch. More...
 
template<class TrackData >
void hitSymmetryPlanePatch (const symmetryPlanePolyPatch &, TrackData &td)
 Overridable function to handle the particle hitting a. More...
 
template<class TrackData >
void hitSymmetryPatch (const symmetryPolyPatch &, TrackData &td)
 Overridable function to handle the particle hitting a. More...
 
template<class TrackData >
void hitCyclicPatch (const cyclicPolyPatch &, TrackData &td)
 Overridable function to handle the particle hitting a cyclicPatch. More...
 
template<class TrackData >
void hitCyclicAMIPatch (const cyclicAMIPolyPatch &, TrackData &td, const vector &direction)
 Overridable function to handle the particle hitting a cyclicAMIPatch. More...
 
template<class TrackData >
void hitProcessorPatch (const processorPolyPatch &, TrackData &td)
 Overridable function to handle the particle hitting a. More...
 
template<class TrackData >
void hitWallPatch (const wallPolyPatch &, TrackData &td, const tetIndices &tetIs)
 Overridable function to handle the particle hitting a wallPatch. More...
 
template<class TrackData >
void hitPatch (const polyPatch &, TrackData &td)
 Overridable function to handle the particle hitting a. More...
 

Protected Attributes

const polyMeshmesh_
 Reference to the polyMesh database. More...
 
vector position_
 Position of particle. More...
 
label celli_
 Index of the cell it is in. More...
 
label facei_
 Face index if the particle is on a face otherwise -1. More...
 
scalar stepFraction_
 Fraction of time-step completed. More...
 
label tetFacei_
 Index of the face that owns the decomposed tet that the. More...
 
label tetPtI_
 Index of the point on the face that defines the decomposed. More...
 
label origProc_
 Originating processor id. More...
 
label origId_
 Local particle id on originating processor. More...
 

Friends

Ostreamoperator<< (Ostream &, const particle &)
 
bool operator== (const particle &pA, const particle &pB)
 
bool operator!= (const particle &pA, const particle &pB)
 

Additional Inherited Members

Detailed Description

template<class Type>
class Foam::particle< Type >

Base particle class.

Definition at line 78 of file particle.H.

Constructor & Destructor Documentation

particle ( const polyMesh mesh,
const vector position,
const label  celli,
const label  tetFacei,
const label  tetPtI 
)

Construct from components.

Definition at line 48 of file particle.C.

Referenced by particle< Type >::clone(), and particle< Type >::iNew::operator()().

Here is the caller graph for this function:

particle ( const polyMesh mesh,
const vector position,
const label  celli,
bool  doCellFacePt = true 
)

Construct from components, tetFacei_ and tetPtI_ are not.

supplied so they will be deduced by a search

Definition at line 69 of file particle.C.

particle ( const polyMesh mesh,
Istream is,
bool  readFields = true 
)
particle ( const particle< Type > &  p)

Construct as a copy.

Definition at line 93 of file particle.C.

particle ( const particle< Type > &  p,
const polyMesh mesh 
)

Construct as a copy with refernce to a new mesh.

Definition at line 107 of file particle.C.

virtual ~particle ( )
inlinevirtual

Member Function Documentation

void findTris ( const vector position,
DynamicList< label > &  faceList,
const tetPointRef tet,
const FixedList< vector, 4 > &  tetAreas,
const FixedList< label, 4 > &  tetPlaneBasePtIs,
const scalar  tol 
) const
inlineprotected

Find the tet tri faces between position and tet centre.

Definition at line 32 of file particleI.H.

References DynamicList< T, SizeInc, SizeMult, SizeDiv >::append(), tetrahedron< Point, PointRef >::centre(), DynamicList< T, SizeInc, SizeMult, SizeDiv >::clear(), lambda(), and particle< Type >::tetLambda().

Referenced by particle< Type >::trackToFace().

Here is the call graph for this function:

Here is the caller graph for this function:

Foam::scalar tetLambda ( const vector from,
const vector to,
const label  triI,
const vector tetArea,
const label  tetPlaneBasePtI,
const label  celli,
const label  tetFacei,
const label  tetPtI,
const scalar  tol 
) const
inlineprotected

Find the lambda value for the line to-from across the.

given tri face, where p = from + lambda*(to - from)

Definition at line 69 of file particleI.H.

References Foam::mag(), particle< Type >::movingTetLambda(), and Foam::sign().

Referenced by particle< Type >::findTris(), particle< Type >::hitWallFaces(), and particle< Type >::trackToFace().

Here is the call graph for this function:

Here is the caller graph for this function:

Foam::scalar movingTetLambda ( const vector from,
const vector to,
const label  triI,
const vector tetArea,
const label  tetPlaneBasePtI,
const label  celli,
const label  tetFacei,
const label  tetPtI,
const scalar  tol 
) const
inlineprotected
void tetNeighbour ( label  triI)
inlineprotected
void crossEdgeConnectedFace ( const label celli,
label tetFacei,
label tetPtI,
const edge e 
)
inlineprotected

Cross the from the given face across the given edge of the.

given cell to find the resulting face and tetPtI

Definition at line 458 of file particleI.H.

References Foam::abort(), primitiveMesh::cells(), face::edgeDirection(), edge::end(), f(), polyMesh::faces(), Foam::FatalError, FatalErrorInFunction, Foam::findIndex(), forAll, particle< Type >::mesh_, Foam::neg(), Foam::meshTools::otherFace(), pFaces, List< T >::size(), edge::start(), and polyMesh::tetBasePtIs().

Referenced by wallBoundedParticle::crossEdgeConnectedFace(), and particle< Type >::tetNeighbour().

Here is the call graph for this function:

Here is the caller graph for this function:

void hitWallFaces ( const CloudType td,
const vector from,
const vector to,
scalar &  lambdaMin,
tetIndices closestTetIs 
)
inlineprotected
void hitFace ( TrackData &  td)
protected

Overridable function to handle the particle hitting a face.

Definition at line 926 of file particleTemplates.C.

References particle< Type >::hitPatch().

Here is the call graph for this function:

bool hitPatch ( const polyPatch ,
TrackData &  td,
const label  patchi,
const scalar  trackFraction,
const tetIndices tetIs 
)
protected

Overridable function to handle the particle hitting a.

patch. Executed before other patch-hitting functions. trackFraction is passed in to allow mesh motion to interpolate in time to the correct face state.

Definition at line 932 of file particleTemplates.C.

References particle< Type >::hitWedgePatch().

Referenced by particle< Type >::hitFace().

Here is the call graph for this function:

Here is the caller graph for this function:

void hitWedgePatch ( const wedgePolyPatch wpp,
TrackData &  td 
)
protected

Overridable function to handle the particle hitting a wedgePatch.

Definition at line 946 of file particleTemplates.C.

References Foam::abort(), Foam::FatalError, FatalErrorInFunction, particle< Type >::hitSymmetryPlanePatch(), Foam::I, Foam::mag(), particle< Type >::normal(), and particle< Type >::transformProperties().

Referenced by particle< Type >::hitPatch().

Here is the call graph for this function:

Here is the caller graph for this function:

void hitSymmetryPlanePatch ( const symmetryPlanePolyPatch spp,
TrackData &  td 
)
protected

Overridable function to handle the particle hitting a.

symmetryPlanePatch

Definition at line 964 of file particleTemplates.C.

References particle< Type >::hitSymmetryPatch(), Foam::I, Foam::mag(), particle< Type >::normal(), and particle< Type >::transformProperties().

Referenced by particle< Type >::hitWedgePatch().

Here is the call graph for this function:

Here is the caller graph for this function:

void hitSymmetryPatch ( const symmetryPolyPatch spp,
TrackData &  td 
)
protected

Overridable function to handle the particle hitting a.

symmetryPatch

Definition at line 978 of file particleTemplates.C.

References particle< Type >::hitCyclicPatch(), Foam::I, Foam::mag(), particle< Type >::normal(), and particle< Type >::transformProperties().

Referenced by particle< Type >::hitSymmetryPlanePatch().

Here is the call graph for this function:

Here is the caller graph for this function:

void hitCyclicPatch ( const cyclicPolyPatch cpp,
TrackData &  td 
)
protected
void hitCyclicAMIPatch ( const cyclicAMIPolyPatch cpp,
TrackData &  td,
const vector direction 
)
protected
void hitProcessorPatch ( const processorPolyPatch ,
TrackData &  td 
)
protected

Overridable function to handle the particle hitting a.

processorPatch

Definition at line 1099 of file particleTemplates.C.

References particle< Type >::hitWallPatch().

Here is the call graph for this function:

void hitWallPatch ( const wallPolyPatch ,
TrackData &  td,
const tetIndices tetIs 
)
protected

Overridable function to handle the particle hitting a wallPatch.

Definition at line 1105 of file particleTemplates.C.

Referenced by particle< Type >::hitProcessorPatch().

Here is the caller graph for this function:

void hitPatch ( const polyPatch ,
TrackData &  td 
)
protected

Overridable function to handle the particle hitting a.

general patch

Definition at line 1114 of file particleTemplates.C.

TypeName ( "particle< Type >"  )

Runtime type information.

static string propertyList ( )
inlinestatic

Definition at line 319 of file particle.H.

virtual autoPtr<particle> clone ( ) const
inlinevirtual

Construct a clone.

Reimplemented in molecule, wallBoundedParticle, streamLineParticle, wallBoundedStreamLineParticle, solidParticle, trackedParticle, findCellParticle, indexedParticle, and passiveParticle.

Definition at line 368 of file particle.H.

References particle< Type >::mesh_, and particle< Type >::particle().

Here is the call graph for this function:

Foam::label getNewParticleID ( ) const
inline

Get unique particle creation id.

Definition at line 566 of file particleI.H.

References Foam::endl(), Foam::labelMax, particle< Type >::particleCount_, and WarningInFunction.

Referenced by particle< Type >::~particle().

Here is the call graph for this function:

Here is the caller graph for this function:

const Foam::polyMesh & mesh ( ) const
inline

Return the mesh database.

Definition at line 580 of file particleI.H.

References particle< Type >::mesh_.

Referenced by findCellParticle::trackingData::cellToEnd(), trackedParticle::trackingData::trackingData(), and particle< Type >::~particle().

Here is the caller graph for this function:

const Foam::vector & position ( ) const
inline
Foam::vector & position ( )
inline

Return current particle position.

Definition at line 592 of file particleI.H.

References particle< Type >::position_.

Foam::label & cell ( )
inline

Return current cell particle is in.

Definition at line 604 of file particleI.H.

References particle< Type >::celli_.

Referenced by wallBoundedParticle::crossEdgeConnectedFace(), Foam::reconstructLagrangianPositions(), and particle< Type >::~particle().

Here is the caller graph for this function:

Foam::label cell ( ) const
inline

Return current cell particle is in.

Definition at line 598 of file particleI.H.

References particle< Type >::celli_.

Foam::label & tetFace ( )
inline

Return current tet face particle is in.

Definition at line 616 of file particleI.H.

References particle< Type >::tetFacei_.

Referenced by wallBoundedParticle::crossDiagonalEdge(), wallBoundedParticle::crossEdgeConnectedFace(), wallBoundedParticle::currentEdge(), and particle< Type >::~particle().

Here is the caller graph for this function:

Foam::label tetFace ( ) const
inline

Return current tet face particle is in.

Definition at line 610 of file particleI.H.

References particle< Type >::tetFacei_.

Foam::label & tetPt ( )
inline

Return current tet face particle is in.

Definition at line 628 of file particleI.H.

References particle< Type >::tetPtI_.

Referenced by wallBoundedParticle::crossDiagonalEdge(), wallBoundedParticle::crossEdgeConnectedFace(), and particle< Type >::~particle().

Here is the caller graph for this function:

Foam::label tetPt ( ) const
inline

Return current tet face particle is in.

Definition at line 622 of file particleI.H.

References particle< Type >::tetPtI_.

Foam::tetIndices currentTetIndices ( ) const
inline
Foam::tetPointRef currentTet ( ) const
inline

Return the geometry of the current tet that the.

particle occupies.

Definition at line 640 of file particleI.H.

References particle< Type >::currentTetIndices(), particle< Type >::mesh_, and tetIndices::tet().

Referenced by Foam::operator<<(), particle< Type >::trackToFace(), and particle< Type >::~particle().

Here is the call graph for this function:

Here is the caller graph for this function:

Foam::vector normal ( ) const
inline

Return the normal of the tri on tetFacei_ for the.

current tet.

Definition at line 646 of file particleI.H.

References particle< Type >::currentTetIndices(), tetIndices::faceTri(), particle< Type >::mesh_, and triangle< Point, PointRef >::normal().

Referenced by particle< Type >::hitSymmetryPatch(), particle< Type >::hitSymmetryPlanePatch(), molecule::hitWallPatch(), particle< Type >::hitWedgePatch(), and particle< Type >::~particle().

Here is the call graph for this function:

Here is the caller graph for this function:

Foam::vector oldNormal ( ) const
inline

Return the normal of the tri on tetFacei_ for the.

current tet at the start of the timestep, i.e. based on oldPoints

Definition at line 652 of file particleI.H.

References particle< Type >::currentTetIndices(), particle< Type >::mesh_, triangle< Point, PointRef >::normal(), and tetIndices::oldFaceTri().

Referenced by particle< Type >::~particle().

Here is the call graph for this function:

Here is the caller graph for this function:

Foam::label & face ( )
inline

Return current face particle is on otherwise -1.

Definition at line 664 of file particleI.H.

References particle< Type >::facei_.

Referenced by wallBoundedParticle::crossEdgeConnectedFace(), and particle< Type >::~particle().

Here is the caller graph for this function:

Foam::label face ( ) const
inline

Return current face particle is on otherwise -1.

Definition at line 658 of file particleI.H.

References particle< Type >::facei_.

bool softImpact ( ) const
inline

Return the impact model to be used, soft or hard (default).

Definition at line 852 of file particleI.H.

Referenced by particle< Type >::~particle().

Here is the caller graph for this function:

Foam::scalar currentTime ( ) const
inline

Return the particle current time.

Definition at line 858 of file particleI.H.

References TimeState::deltaTValue(), particle< Type >::mesh_, particle< Type >::stepFraction_, objectRegistry::time(), and dimensioned< Type >::value().

Referenced by particle< Type >::~particle().

Here is the call graph for this function:

Here is the caller graph for this function:

void initCellFacePt ( )
inline

Check the stored cell value (setting if necessary) and.

initialise the tetFace and tetPt values

Definition at line 670 of file particleI.H.

References Foam::abort(), primitiveMesh::cellCentres(), particle< Type >::celli_, Foam::endl(), Foam::FatalError, FatalErrorInFunction, polyMesh::findCellFacePt(), polyMesh::findTetFacePt(), Foam::mag(), particle< Type >::mesh_, Foam::nl, primitiveMesh::pointInCellBB(), particle< Type >::position_, particle< Type >::tetFacei_, particle< Type >::tetPtI_, particle< Type >::trackingCorrectionTol, and WarningInFunction.

Referenced by particle< Type >::~particle().

Here is the call graph for this function:

Here is the caller graph for this function:

bool onBoundary ( ) const
inline

Is the particle on the boundary/(or outside the domain)?

Definition at line 810 of file particleI.H.

References particle< Type >::facei_, particle< Type >::mesh_, and primitiveMesh::nInternalFaces().

Referenced by particle< Type >::track(), and particle< Type >::~particle().

Here is the call graph for this function:

Here is the caller graph for this function:

bool internalFace ( const label  facei) const
inline

Is this global face an internal face?

Definition at line 866 of file particleI.H.

References primitiveMesh::isInternalFace(), and particle< Type >::mesh_.

Referenced by particle< Type >::boundaryFace(), particle< Type >::hitWallFaces(), particle< Type >::trackToFace(), and particle< Type >::~particle().

Here is the call graph for this function:

Here is the caller graph for this function:

bool boundaryFace ( const label  facei) const
inline

Is this global face a boundary face?

Definition at line 872 of file particleI.H.

References particle< Type >::internalFace().

Referenced by particle< Type >::~particle().

Here is the call graph for this function:

Here is the caller graph for this function:

Foam::label patch ( const label  facei) const
inline

Which patch is particle on.

Definition at line 878 of file particleI.H.

References polyMesh::boundaryMesh(), particle< Type >::mesh_, particle< Type >::patchFace(), and polyBoundaryMesh::whichPatch().

Referenced by particle< Type >::trackToFace(), and particle< Type >::~particle().

Here is the call graph for this function:

Here is the caller graph for this function:

Foam::label patchFace ( const label  patchi,
const label  facei 
) const
inline

Which face of this patch is this particle on.

Definition at line 885 of file particleI.H.

References polyMesh::boundaryMesh(), particle< Type >::mesh_, and patchi.

Referenced by particle< Type >::patch(), and particle< Type >::~particle().

Here is the call graph for this function:

Here is the caller graph for this function:

Foam::scalar & stepFraction ( )
inline

Return the fraction of time-step completed.

Definition at line 816 of file particleI.H.

References particle< Type >::stepFraction_.

Referenced by wallBoundedStreamLineParticle::move(), molecule::move(), and particle< Type >::~particle().

Here is the caller graph for this function:

Foam::scalar stepFraction ( ) const
inline

Return the fraction of time-step completed.

Definition at line 822 of file particleI.H.

References particle< Type >::stepFraction_.

Foam::label origProc ( ) const
inline

Return const access to the originating processor id.

Definition at line 828 of file particleI.H.

References particle< Type >::origProc_.

Referenced by Foam::operator==(), particle< Type >::writeFields(), and particle< Type >::~particle().

Here is the caller graph for this function:

Foam::label & origProc ( )
inline

Return the originating processor id for manipulation.

Definition at line 834 of file particleI.H.

References particle< Type >::origProc_.

Foam::label origId ( ) const
inline

Return const access to the particle id on originating processor.

Definition at line 840 of file particleI.H.

References particle< Type >::origId_.

Referenced by Foam::operator==(), particle< Type >::readFields(), particle< Type >::writeFields(), and particle< Type >::~particle().

Here is the caller graph for this function:

Foam::label & origId ( )
inline

Return the particle id on originating processor for manipulation.

Definition at line 846 of file particleI.H.

References particle< Type >::origId_.

label track ( const vector endPosition,
TrackData &  td 
)

Track particle to end of trajectory.

or until it hits the boundary. On entry 'stepFraction()' should be set to the fraction of the time-step at which the tracking starts and on exit it contains the fraction of the time-step completed. Returns the boundary face index if the track stops at the boundary, -1 otherwise.

Referenced by particle< Type >::~particle().

Here is the caller graph for this function:

scalar trackToFace ( const vector endPosition,
TrackData &  td 
)

Track particle to a given position and returns 1.0 if the.

trajectory is completed without hitting a face otherwise stops at the face and returns the fraction of the trajectory completed. on entry 'stepFraction()' should be set to the fraction of the time-step at which the tracking starts.

Referenced by molecule::move(), particle< Type >::track(), and particle< Type >::~particle().

Here is the caller graph for this function:

Foam::label faceInterpolation ( ) const
inline

Return the index of the face to be used in the interpolation.

routine

Definition at line 894 of file particleI.H.

References particle< Type >::facei_.

Referenced by particle< Type >::~particle().

Here is the caller graph for this function:

void transformProperties ( const tensor T)
virtual

Transform the physical properties of the particle.

according to the given transformation tensor

Reimplemented in molecule, and solidParticle.

Definition at line 123 of file particle.C.

Referenced by particle< Type >::hitCyclicAMIPatch(), particle< Type >::hitCyclicPatch(), particle< Type >::hitSymmetryPatch(), particle< Type >::hitSymmetryPlanePatch(), particle< Type >::hitWedgePatch(), solidParticle::transformProperties(), molecule::transformProperties(), and particle< Type >::~particle().

Here is the caller graph for this function:

void transformProperties ( const vector separation)
virtual

Transform the physical properties of the particle.

according to the given separation vector

Reimplemented in molecule, and solidParticle.

Definition at line 127 of file particle.C.

Foam::scalar wallImpactDistance ( const vector n) const
virtual

The nearest distance to a wall that.

the particle can be in the n direction

Reimplemented in solidParticle.

Definition at line 131 of file particle.C.

Referenced by particle< Type >::~particle().

Here is the caller graph for this function:

void prepareForParallelTransfer ( const label  patchi,
TrackData &  td 
)

Convert global addressing to the processor patch.

local equivalents

Definition at line 41 of file particleTemplates.C.

References particle< Type >::correctAfterParallelTransfer().

Referenced by particle< Type >::~particle().

Here is the call graph for this function:

Here is the caller graph for this function:

void correctAfterParallelTransfer ( const label  patchi,
TrackData &  td 
)

Convert processor patch addressing to the global equivalents.

and set the celli to the face-neighbour

Definition at line 53 of file particleTemplates.C.

References polyPatch::faceCells(), coupledPolyPatch::forwardT(), coupledPolyPatch::parallel(), patchi, s(), coupledPolyPatch::separated(), coupledPolyPatch::separation(), List< T >::size(), polyPatch::start(), T, and coupledPolyPatch::transformPosition().

Referenced by particle< Type >::prepareForParallelTransfer(), and particle< Type >::~particle().

Here is the call graph for this function:

Here is the caller graph for this function:

void readFields ( CloudType c)
static
void writeFields ( const CloudType c)
static
void writePosition ( Ostream os) const

Write the particle position and cell.

Definition at line 89 of file particleIO.C.

References IOstream::ASCII, particle< Type >::celli_, IOstream::check(), IOstream::format(), particle< Type >::position_, token::SPACE, and Ostream::write().

Referenced by particle< Type >::~particle().

Here is the call graph for this function:

Here is the caller graph for this function:

Foam::label track ( const vector endPosition,
TrackData &  td 
)

Definition at line 188 of file particleTemplates.C.

References particle< Type >::facei_, particle< Type >::onBoundary(), particle< Type >::stepFraction_, and particle< Type >::trackToFace().

Here is the call graph for this function:

Foam::scalar trackToFace ( const vector endPosition,
TrackData &  td 
)

Friends And Related Function Documentation

Ostream& operator<< ( Ostream ,
const particle< Type > &   
)
friend
bool operator== ( const particle< Type > &  pA,
const particle< Type > &  pB 
)
friend
bool operator!= ( const particle< Type > &  pA,
const particle< Type > &  pB 
)
friend

Member Data Documentation

const polyMesh& mesh_
protected
vector position_
protected
label celli_
protected
label facei_
protected
scalar stepFraction_
protected
label tetFacei_
protected
label tetPtI_
protected
label origProc_
protected

Originating processor id.

Definition at line 161 of file particle.H.

Referenced by Foam::operator<<(), particle< Type >::origProc(), particle< Type >::particle(), and particle< Type >::readFields().

label origId_
protected

Local particle id on originating processor.

Definition at line 164 of file particle.H.

Referenced by Foam::operator<<(), particle< Type >::origId(), particle< Type >::particle(), and particle< Type >::readFields().

Foam::string propertyList_ = Foam::particle::propertyList()
static

String representation of properties.

Definition at line 319 of file particle.H.

Foam::label particleCount_ = 0
static

Cumulative particle counter - used to provode unique ID.

Definition at line 319 of file particle.H.

Referenced by particle< Type >::getNewParticleID().

const Foam::scalar trackingCorrectionTol = 1e-5
static

Fraction of distance to tet centre to move a particle to.

'rescue' it from a tracking problem

Definition at line 326 of file particle.H.

Referenced by particle< Type >::initCellFacePt(), sampledSet::pushIn(), and particle< Type >::trackToFace().

const Foam::scalar lambdaDistanceToleranceCoeff = 1e3*SMALL
static

Fraction of the cell volume to use in determining tolerance values.

for the denominator and numerator of lambda

Definition at line 330 of file particle.H.

Referenced by particle< Type >::hitWallFaces(), and particle< Type >::trackToFace().

const Foam::scalar minStepFractionTol = 1e5*SMALL
static

Minimum stepFraction tolerance.

Definition at line 333 of file particle.H.


The documentation for this class was generated from the following files: