|
| Particle (double IQ, double q, double m, const PP &x) |
| Constructor for particle.
|
|
| Particle (std::istream &s) |
| Constructor for loading particle from a file.
|
|
| ~Particle () |
| Destructor.
|
|
double & | operator() (int i) |
| Operator for pointing to coordinate data.
|
|
const double & | operator() (int i) const |
| Operator for pointing to coordinate data.
|
|
double & | operator[] (int i) |
| Operator for pointing to coordinate data.
|
|
const double & | operator[] (int i) const |
| Operator for pointing to coordinate data.
|
|
Vec3D | location () const |
| Returns the location of particle in Vec3D.
|
|
Vec3D | velocity () const |
| Returns the velocity of particle in Vec3D.
|
|
PP & | x () |
| Return reference to coordinate data.
|
|
const PP & | x () const |
| Return const reference to coordinate data.
|
|
PP & | traj (int i) |
| Return reference to trajectory data.
|
|
const PP & | traj (int i) const |
| Return const reference to trajectory data.
|
|
size_t | traj_size (void) const |
| Return number of trajectory points of particle.
|
|
void | add_trajectory_point (const PP &x) |
| Add trajectory point to the end of the trajectory.
|
|
void | copy_trajectory (const std::vector< PP > &traj) |
| Define trajectory by copying.
|
|
void | clear_trajectory (void) |
| Clears the particle trajectory.
|
|
void | save (std::ostream &s) const |
| Saves data to stream.
|
|
void | debug_print (std::ostream &os) const |
| Print debugging information to os.
|
|
Public Member Functions inherited from ParticleBase |
particle_status_e | get_status () |
| Return particle status.
|
|
void | set_status (particle_status_e status) |
| Set particle status.
|
|
double | IQ () const |
| Return current or charge carried by trajectory or particle cloud [A/C].
|
|
double | q () const |
| Return particle charge (q) [C].
|
|
double | m () const |
| Return particle mass (m) [kg].
|
|
double | qm () const |
| Return charge per mass ratio (q/m) [C/kg].
|
|
void | save (std::ostream &s) const |
| Saves data to stream.
|
|
template<class PP>
class Particle< PP >
Particle class in some geometry.
Contains a templated description of one particle in some geometry. The geometry is selected throught templation, where PP is either ParticleP2D, ParticlePCyl or ParticleP3D. The particle classes for defined geometry modes can be used through defined types Particle2D, ParticleCyl and Particle3D.