Question: dsolve, numeric: events

I have a non-linear deq of 2nd order which I want to solve numerically. The integration should stop if the integrated variable exceeds a certain value, i.e. phi(t)>phi_ end or equivalently phi(t)-phi_end>0. Maple doesn't accept this type of event and the test phi(t)=phi_end doesn't catch (obviously). How to work around?

Please Wait...