reduction of std::pow calls; stronger usage of
Cartesian- and CylinderCoordinate objects
This commit is contained in:
@@ -11,6 +11,8 @@ class DriftVelocity {
|
||||
DriftVelocity(std::shared_ptr<VectorField> drift_velocity);
|
||||
|
||||
CartesianVector driftVelocity(const Coordinate& position);
|
||||
CartesianVector driftVelocity(const CartesianCoordinate& cartCoord,
|
||||
const CylinderCoordinate& cylCoord);
|
||||
|
||||
private:
|
||||
std::shared_ptr<VectorField> drift_velocity_;
|
||||
|
||||
@@ -19,7 +19,8 @@ class Particle {
|
||||
const double weight);
|
||||
|
||||
void position(const Coordinate& new_position);
|
||||
CartesianCoordinate position() const;
|
||||
CartesianCoordinate cartesianPosition() const;
|
||||
CylinderCoordinate cylinderPosition() const;
|
||||
|
||||
void velocity(const CartesianVector& new_velocity);
|
||||
CartesianVector velocity() const;
|
||||
@@ -55,7 +56,8 @@ class Particle {
|
||||
double weight_;
|
||||
|
||||
CartesianVector velocity_;
|
||||
CartesianCoordinate position_;
|
||||
CartesianCoordinate position_cart_;
|
||||
CylinderCoordinate position_cyl_;
|
||||
|
||||
double time_alive_s_;
|
||||
// double time_in_bin_s_;
|
||||
|
||||
Reference in New Issue
Block a user