Commit 37f56ff2 authored by Nicolas Van der Noot's avatar Nicolas Van der Noot
Browse files

stop the simulation for dopri5

parent 79c17b0c
......@@ -252,6 +252,14 @@ static int dopcor (unsigned n, FcnEqDiff fcn, double x, double* y, double xend,
return -3;
}
// modif: stop the simulation if 'flag_stop' is 1
if (s->flag_stop)
{
xout = x;
hout = h;
return -4;
}
if ((x + 1.01*h - xend) * posneg > 0.0)
{
h = xend - x;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment