LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Differential equation system to solve a BZ reaction model

Solved!
Go to solution

Hi again,

Thank you very much for answering all my questions.

Indeed, I think I need to choose a stiff ODEsolver.In the Labview help, it is claimed tht BDF is useful fore moderately stiff problems and I am not sure if my system can fall in this case.

For your last question, I would say that I am just stating with a periodic model that is straighforward to analyse and obviously, changing the initial conditions will change the periodicity parameters which is good but I am planning for more complicated problem which is the the use of a chaotic model that can perturbedto go back to the periodic behaviour or a different chaotic behaviour.

I tried a different periodic model that is more complicated but I got an error from labview stating that (Analysis:  Nonpositive step rate.).

Unfortunately I could not find a similar error in the forum.

Thanks,
Zied

0 Kudos
Message 11 of 14
(1,382 Views)

Nonpositive step rate means you either have a negative or 0 step rate in your "simulation parameters" cluster, or the solver itself ends up needing a nonpositive step rate to solve the problem, which is not possible. This may indicate you need to use an alternate solver. In terms of what to use, I really can't say as I lack the knowledge of your systems to make such a call. In any case, for these sorts of numerical integration problems where stiffness is a real factor, I'd say you're better off using any of the great methods in the scipy.ode.integrate Python module, or if you can afford it, the relevant Matlab code.

 

Your VI does not have "Set current value as Default" for the controls so I can't really know what settings you're using. If you want to share those, right click the cluster, do Data Operations - > Make Current Value Default, then save the VI. Do this in all controls you have so that I can exactly reproduce the error you're experiencing.

Message 12 of 14
(1,379 Views)

Hi again,

I found in the litterature that Gear algorithm works well with my system and in Labview helper it is one of the implemented ODE solver that works well with stiffness. I couldn't find it in the list of your VI but I found it in the list of solvers when I go the configuration of the simulation loop  as indicated in the VI attached. To be honest your VI is more straighforward as I need to copy the ODE but the list of ODE is not complete. I can say the problem of the ODE solver is solvedwhen I use the Gear solver from the control and simulation loop but I found different problems:

 

1-The plot in 3D did not work as the conversion from waverform to 1D array keeps only the last value from the loop and there is no way to take the whole array.

 

2- In the attached VI I expected to get a plot like figure 3a after the integration. I am trying to verify again the parameters but I am not sure if I missed something in the configuration of the ODE

http://www.nrcresearchpress.com/doi/pdfplus/10.1139/v00-166

 

Cheers,

Zied

0 Kudos
Message 13 of 14
(1,363 Views)

I found an answer to my first question. I need just the function "collector" in the simulation loop.

Cheers,

Zied

0 Kudos
Message 14 of 14
(1,349 Views)