GenGeo  1.1
InsertGenerator2D Class Reference

#include <InsertGenerator2D.h>

Inheritance diagram for InsertGenerator2D:
Collaboration diagram for InsertGenerator2D:

Public Member Functions

 InsertGenerator2D ()
 InsertGenerator2D (double, double, int, int, double)
 InsertGenerator2D (double, double, int, int, double, bool)
virtual ~InsertGenerator2D ()
void setOldSeeding (bool)
virtual void fillIn (AVolume2D *, MNTable2D *, int, int)
virtual void generatePacking (AVolume2D *, MNTable2D *, int, int)
- Public Member Functions inherited from AGenerator2D
virtual ~AGenerator2D ()

Protected Member Functions

virtual void seedParticles (AVolume2D *, MNTable2D *, int, int)

Protected Attributes

double m_rmin
double m_rmax
double m_max_tries
int m_max_iter
double m_prec
bool m_old_seeding

Friends

ostream & operator<< (ostream &, const InsertGenerator2D &)

Detailed Description

Packing generator using Place et al. insertion based algorithm.

Constructor & Destructor Documentation

InsertGenerator2D::InsertGenerator2D ( )
InsertGenerator2D::InsertGenerator2D ( double  rmin,
double  rmax,
int  tries,
int  max_iter,
double  prec 
)

Constructor

Parameters
rminminimum particle radius
rmaxmaximum particle radius
ntriesmax. nr. of tries to insert particle
max_itermaximum iterations within the iterative solvers
precmax. error in iterative solvers

References m_max_iter, m_max_tries, m_old_seeding, m_prec, m_rmax, and m_rmin.

InsertGenerator2D::InsertGenerator2D ( double  rmin,
double  rmax,
int  tries,
int  max_iter,
double  prec,
bool  seed 
)

Constructor. Added random seed parameter

Parameters
rminminimum particle radius
rmaxmaximum particle radius
ntriesmax. nr. of tries to insert particle
max_itermaximum iterations within the iterative solvers
precmax. error in iterative solvers
seedif true, initialize random number generator via time

References m_max_iter, m_max_tries, m_old_seeding, m_prec, m_rmax, and m_rmin.

InsertGenerator2D::~InsertGenerator2D ( )
virtual

Destructor

Member Function Documentation

void InsertGenerator2D::fillIn ( AVolume2D vol,
MNTable2D ntable,
int  gid,
int  tag 
)
virtual

Fill in particles

Parameters
vola pointer to the packing volume
ntablea pointer to the neighbour table used
gidparticle group id
tagthe particle tag

Reimplemented in HexAggregateInsertGenerator2DRand, and HexAggregateInsertGenerator2D.

References MNTable2D::checkInsertable(), FitSphere2D(), AVolume::getAPoint(), AVolume2D::getClosestObjects(), AVolume2D::getClosestPlanes(), AVolume::getNumberSubVolumes(), MNTable2D::getSpheresClosestTo(), MNTable2D::insertChecked(), AVolume::isIn(), m_max_iter, m_max_tries, m_prec, m_rmax, m_rmin, Sphere::Radius(), and Sphere::setTag().

Referenced by generatePacking().

Here is the call graph for this function:

void InsertGenerator2D::generatePacking ( AVolume2D vol,
MNTable2D ntable,
int  gid,
int  tag 
)
virtual

generate packing

Parameters
vola pointer to the volume in which the packing is generated
ntablea pointer to the neighbour table used
gidparticle group id
tagthe particle tag

Implements AGenerator2D.

References fillIn(), and seedParticles().

Referenced by exportInsertGenerator2D(), and main().

Here is the call graph for this function:

void InsertGenerator2D::seedParticles ( AVolume2D vol,
MNTable2D ntable,
int  gid,
int  tag 
)
protectedvirtual

seed the area with particles

Parameters
vola pointer to the packing volume
ntablea pointer to the neighbour table used
gidparticle group id
tagthe particle tag

Reimplemented in HexAggregateInsertGenerator2DRand, and HexAggregateInsertGenerator2D.

References MNTable2D::checkInsertable(), AVolume::getBoundingBox(), MNTable2D::insertChecked(), AVolume::isIn(), m_old_seeding, m_prec, m_rmax, m_rmin, and Sphere::setTag().

Referenced by generatePacking().

Here is the call graph for this function:

void InsertGenerator2D::setOldSeeding ( bool  old)

toggle between old (pre rev.84, ansiotropic) and new (rev 84 onwards) seeding behaviour

Parameters
oldif true -> old behaviour, if false -> new behaviour

References m_old_seeding.

Referenced by exportInsertGenerator2D().

Friends And Related Function Documentation

ostream& operator<< ( ostream &  ost,
const InsertGenerator2D T 
)
friend

Member Data Documentation

double InsertGenerator2D::m_max_tries
protected
bool InsertGenerator2D::m_old_seeding
protected

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