Many, many more comments

This commit is contained in:
2024-12-04 17:15:04 +01:00
parent 8696517336
commit 03854339ca
100 changed files with 1702 additions and 49 deletions
@@ -5,19 +5,30 @@
#include <random>
#include "simulation/coordinates.h"
// defined in "velocity_distribution_function.h"
class VelocityDistributionFunction;
// class to define the minimum requirements of a velocity distribution function
// (in the frame center of mass frame)
class VelocityDistribution {
public:
// draw a randomly oriented Cartesian velocity vector at the Coordinate position
// using the random engine
virtual CartesianVector rollVelocity(const Coordinate& position,
std::mt19937* engine) = 0;
};
// class that defines a velocity distribution by the usage of a VelocityDistributionFunction
// object
class VelocityDistributionFromFunction : public VelocityDistribution {
public:
// Constructor: takes a shared_ptr to the VelocityDistributionFunction, that defines the
// distribution to be drawn from
VelocityDistributionFromFunction(
std::shared_ptr<VelocityDistributionFunction> fv);
// returns a radnomly oriented CartesianVector drawn from the VelocityDistribution
// given at creation of the object
CartesianVector rollVelocity(const Coordinate& position,
std::mt19937* engine);