reduction of calls to atan2, sin and cos
This commit is contained in:
@@ -19,8 +19,10 @@ class Particle {
|
||||
|
||||
// set the position of the particle to the provided Coordinate new_position
|
||||
void position(const Coordinate& new_position);
|
||||
// return the position of the particle as a CartesianVector
|
||||
// return the position of the particle as a CartesianCoordinate
|
||||
CartesianCoordinate position() const;
|
||||
// return the cylinder position of the particle
|
||||
CylinderCoordinate cylinderPosition() const;
|
||||
|
||||
// set the velocity of the particle to the provided CartesianVector new_velocity
|
||||
void velocity(const CartesianVector& new_velocity);
|
||||
@@ -77,6 +79,7 @@ class Particle {
|
||||
private:
|
||||
CartesianVector velocity_;
|
||||
CartesianCoordinate position_;
|
||||
CylinderCoordinate position_cyl_;
|
||||
|
||||
double time_alive_s_;
|
||||
double time_in_bin_s_;
|
||||
|
||||
Reference in New Issue
Block a user