05-10-2014 09:12 PM
Good evening,
I've got an array of time and 9 acceleration values (in columns). I'm trying to integrate the array to yield velocity, but for some reason (and I'm assuming the hour is contributing here), it's not working to my expectations.
A relevant snippet of the code is attached. Can someone with fresh eyes tell me where I've gone astray?
Thanks!
05-10-2014 09:27 PM
Had a fresh cup of coffee, and found what I was overlooking. Thanks for taking a look at the problem!
05-11-2014 09:32 AM
From the looks of your code it appears that you would do well to spend some time with the Getting Started with LabVIEW tutorials.
-The use of stacked sequence structures is discouraged because it obscures code, is difficult to modify or extend, and often results in wires running backwards.
-Similarly local variables should not be used to pass data around - use wires. Locals are prone to race conditions, generate extra copies of the data, and are slower than wires.
-Use autoindexing to get the data from your array. You code will be substantially simplified.
There are Integration VIs in the Mathematics >> Integration & Differentiation palette which may be helpful. I am not sure these are in the Student Edition, but I think they may be.
Lynn