Distributed Simulation of Large Multi-body Systems

Manas Kale,Paul G. Kry
2024-03-26
Abstract:We present a technique designed for parallelizing large rigid body simulations, capable of exploiting multiple CPU cores within a computer and across a network. Our approach can be applied to simulate both unilateral and bilateral constraints, requiring straightforward modifications to the underlying physics engine. Starting from an approximate partitioning, we identify interface bodies and add them to overlapping sets such that they are simulated by multiple workers. At each timestep, we blend the states of overlap bodies using weights based on graph geodesic distances within the constraint graph. The use of overlap simulation also allows us to perform load balancing using efficient local evaluations of the constraint graph. We demonstrate our technique's scalability and load-balancing capabilities using several large-scale scenes.
Graphics,Distributed, Parallel, and Cluster Computing
What problem does this paper attempt to address?
### What problems does this paper attempt to solve? This paper aims to solve the performance bottleneck problems in large - scale multi - rigid - body system simulations, especially load balancing and efficiency improvement in parallel and distributed computing environments. Specifically: 1. **Improve simulation performance**: With the increasing demand in large - scale movie production and video game production, the industry trend is increasingly focused on faster and larger - scale simulations (i.e., performance). The main focus of this paper is to improve the performance of rigid - body simulations through parallel computing. 2. **Handle complex collisions and constraints**: In large - scale rigid - body simulations, the collision of interface bodies between different partitions is a key challenge. If an object in one partition collides with an object in another partition, simple rules may lead to load imbalance. In addition, contact - rich scenarios introduce additional complexity, such as loops that may appear in the constraint graph. 3. **Achieve effective load balancing**: In distributed simulations, how to maintain a balanced workload among different computing nodes is an important issue. Since the simulation process is essentially chaotic and affected by unpredictable user inputs, it is difficult to determine the optimal partition allocation in advance. 4. **Utilize cloud computing technology**: By horizontally expanding the simulation workload onto heterogeneous CPUs, the scalability of cloud computing can be utilized to run large - scale simulations. However, how to maintain load balancing in such a dynamic environment is a challenge. To solve these problems, the author proposes an overlap algorithm, which improves the existing methods in the following ways: - **Overlapping simulation**: For interface bodies, simulate in multiple overlapping sets and perform weighted fusion of their states according to the geodesic distance in the constraint graph. - **Load balancing driven by local evaluation**: By using a simple greedy heuristic method, rely only on the local evaluation of the constraint graph topology to drive the system towards a more balanced load distribution. - **Support freely moving and joint - constrained bodies**: This method is applicable not only to freely moving rigid bodies but also to rigid bodies with joint constraints, thus being suitable for distributed computing environments. In summary, the main contribution of this paper is to provide a new parallel computing framework that can efficiently simulate large - scale multi - rigid - body systems in a distributed computing environment while maintaining good load balancing and simulation accuracy. ### Key formulas The formulas involved in the paper are mainly used to describe the constraint solving process in rigid - body simulations. Here are several key formulas: 1. **Relationship between velocity and force**: \[ M(v^+ - v)=hf + J^T\lambda^+ \] where: - \(M\in\mathbb{R}^{6n\times6n}\) is a symmetric positive - definite mass matrix - \(v\in\mathbb{R}^{6n}\) is a generalized velocity vector - \(J\in\mathbb{R}^{m\times6n}\) is a constraint Jacobian matrix - \(f\in\mathbb{R}^{6n}\) is a generalized external force vector - \(\lambda^+\in\mathbb{R}^m\) is an unknown constraint impulse vector 2. **Constraint velocity equation**: \[ Jv^+ + C\lambda^+ + h^{-1}\phi = Jv \] where: - \(C\in\mathbb{R}^{m\times m}\) is a compliance matrix (constraint force mixing) - \(\phi\in\mathbb{R}^m\) is a position - level constraint violation vector 3. **Linear system**: \[ \begin{bmatrix} M&-J^T\\ J&C \end{bmatrix} \begin{bmatrix} v^+\\ \lambda^+ \end{bmatrix} = \begin{bmatrix} hv + J^T\lambda^+\\ Jv - h^{-1}\phi \end{bmatrix} \]