ESyS-Particle  2.3.4
CSimple2DNTable Class Reference

2D implementation of simple, serial neighbor table More...

#include <SimpleNTable.h>

Inheritance diagram for CSimple2DNTable:
Collaboration diagram for CSimple2DNTable:

Public Member Functions

 CSimple2DNTable (const Vec3 &, const Vec3 &, double, bool xcirc=false, bool ycirc=false)
 
virtual void getInteractions (set< BasicInteraction, BILess > &, double)
 
void print ()
 
- Public Member Functions inherited from ASimpleNTable
 ASimpleNTable ()
 
virtual ~ASimpleNTable ()
 
int getNumInsertedParticles () const
 
const vector< SimpleParticle > * getNeighbors (const Vec3 &) const
 
int getClosestParticleID (const Vec3 &) const
 
void insertParticle (SimpleParticle)
 

Protected Member Functions

virtual int index (const Vec3 &) const
 
virtual vector< int > allidx (const Vec3 &) const
 
virtual void insertParticleCircular (SimpleParticle)
 

Private Attributes

Vec3 m_xshift
 
Vec3 m_yshift
 
int m_xsize
 
int m_ysize
 
bool m_xcirc
 
bool m_ycirc
 

Additional Inherited Members

- Protected Attributes inherited from ASimpleNTable
vector< SimpleParticle > * m_data
 
Vec3 m_p0
 
double m_dim
 
int m_numInsertedParticles
 

Detailed Description

2D implementation of simple, serial neighbor table

Author
Steffen Abe $Revision$ $Date$

Constructor & Destructor Documentation

◆ CSimple2DNTable()

CSimple2DNTable::CSimple2DNTable ( const Vec3 pos,
const Vec3 dim,
double  r,
bool  xcirc = false,
bool  ycirc = false 
)

Constructor

Parameters
posposition of the (xmin,ymin) point
dimsize of the space
rgrid spacing

References ASimpleNTable::m_data, ASimpleNTable::m_dim, ASimpleNTable::m_p0, m_xcirc, m_xshift, m_xsize, m_ycirc, m_yshift, m_ysize, Vec3::X(), and Vec3::Y().

Here is the call graph for this function:

Member Function Documentation

◆ allidx()

vector< int > CSimple2DNTable::allidx ( const Vec3 pos) const
protectedvirtual

Get all indices to which a particle at a given position will be added.

Parameters
posthe position
Warning
does not check if pos is within space

Implements ASimpleNTable.

References ASimpleNTable::m_dim, ASimpleNTable::m_p0, m_xsize, m_ysize, Vec3::X(), and Vec3::Y().

Referenced by insertParticleCircular().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getInteractions()

void CSimple2DNTable::getInteractions ( set< BasicInteraction, BILess > &  iset,
double  dmax 
)
virtual

Put all interactions into a set

Parameters
isetthe set into which to put them

Implements ASimpleNTable.

References esys::lsm::bpu::iter(), ASimpleNTable::m_data, m_xsize, and m_ysize.

Here is the call graph for this function:

◆ index()

int CSimple2DNTable::index ( const Vec3 pos) const
protectedvirtual

Return the grid index of a position.

Parameters
posthe position
Warning
does not check if pos is within space

Implements ASimpleNTable.

References ASimpleNTable::m_dim, ASimpleNTable::m_p0, m_xsize, Vec3::X(), and Vec3::Y().

Here is the call graph for this function:

◆ insertParticleCircular()

void CSimple2DNTable::insertParticleCircular ( SimpleParticle  cbp)
protectedvirtual

insert circular images of the particle

Parameters
cbpthe particle

Implements ASimpleNTable.

References allidx(), SimpleParticle::getPos(), ASimpleNTable::m_data, ASimpleNTable::m_dim, ASimpleNTable::m_p0, m_xcirc, m_xshift, m_xsize, SimpleParticle::moveTo(), and Vec3::X().

Here is the call graph for this function:

◆ print()

void CSimple2DNTable::print ( )

References esys::lsm::bpu::iter(), ASimpleNTable::m_data, m_xsize, and m_ysize.

Here is the call graph for this function:

Member Data Documentation

◆ m_xcirc

bool CSimple2DNTable::m_xcirc
private

◆ m_xshift

Vec3 CSimple2DNTable::m_xshift
private

◆ m_xsize

int CSimple2DNTable::m_xsize
private

◆ m_ycirc

bool CSimple2DNTable::m_ycirc
private

Referenced by CSimple2DNTable().

◆ m_yshift

Vec3 CSimple2DNTable::m_yshift
private

Referenced by CSimple2DNTable().

◆ m_ysize

int CSimple2DNTable::m_ysize
private

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