ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Formula node, keep getting errors

Solved!
Go to solution

I am trying to integrate a formula node into an array, I keep getting errors and don't know why. Any ideas?

Capture4.PNG

Thanks!

0 Kudos
Message 1 of 3
(3,548 Views)

X is a 2D array but you're trying to index it as a 1D array. You're also missing a semi-colon at the end of that statement....and y needs to be indexed since you want a 1D out.

Message 2 of 3
(3,544 Views)
Solution
Accepted by sofiakyle

That is a better attempt.

 

The problem is that you only defined your output y array to be a 1-D array.  And your math on the input array is also acting like it is a 1-D array.

 

See the attached modification.

 

But your formula is simple enough that doing it in real LabVIEW code is easier and you don't have to deal with syntax problems of the formula node.

 

(Note, since I don't have your data, I couldn't run this, so it is possible there are errors.)

Message 3 of 3
(3,539 Views)