OpenFOAM logo
The Open Source CFD Toolbox
  Programmer’s C++ Doxygen OpenCFD Solutions Contact OpenFOAM

particle Class Template Reference

Inheritance diagram for particle:

Inheritance graph
[legend]
Collaboration diagram for particle:

Collaboration graph
[legend]
List of all members.

Detailed Description

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

Definition at line 81 of file particle.H.


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 &, bool readFields=true)
 Construct from Istream.
virtual ~particle ()
bool inCell ()
 Return true if particle is in cell.
bool inCell (const vector &position, const label celli, const scalar stepFraction)
 Return true if position is in cell i.
const vector & position () const
 Return current particle position.
label cell () const
 Return current cell particle is in.
label face () const
 Return current face particle is on otherwise -1.
const Cloud< particleType > & cloud () const
 Return reference to the particle cloud.
bool softImpact () const
 Return the impact model to be used, soft or hard (default).
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.
scalar wallImpactDistance (const vector &n) const
 The nearest distance to a wall that.
scalar & stepFraction ()
 Return the fraction of time-step completed.
scalar stepFraction () const
 Return the fraction of time-step completed.
template<class TrackingData>
label track (const vector &endPosition, TrackingData &td)
 Track particle to end of trajectory.
label track (const vector &endPosition)
 Calls the templated track with dummy TrackingData.
template<class TrackingData>
scalar trackToFace (const vector &endPosition, TrackingData &td)
 Track particle to a given position and returns 1.0 if the.
scalar trackToFace (const vector &endPosition)
 calls the templated trackToFace with dummy TrackingData

Protected Member Functions

template<class TrackingData>
void hitWedgePatch (const wedgePolyPatch &, TrackingData &td)
 Overridable function to handle the particle hitting a wedgePatch.
template<class TrackingData>
void hitSymmetryPatch (const symmetryPolyPatch &, TrackingData &td)
 Overridable function to handle the particle hitting a symmetryPatch.
template<class TrackingData>
void hitCyclicPatch (const cyclicPolyPatch &, TrackingData &td)
 Overridable function to handle the particle hitting a cyclicPatch.
template<class TrackingData>
void hitProcessorPatch (const processorPolyPatch &, TrackingData &td)
 Overridable function to handle the particle hitting a processorPatch.
template<class TrackingData>
void hitWallPatch (const wallPolyPatch &, TrackingData &td)
 Overridable function to handle the particle hitting a wallPatch.
template<class TrackingData>
void hitPatch (const polyPatch &, TrackingData &td)
 Overridable function to handle the particle hitting a general patch.
void transformPosition (const tensor &T)
 Transform the position the particle.
void transformProperties (const tensor &T)
 Transform the physical properties of the particle.
void transformProperties (const vector &separation)
 Transform the physical properties of the particle.
template<class TrackingData>
void prepareForParallelTransfer (const label patchi, TrackingData &td)
 Convert global addressing to the processor patch.
template<class TrackingData>
void correctAfterParallelTransfer (const label patchi, TrackingData &td)
 Convert processor patch addressing to the global equivalents.

Friends

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

Classes

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

Constructor & Destructor Documentation

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

Construct from components.

particle ( const Cloud< particleType > &  ,
Istream &  ,
bool  readFields = true 
)

Construct from Istream.

virtual ~particle (  )  [inline, virtual]

Definition at line 276 of file particle.H.


Member Function Documentation

void hitWedgePatch ( const wedgePolyPatch &  ,
TrackingData &  td 
) [protected]

Overridable function to handle the particle hitting a wedgePatch.

void hitSymmetryPatch ( const symmetryPolyPatch &  ,
TrackingData &  td 
) [protected]

Overridable function to handle the particle hitting a symmetryPatch.

void hitCyclicPatch ( const cyclicPolyPatch &  ,
TrackingData &  td 
) [protected]

Overridable function to handle the particle hitting a cyclicPatch.

void hitProcessorPatch ( const processorPolyPatch &  ,
TrackingData &  td 
) [protected]

Overridable function to handle the particle hitting a processorPatch.

void hitWallPatch ( const wallPolyPatch &  ,
TrackingData &  td 
) [protected]

Overridable function to handle the particle hitting a wallPatch.

void hitPatch ( const polyPatch &  ,
TrackingData &  td 
) [protected]

Overridable function to handle the particle hitting a general patch.

void transformPosition ( const tensor &  T  )  [protected]

Transform the position the particle.

according to the given transformation tensor

void transformProperties ( const tensor &  T  )  [protected]

Transform the physical properties of the particle.

according to the given transformation tensor

Reimplemented in parcel.

void transformProperties ( const vector &  separation  )  [protected]

Transform the physical properties of the particle.

according to the given separation vector

Reimplemented in parcel.

void prepareForParallelTransfer ( const label  patchi,
TrackingData &  td 
) [protected]

Convert global addressing to the processor patch.

local equivalents

void correctAfterParallelTransfer ( const label  patchi,
TrackingData &  td 
) [protected]

Convert processor patch addressing to the global equivalents.

and set the celli to the face-neighbour

TypeName ( "particle< particleType >"   ) 

Runtime type information.

bool inCell (  )  [inline]

Return true if particle is in cell.

Definition at line 243 of file particleI.H.

bool inCell ( const vector &  position,
const label  celli,
const scalar  stepFraction 
) [inline]

Return true if position is in cell i.

Definition at line 253 of file particleI.H.

References particle::position(), and UList::size().

Here is the call graph for this function:

const vector & position (  )  const [inline]

Return current particle position.

Definition at line 276 of file particleI.H.

Referenced by particle::inCell(), and parcel::Urel().

Here is the caller graph for this function:

label cell (  )  const [inline]

Return current cell particle is in.

Definition at line 283 of file particleI.H.

label face (  )  const [inline]

Return current face particle is on otherwise -1.

Definition at line 290 of file particleI.H.

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

Return reference to the particle cloud.

Definition at line 269 of file particleI.H.

bool softImpact (  )  const [inline]

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

Definition at line 319 of file particleI.H.

bool onBoundary (  )  const [inline]

Is the particle on a boundary face?

Definition at line 298 of file particleI.H.

label patch ( const label  facei  )  const [inline]

Which patch is particle on.

Definition at line 326 of file particleI.H.

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

Which face of this patch is this particle on.

Definition at line 334 of file particleI.H.

scalar wallImpactDistance ( const vector &  n  )  const [inline]

The nearest distance to a wall that.

the particle can be in the n direction

Reimplemented in solidParticle.

Definition at line 344 of file particleI.H.

scalar & stepFraction (  )  [inline]

Return the fraction of time-step completed.

Definition at line 305 of file particleI.H.

scalar stepFraction (  )  const [inline]

Return the fraction of time-step completed.

Definition at line 312 of file particleI.H.

label track ( const vector &  endPosition,
TrackingData &  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.

label track ( const vector &  endPosition  ) 

Calls the templated track with dummy TrackingData.

scalar trackToFace ( const vector &  endPosition,
TrackingData &  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.

scalar trackToFace ( const vector &  endPosition  ) 

calls the templated trackToFace with dummy TrackingData


Friends And Related Function Documentation

friend class Cloud< particleType > [friend]

Definition at line 230 of file particle.H.

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


The documentation for this class was generated from the following files: Copyright © 2000-2007 OpenCFD Ltd