ode event stopping without a zero crossing
Ältere Kommentare anzeigen
I'm having trouble with an ODE45 model I am building and the event function used to terminate the integration. The event function I am using detects a zero crossing (positive direction) to terminate the solver then another function modifies the ode and I'm feeding the end state from the first run into another ode45 call as the initial conditions (similar to ballode example except instead of modifying the initial conditions I am modifying ode).
The first termination occurs correctly but then I am getting a second termination during the subsequent run. The output reports the same event index (ie) as the first run. When I manually run the event function with the terminated state I am finding that the value of the flagged event is not zero.
How can the solver stop and report an event with an event value that is much less than zero?
Any thoughts?
1 Kommentar
Jason Kozmic
am 15 Nov. 2018
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Ordinary Differential Equations finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!