Rigid body dynamics: Parallelization
Supervision:
Background:
The pe rigid body physics engine is a framework for the physically
correct simulation of rigid bodies of arbitrary shape. The engine is primarily focused
on accuracy and correctness and only secundary concerned about simulation performance.
However, performance still is a an important goal of the physics engine. Therefore the
parallelization of the engine is a necessary and desired requirement.
So far the engine is written for single core CPUs. This poses the obvious disadvantage
that it cannot exploit the possibilities of a multi core CPU as it is for example used
in computer games; in this case, one CPU is responsible for the physics calculations
whereas the other CPUs have different tasks.
Furthermore, the physics calculations themselves can easily exploit the computing power
of multi core CPUs. During each time step of a rigid body dynamics simulation, the
following steps have to be performed:
- Overlap detection between the rigid bodies
- Setup of contacts between touching rigid bodies
- Contact resolution to prevent interpenetration
- Moving the objects forward in time
Except for the contact resolution, all other aspects of a single time step can be efficiently
parallelized, e.g. several cores can create contacts for a certain configuration in parallel.
Since the generation of a specific contact is completely independent of the setup of another
contact, these tasks can be perfectly parallelized.
In order to increase the performance and to make the engine competitive, the goal of this
thesis is the parallelization of the pe rigid body physics engine. The
prefered way to achieve a flexible parallelization for multi core CPUs is via threads. The
first task will be to create a separate thread for the physics calculations. The second
task is the internal parallelization of the different steps with a single time step.
Tasks:
- Thread parallelization for the pe physics engine
- Performance comparison between the single core and multi core approach
- Development of demonstration examples
Recommended knowledge:
- Advanced C++ programming
- Parallelization basics
Status:
Finished
|