[★★★★☆] Simulation of Particle Collision
In this example, we illustrate the contact problem by simulating a 2D particle collision problem. The model can be downloaded here.
General Information
The container is assumed to be a square with edge length of \(10\). A certain number of nodes are randomly generated
within the container with randomly generated initial velocities. A small program is written to generate the model
script. One could compile the Generator.cpp
file and run it with the number of particles needed. For example,
The model file will be generated as Collision.supan
.
Collision
The collision force \(F\) is assumed to be a function of distance \(d\) between two particles.
where \(s\) is the approximate size of particles, \(\alpha\) is a factor that can be used to adjust response. To define such a collision, one can use
Text Only | |
---|---|
in which \(s=2\) and \(\alpha\) is defaulted to be unity.
Container Boundary
The four edges of the container can be assigned by using the rigid wall constraint. For example,
Other Caveats
It shall be noted that a full matrix storage scheme shall be enabled to perform a collision simulation, since any two particles can collide with each other based on different initial conditions, there is no way to obtain a sparse/banded matrix in advance.
Output
The global kinetic energy can be recorded by using
Text Only | |
---|---|
Besides, it may be helpful to visualize the collision progress, to do that, a Visualisation
recorder can be defined.
Text Only | |
---|---|
Result
The kinetic energy history is obtained as follows. It can be seen that the total energy level is increasing with the number of collisions. The parameters can be further adjusted for more realistic results. Here the model is presented for the purpose of illustration.
The animation is presented as follows.