LSDTopoTools
 All Classes Files Functions Variables Friends Pages
Public Member Functions | Protected Attributes | List of all members
LSDParticle Class Reference

This is a class for a particle that can be tracked through simulations and retains data about position and chemical content. More...

#include <LSDParticle.hpp>

Inheritance diagram for LSDParticle:
LSDCRNParticle

Public Member Functions

 LSDParticle ()
 default constructor. Makes a particle with type 0, age 0, and no data for other parameters
 
 LSDParticle (int StartType)
 Constructor. Similar to default, but assignes type. More...
 
 LSDParticle (int StartType, double StartAge)
 Constructor. Similar to default, but assignes type and age. More...
 
 LSDParticle (int StartType, int StartCI, double StartAge, double StartOSLage, double StartxLoc, double StartdLoc)
 Constructor. Assignes all data members except yLoc. More...
 
 LSDParticle (int StartType, int StartCI, double StartAge, double StartOSLage, double StartxLoc, double StartyLoc, double StartdLoc)
 Constructor. Assignes all data members. More...
 
 LSDParticle (int StartType, double StartxLoc, double StartdLoc)
 Constructor. Assignes type, x location and d location. other parameters are default. More...
 
int getType () const
 Get the type. More...
 
int getCellIndex () const
 Get the CellIndex. More...
 
double getAge () const
 Get the Age. More...
 
double getOSLage () const
 Get the OSLage. More...
 
double getxLoc () const
 Get the xLoc. More...
 
double getyLoc () const
 Get the yLoc. More...
 
double getdLoc () const
 Get the dLoc. More...
 
 LSDParticle (const LSDParticle &tP)
 const reference operator
 
 LSDParticle (LSDParticle &tP)
 const reference operator
 
LSDParticleoperator= (const LSDParticle &tP)
 copy constructor
 
std::ostream & operator<< (std::ostream &)
 outstream operator
 
void incrementAge (double dt)
 Increase the age of the particle. More...
 
void setCellIndex (int CI)
 Change the cell index. Used for referencing where the particle is this could be changed in the future to an octree structure. More...
 
void OSLexpose ()
 This 'exposes' the particle to light and resets the OSL age.
 
void SoilAgeExpose ()
 This 'exposes' the particle and resets its soil age to zero.
 
void update_xLoc (double new_xLoc)
 Allows the user to update the horizontal location (dangerous!)
 
void update_yLoc (double new_yLoc)
 Allows the user to update the horizontal location (dangerous!)
 
void displaceReflect (double dx, double dd, double h, double dt)
 this changes a particles horizontal and vertical position. If the particle reaches the surface it 'reflects' back into the soil layer IMPORTANT: this increments the OSL age but not the soil age!! More...
 
int test_domain (double lambda)
 this function test to see if the particle is within a hillslope, and if not sets the data to no data values More...
 

Protected Attributes

int Type
 The type: used to identify, generally, what mineral the particle is.
 
int CellIndex
 
double Age
 Age the particle has spent in the soil.
 
double OSLage
 Optically stimulated luminescence age.
 
double xLoc
 Horizontal location of the particle.
 
double yLoc
 Other coordinate, used in 3D simulations.
 
double dLoc
 Depth of the particle.
 

Detailed Description

This is a class for a particle that can be tracked through simulations and retains data about position and chemical content.

Constructor & Destructor Documentation

LSDParticle::LSDParticle ( int  StartType)
inline

Constructor. Similar to default, but assignes type.

Parameters
StartTypethe type of the particle
LSDParticle::LSDParticle ( int  StartType,
double  StartAge 
)
inline

Constructor. Similar to default, but assignes type and age.

Parameters
StartTypethe type of the particle
StartAgethe starting age of the particle
LSDParticle::LSDParticle ( int  StartType,
int  StartCI,
double  StartAge,
double  StartOSLage,
double  StartxLoc,
double  StartdLoc 
)
inline

Constructor. Assignes all data members except yLoc.

Parameters
StartTypethe type of the particle
StartCIthe starting cell index
StartAgethe starting age of the particle
StartOSLagethe starting OSL age
StartxLocthe starting x location
StartdLocthe starting depth
LSDParticle::LSDParticle ( int  StartType,
int  StartCI,
double  StartAge,
double  StartOSLage,
double  StartxLoc,
double  StartyLoc,
double  StartdLoc 
)
inline

Constructor. Assignes all data members.

Parameters
StartTypethe type of the particle
StartCIthe starting cell index
StartAgethe starting age of the particle
StartOSLagethe starting OSL age
StartxLocthe starting x location
StartyLocthe starting y location
StartdLocthe starting depth
LSDParticle::LSDParticle ( int  StartType,
double  StartxLoc,
double  StartdLoc 
)
inline

Constructor. Assignes type, x location and d location. other parameters are default.

Parameters
StartTypethe type of the particle
StartxLocthe starting x location
StartdLocthe starting depth

Member Function Documentation

void LSDParticle::displaceReflect ( double  dx,
double  dd,
double  h,
double  dt 
)

this changes a particles horizontal and vertical position. If the particle reaches the surface it 'reflects' back into the soil layer IMPORTANT: this increments the OSL age but not the soil age!!

Parameters
dxthe distance moved horizontally.
ddthe distance moved in depth
hthe thickness of the soil
dtthe time over which the particle moves.
Author
SMM
Date
01/01/2010
double LSDParticle::getAge ( ) const
inline

Get the Age.

Returns
Age the Age of the particle. This is the time since it has entered the soil layer
int LSDParticle::getCellIndex ( ) const
inline

Get the CellIndex.

Returns
CellIndex the CellIndex of the particle
double LSDParticle::getdLoc ( ) const
inline

Get the dLoc.

Returns
dLoc the depth of the particle
double LSDParticle::getOSLage ( ) const
inline

Get the OSLage.

Returns
OSLage the Optically stimulated luminesce age of the particle
int LSDParticle::getType ( ) const
inline

Get the type.

Returns
Type the type of the particle
double LSDParticle::getxLoc ( ) const
inline

Get the xLoc.

Returns
xLoc the x location of the particle
double LSDParticle::getyLoc ( ) const
inline

Get the yLoc.

Returns
yLoc the y location of the particle
void LSDParticle::incrementAge ( double  dt)

Increase the age of the particle.

Parameters
dtthe time increment
void LSDParticle::setCellIndex ( int  CI)

Change the cell index. Used for referencing where the particle is this could be changed in the future to an octree structure.

Parameters
CIthe cell index
int LSDParticle::test_domain ( double  lambda)

this function test to see if the particle is within a hillslope, and if not sets the data to no data values

Parameters
lambdathe length of the hillslope
Author
SMM
Date
01/01/2010

Member Data Documentation

int LSDParticle::CellIndex
protected

The cell index, used for referencing the location of a particle in a grid


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