Next: Motor Controllers Up: Numerical Solution Previous: System Matrix Assembling and the

## Algorithm Outline and Discussion

An outline of our semi-implicit simulation algorithm is as follows:

Initial calculations at t=0:

1. Initialize , and .
2. From the connectivity of the mass-spring-damper model, initialize the skyline storage scheme: Calculate the dimension of from column heights and the index array MAX .

For each time step :

1. Calculate the system matrix and the effective load matrix as prescribed in Section .
2. Factorize , where is diagonal and is lower triangular.
3. Solve for the new velocities :
1. Solve for using forward-substitution.
2. Solve for using back-substitution. Note that since is diagonal, the computation of its inverse is trivial.
4. Update the nodal positions: .

We have verified experimentally that the semi-implicit algorithm is sufficiently stable for our simulation purposes. We use a time step of in our simulator (the stability limit is reached with a time step around ). Our algorithm is much more stable than an explicit Euler time integration implementation. Given the same numerical settings, experiments show that the largest time step allowed (before the system becomes unstable) when using our algorithm is typically 100 to 150 times larger than is possible when using the explicit method. On the other hand, our algorithm is simpler than implicit methods described by Bathe and Wilson Bathe76, such as the Houbolt method or the Newmark method. In particular, the approximations we use for (Eq. ) and (Eq. ) are simple and require only knowledge of the position matrix and the velocity matrix at time t while other methods (for example the Houbolt method) requires positions and velocities from several previous time steps. Furthermore, fully implicit methods require that the external load matrix in Eq. () be calculated implicitly as well, which would be difficult in our case.

Next: Motor Controllers Up: Numerical Solution Previous: System Matrix Assembling and the
 Xiaoyuan Tu January 1996