## 5.17. Bouncing ball -- discontinuity example

Most of classical simulators cannot cope with the discontinuity of the system's behavior when it occurs during the simulation. This means that systems that have response that is not differentiable cannot be simulated with such simulators. Primary reason is the way in which a simulator works: for finding the solution in one time point it needs solution(s) in one (or more) past point(s), depending on the integration method.

Excellent, while simple example of discontinuity is bouncing ball. Discontinuity occurs when the ball reaches ground. The sign of velocity is changed and the ball rebounds. It is of crucial importance to extract the "discontinuity" instant, so that the simulator can react by calculating new initial conditions.

The idealized ball’s trajectory is described by the equation: where g is the gravity constant and ? the air damping coefficient. Fig. 5.49:
Simulation results for bouncing ball

Discontinuity is determined when x falls down to zero. The results of the simulation are given in Fig 5.49. Lost of energy due to the impact is not considered in this example.