I am trying to use an events function to in my ODE function. However, when I run the attached file 'ode_events_error.m' I am getting the following error message:
??? Error using ==> funfun\private\odezero at 50 odezero: an event disappeared (internal error) Error in ==> ode45 at 419 [te,ye,ie,valt,stop] = ... Error in ==> mycode at 10 [r,state,re,statee,ie] = ode45(@(r,state)prbode(r,state,tauc),rspan,stateinit,options);
Best Answer