LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Regression Solver Error

Solved!
Go to solution

Hello community,

 

I would like to execute the regression program. How to make it work, using the equation generated linking with formula eval node. Then i would have a reference input value and calculate output value in front panel.

 

Thanks,

Zull miza

UTM 

0 Kudos
Message 1 of 8
(3,525 Views)
Setting aside issues like local variables and your cluster-to-nowhere, let's try to get this working first.  I personally do not use the evaluation VIs that often, but in this case you should be using Eval Single-Variable Scalar.vi instead of Eval Formula Node.vi.
0 Kudos
Message 2 of 8
(3,515 Views)

Hi,

 

 

Working out your VI, It has two problems,

 

1) You have not entered the input and output variables to EVAL formula node.

 

2) You cannot send the equation directly from  polynomial fit vi to eval formula vi as the terminology is not same.

 

I have attached the vi below, i hope it solves your problem,

 

reply if some error occurs,

 

Regards,

 

Shrek

0 Kudos
Message 3 of 8
(3,507 Views)

Hello, thanks for the reply. I have test the program and work perfectly. The program need to be re run every time to see the changes of the value.

Let say for example, if i would select value X = 5, at Polynomial Fit of 5 order, i would exactly receive the y value equal to 220, same as

enter data. But the problem now is the value of y is still the same and not changing if i 

change X=4, or X=3 and so on. I need to stop and run the program again if i want to get y value when 

x value is change to new value. Let say the X value is changing always, assume that x value is

temperature sensor which have an output in voltage, and y value is degree celcius reading. So, this cannot

be work if continuous X reading is taken. Any idea to improves the program? 

 

Thanks,

Zull Miza

UTM 

0 Kudos
Message 4 of 8
(3,488 Views)
Solution
Accepted by topic author suffyzull

Hi,

 

 

The main problem for that is the Eval formula node is not running continuously.

 

 

Take it outside the case structure as it is implementing only when the input data is changed and for only 1 time.

 

 

attached is the vi, for your reference,(it is not optimised as i have used local variable)

 

work on it.

 

Regards,

 

Shrek

Message 5 of 8
(3,481 Views)

Hello,

 

Thanks for the explanation and  now i understand more about this technique and also has work on it. It all work perfectly

now and i can manage my VI into proper way. Thanks a lot again shrekt. Have a nice weekend and celebrate Valentine's.

 

Regards,

Zull Miza

UTM 

0 Kudos
Message 6 of 8
(3,468 Views)

Hello suffyzull,

I am also interested in this topic, unfortunately I cannot open this via since I am using LV 8.5.

Would you like to attach a LV 8.5 version so I can see how this solution is working?

 

Thanks in advance,

 

0 Kudos
Message 7 of 8
(3,393 Views)
Yes i will do when i am available... now i am outstation and to convert I need to get to my workstation located at my office first, maybe other members may help if you need it urgently... sorry.
0 Kudos
Message 8 of 8
(3,357 Views)