OpenFOAM logo
Open Source CFD Toolkit

particle Class Template Reference

Inheritance diagram for particle:

Inheritance graph
[legend]
Collaboration diagram for particle:

Collaboration graph
[legend]
List of all members.

template<class particleType>
class Foam::particle< particleType >


Public Member Functions

 TypeName ("particle")
 Runtime type information.
 particle (const Cloud< particleType > &, const vector &position, const label celli)
 Construct from components.
 particle (const Cloud< particleType > &, Istream &)
 Construct from Istream.
virtual ~particle ()
bool inCell ()
 Return true if particle is in cell.
bool inCell (const vector &position, const label celli, const scalar fraction)
 Return true if position is in cell i.
const vectorposition () const
 Return current particle position.
label cell () const
 Return current cell particle is in.
const Cloud< particleType > & cloud () const
 Return reference to the particle cloud.
bool onBoundary () const
 Is the particle on a boundary face?
label patch (const label facei) const
 Which patch is particle on.
label patchFace (const label patchi, const label facei) const
 Which face of this patch is this particle on.
virtual scalar wallImpactDistance (const vector &n) const
 The nearest distance to a wall that.
label track (const vector &endPosition, scalar &fraction, const bool softAlgorithm=false)
 Track particle to end of trajectory.
label trackToFace (const vector &endPosition, scalar &fraction, const bool softAlgorithm=false)
 Track particle to a given position.
void transformPosition (const tensor &T)
 Transform the position the particle.
virtual void transformProperties (const tensor &T)
 Transform the physical properties of the particle.

Protected Member Functions

void prepareForParallelTransfer (const label patchi, const label facei)
 Convert global addressing to the processor patch.
void correctAfterParallelTransfer (const label patchi, const label facei)
 Convert processor patch addressing to the global equivalents.

Friends

class Cloud<particleType>
Ostreamoperator (Ostream &, const particle< particleType > &)

Constructor & Destructor Documentation

particle const Cloud< particleType > &  ,
const vector position,
const label  celli
 

Construct from components.

particle const Cloud< particleType > &  ,
Istream
 

Construct from Istream.

virtual ~particle  )  [inline, virtual]
 

Definition at line 187 of file particle.H.


Member Function Documentation

label cell  )  const [inline]
 

Return current cell particle is in.

Definition at line 274 of file particleI.H.

const Cloud< particleType > & cloud  )  const [inline]
 

Return reference to the particle cloud.

Definition at line 260 of file particleI.H.

void correctAfterParallelTransfer const label  patchi,
const label  facei
[protected]
 

Convert processor patch addressing to the global equivalents.

and set the celli to the face-neighbour

bool inCell const vector position,
const label  celli,
const scalar  fraction
[inline]
 

Return true if position is in cell i.

Definition at line 245 of file particleI.H.

bool inCell  )  [inline]
 

Return true if particle is in cell.

Definition at line 236 of file particleI.H.

References Foam::label, Foam::labelList, and Foam::vector.

bool onBoundary  )  const [inline]
 

Is the particle on a boundary face?

Definition at line 282 of file particleI.H.

label patch const label  facei  )  const [inline]
 

Which patch is particle on.

Definition at line 288 of file particleI.H.

References Foam::label.

label patchFace const label  patchi,
const label  facei
const [inline]
 

Which face of this patch is this particle on.

Definition at line 295 of file particleI.H.

const vector & position  )  const [inline]
 

Return current particle position.

Definition at line 267 of file particleI.H.

void prepareForParallelTransfer const label  patchi,
const label  facei
[protected]
 

Convert global addressing to the processor patch.

local equivalents

label track const vector endPosition,
scalar &  fraction,
const bool  softAlgorithm = false
 

Track particle to end of trajectory.

or until it hits the boundary, on entry 'fraction' is the fraction of the integration step at which the tracking starts (only used for moving meshes) and on exit it contains the fraction of the traveled trajectory

label trackToFace const vector endPosition,
scalar &  fraction,
const bool  softAlgorithm = false
 

Track particle to a given position.

If particle reaches that position without hitting a face we return -1, otherwise track to face and return face index on entry 'fraction' is the fraction of the integration step at which the tracking starts (only used for moving meshes) upon exit fraction contains the fraction of the actual distance moved

void transformPosition const tensor T  ) 
 

Transform the position the particle.

according to the given transformation tensor

virtual void transformProperties const tensor T  )  [virtual]
 

Transform the physical properties of the particle.

according to the given transformation tensor

Reimplemented in parcel.

TypeName "particle< particleType >"   ) 
 

Runtime type information.

virtual scalar wallImpactDistance const vector n  )  const [virtual]
 

The nearest distance to a wall that.

the particle can be in the n direction


Friends And Related Function Documentation

friend class Cloud<particleType> [friend]
 

Definition at line 160 of file particle.H.

Ostream& operator Ostream ,
const particle< particleType > & 
[friend]
 


The documentation for this class was generated from the following files:
For further information go to www.openfoam.org