Showing results for 
Search instead for 
Did you mean: 

for loop in formula node not working

Go to solution


I;m trying to use for loop in formula node but it is not working. I want the output (y1) produce value in certain range (a and d, of course a is smaller than d). I' not using primitive labview since a and d are keep changing (both are variables). I did try to put "return 0;" after equation y1 but the error popup.

The issue for loop not working since it gives last value ( i mean 'd') . It not start with a value (initial).

Please help me how to solve this..


Pls ignore other variables that not used in equation. Thank you!! very much

0 Kudos
Message 1 of 3
Accepted by topic author rina

Your code is working.





But why you use loop?
You get last value, so you can get it in one step with correct x;

Also why you say that can't use primitives?
If you use wires instead of terminals or local variables states of values keep constant.


y1, y1_2, y1 3 is the same values calculated different ways.




0 Kudos
Message 2 of 3

many thanks!! after lil bit changes, it works for my case..

0 Kudos
Message 3 of 3