05-29-2022 02:13 PM
Hello,
In my VI I want to solve a differential equantions.
My VI is based on examples found in LabView help.
After I started the VI I reciced an error message "Error -2334 occurred at an unidentified location: Control Design and Simulation: An overflow occurred in the ODE solver."
Equation (4.65) is in my VI equation 5 and equation (4.67) is in my VI equation 6.
Equation 9 is in attachments.
I tried to find in help and on the internet what is causing this error, but without any results.
I try to solve a very difficult differential equantion, so maybe it could cause an error.
I am using an Labview 2015.
Thank you very much for help
Best regards
Piotr
05-29-2022 03:44 PM - edited 05-29-2022 04:00 PM
You need to get rid of ALL your local variables. They are completely misguided here.
LabVIEW is a parallel language and all your code islands will execute in parallel, meaning that most local variables will get read way before the terminals gets written, causing glaring race conditions and unpredictable outcome.
This is not text programming. In LabVIEW, the wire is the variable. (Local variables just provide alternative access to the terminals of front panel objects).
(... and why would you hide terminals behind "index array" primitives?? Are you intentionally trying to obfuscate your code even more??? Why is your toplevel caller not part of the project? Why does the toplevel have a greedy while loop?)
05-30-2022 11:31 AM
Thank you very much for help.
I'm learning how to program in Labview now.
This code is an adaptation of two examples that I found in "Find Examples" section.
I simply forgot to add a top caller VI to the project, my mistake.
Best regards
Piotr
05-31-2022 12:50 PM
Hello
After delating all the local variables (i replaced it with a created subVIs and 3 clusters to transfer data) and error still shows.
Do you have any idea how to fix it?
Best regards
Piotr
05-31-2022 01:04 PM - edited 05-31-2022 01:05 PM
I doubt it is reasonable that all inputs are zero. As a first step, can you fill all your controls of the toplevel with reasonable values and make them default before saving. We cannot possibly guess what reasonable values are.
It is also very distracting if you still hide the array terminals behind the index array nodes. There is absolutely no reason for that.
Also please use the standard connection panes. It would be significantly less wiring if your subVIs would output arrays instead of hordes of scalars.
05-31-2022 02:01 PM
All the equations describes a specific type of pendulum, so if all imput data are 0, the function should return 0.
Even if I chechs how function VI works - all the calculations are correct. I think the problem is in the solver, but I don't know how to correct it.
05-31-2022 02:05 PM
The solver is a plain VI that you can inspect in detail to see what's happening inside.