Project-3/include/Particle.hpp
Cory 1ae665e7e7
Update versions and some other things
- Update version numbers for Doxygen
- Use vec3 instead of vec_3d
2023-10-23 12:42:12 +02:00

49 lines
1.1 KiB
C++

/** @file Particle.hpp
*
* @author Cory Alexander Balaton (coryab)
* @author Janita Ovidie Sandtrøen Willumsen (janitaws)
*
* @version 1.0
*
* @brief A class that holds the properties of a particle.
*
* @bug No known bugs
* */
#ifndef __PARTICLE__
#define __PARTICLE__
#include <armadillo>
#include "constants.hpp"
#include "typedefs.hpp"
/** @brief A class that holds attributes of a particle
* */
class Particle
{
private:
vec3 r_vec; ///< position
vec3 v_vec; ///< velocity
double q; ///< Charge
double m; ///< Mass
public:
/** @brief Initialize the particle.
*
* @details Initialize the particle with a charge, mass, position and
* velocity.
*
* @param q The charge of the particle
* @param m The mass of the particle
* @param r_vec The initial position of the particle
* @param v_vec The initial velocity of the particle
* */
Particle(vec3 r_vec, vec3 v_vec, double q = CA_CHARGE, double m = CA_MASS);
/** @brief Make private attributes available for PenningTrap.
* */
friend class PenningTrap;
};
#endif