100 int spawnParticles(std::vector<Particle>& particles)
const override;
ThirdDimension
Enum class to define the dimension count of the simulation (2D or 3D). Affects primarily the dimensio...
LockState
Enum class to define the lockstate of particles. Locked particles are not allowed to move.
Interface for particle spawner classes.
Class to spawn particles in a Sphere. Implements the interface ParticleSpawner.
const std::array< double, 3 > center
Defines the center of the sphere.
const double grid_spacing
Defines the spacing between neighboring particles in the sphere.
const double initial_temperature
Defines the initial temperature of the particles in the sphere.
const double espilon
Defines the Lennard-Jones epsilon parameter of the particles in the sphere.
const std::array< double, 3 > initial_velocity
Defines the initial velocity of the particles in the sphere.
SphereSpawner(const std::array< double, 3 > ¢er, int sphere_radius, double grid_spacing, double mass, const std::array< double, 3 > &initial_velocity, int type, double epsilon=1.0, double sigma=1.2, LockState lock_state=LockState::UNLOCKED, ThirdDimension third_dimension=ThirdDimension::ENABLED, double initial_temperature=0.1)
Constructor.
const int sphere_radius
Defines the radius of the sphere.
const LockState lock_state
Defines whether the particles in the sphere are locked.
const double mass
Defines the mass of the particles in the sphere.
const ThirdDimension third_dimension
Defines whether to use the third dimension.
const int type
Defines the type of the particles in the sphere.
const double sigma
Defines the Lennard-Jones sigma parameter of the particles in the sphere.
size_t getEstimatedNumberOfParticles() const override
Returns the number of particles to be spawned.
int spawnParticles(std::vector< Particle > &particles) const override
Spawns particles in the given container.