Optimization of damping positions in a mechanical system