LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

constant arrays

Solved!
Go to solution
Highlighted

Hi

 

Using the build array function I put together 2 1d arrays (each 5 elements) and the output was expected as described in literature.   A 2d array was created with the same number of elements (5).

 

I then tried the same thing using a 1d array (5 elements, initialized with random numbers) and a constant array.  The constant array was build using the back panel 'constant array' icon.  I manually entered 5 numbers.  I connected both to the build array function and I ended up with a 2d 10 element array.  The first row had the 10 values from the constant array and then zeros.  The second row had 10 zeros and then the 1d array.  Why did this happen? (using labview 14)

 

Thanks for your help

 

pete

 

catinthehat_0-1594509003977.png

 

 

0 Kudos
Message 1 of 3
(220 Views)
Highlighted
Solution
Accepted by topic author catinthehat

Your array constant has 10 elements in it. The box in the top left is the index of the first visible element, so by having 5 you are the first element you are looking at is index 5 (the 6th element in the row)

 

expand the array constant and it will probably make more sense. 

Message 2 of 3
(208 Views)
Highlighted

Hi

 

Well that was an easy fix.  Kicking myself for that one.

 

Thanks so much!

 

Pete

 

0 Kudos
Message 3 of 3
(205 Views)