12-26-2006 04:12 AM - edited 12-26-2006 04:12 AM
Message Edited by amose on 12-26-2006 04:13 AM
12-26-2006 04:50 AM
If you want to do a real interpolation (make the new elements have different values than the existing ones), then you can use the interpolation function and do something like this:
If you just want to pad out the array, you can modify the VI posted here to work with a 1D array.
To learn more about LabVIEW, I suggest you try searching this site and google for LabVIEW tutorials. Here, here, here, here and here are a few you can start with and here are some tutorial videos. You can also contact your local NI office and join one of their courses.
In addition, I suggest you read the LabVIEW style guide and the LabVIEW user manual (Help>>Search the LabVIEW Bookshelf).
12-26-2006 01:59 PM - edited 12-26-2006 01:59 PM
If you have LabVIEW 8.0 or later, there is "interpolate 1D" which is very flexible (e.g. x-values in input and output don't need to be evenly spaced, large choice of interpolations (linear, spline, etc.)).
An implementation for a simple linear interpolation is shown here, modify as needed.
Check the online help for more details and options.
Message Edited by altenbach on 12-26-2006 12:00 PM
12-26-2006 03:19 PM
Please tell me that you do not have controls set to appear as icons on the diagram.
altenbach actually posted this:
![]()
12-26-2006 04:07 PM
@tst wrote:
Please tell me that you do not have controls set to appear as icons on the diagram.
I am almost too embarrased to admit that I haven not really touched the LabVIEW options since installing on a new PC a few weeks ago. So, yes, they're set to show as icons at the moment, the default behavior. 😉
For illustrative purposes, such as in a code image as above, it probably adds a little bit of clarity to the diagram picture. 🙂
(In my own code, I rarely use icons).