01-28-2006 01:23 AM
01-28-2006 01:26 AM
I'm sorry
I didn't put the file for this.
01-28-2006 01:32 AM
Hi Hiyang,
sorry, could not understand your query.
are you adding all individual elements of a 2D array to get a single sum?
If it is so, here is a simpler method to do it, use add array elements function in numerics palette( look at attached VI)
or, are you adding two seperate 2d arrays?? again use addition function for acheiving it (as shown in the same VI)
Regards
Dev
01-28-2006 01:40 AM
Ok, looked at ur attached VI
You are not getting any output because, you are adding an array with an empty/blank array
First, initialise an array of zeroes of required size and pass it to shift register, Initialise your other array which u are adding inside the loop also of similiar dimension, and later, keep changing its elements
Do as shown in modification of your attached VI
Regards
Dev
01-28-2006 12:50 PM
Thank you Dev.
It does work well when I follow your suggestion.
Again thank you Dev.
03-03-2012 07:34 AM
Hi!
How You make then the output array in both cases ... my way is not working .... ![]()
Thanks!
03-03-2012 06:37 PM
You should have create a new message thread for your question instead of posting into a 6 year old one.
The problem is you are using insert into array, and doing it on an empty array, after the first iteration, you are trying to insert into row 1 of an empty array, but row 0 doesn't exist, so you wind up with an empty array.
If you are trying to build up an array of results, you need to keep that array in a shift register instead of starting with an empty array on each iteration. You should also use build array instead of Insert into Array. (Insert into Array is almost always incorrectly used. Build array is the correct function to use about 99% of the time.)
03-05-2012 04:27 PM
Hi!
Thank You for the reply... could You please send me solution in VI file ....
I could not completely understand your solution ![]()
This is part of the solution, which is dedicated for the arbitrary step function into Control and simulation ....
Thank You !