A dynamic simplex approach for optimization of real-time distributed multi-body simulations