yes i have seen the bouncing ball exemple and i knew my problem, it is the initialisation of initial conditions. because at each event we have such a new funtion.
For that i won't use the methode of eventlocator, but i will creat some function that give me the instant that the event occurs (in my exemple x=4 ou x=0) and use this instant in the initial condition of my functions.
i hae defined function with tin and tend as arguments and used Dynamic refresh to reinitilize function at each changement.
my problem is how to do the first initialization of the time.
i have joined my code for more explanations.
and for any suggestions
Attachment: modified with t.nb, URL: ,