endless loop with negative start_time

3 posts / 0 new
Last post
hanshell
Offline
Joined: 2015-10-07
endless loop with negative start_time

Hello,

In CS simulation a negative value of start_time results in endless loop in jmi_ode_solver.c  in function jmi_ode_solver_solve

My workaround line in 122 was helping:

static int jmi_ode_not_finished(jmi_real_t time, jmi_real_t final_time) {
return jmi_abs(time -final_time) > jmi_abs(JMI_ALMOST_EPS*final_time);
}

svn JModelica version 10113.

best regards

Johann

 

 

hanshell
Offline
Joined: 2015-10-07
endless loop with negative start_time - again

Hi - again,

I'm still aware that the priority of this reported bug is not so high. But somtimes it's useful to start a simulation at negative start_time and apply a disturbamce to the system at time zero.

my proposed solution works, but should be checked by experts.

Thanks in advance
Johann

 

chria
Offline
Joined: 2009-07-29
Hi Johann, Thanks for the

Hi Johann,

Thanks for the report! I've created a ticket for the problem https://trac.jmodelica.org/ticket/5538 and we will try to fix for the next release.

Best

/Christian

 

Login or register to post comments