11-09-2018 11:07 AM
How to multiply first line of Array A with last column of Array B element by element?Both Arrays are 2D square arrays.
Solved! Go to Solution.
11-09-2018 11:09 AM
Hi Marius, what do you mean by multiply? Would the number of elements of the arrays being multiplied be the same? Do you want dot product or element by element? Why are you only multiplying those two, are you sure you don't want to explore some of the matrix math operations? Have you used the index array function before?
11-09-2018 11:17 AM
I just started college, and i had a labview course last week which i missed. And the teacher gave us some problems to solve. And this one i can't.Well The thing is that there are 2 Matrices, A and B(they are square matrices- 5 x 5 in my case). And I need to multiply first line of A matrix with the last column of B matrix, element by element.
11-09-2018 11:20 AM
Just use "index array" and "multiply". Use the first index of index array to pull off a row, or the second to pull of a column. If you can't find those functions, type in ctrl + space and the quick drop will pop up, you can just type in the functions you want.
I must warn you though, LabVIEW is not much fun when you just go in blind without learning how it works. You should try to go through some of the free training available listed on the front page of the forums, or the "Unofficial rules and guidelines".
11-09-2018 11:45 AM
Could you take a look at this, please?
11-09-2018 11:49 AM
Close, but LabVIEW uses index 0, so you are multiply the 2nd row (empty) by the 6th column (empty) and getting (empty).
11-09-2018 11:54 AM
Thanks, it's working now. I appreciate the help 🙂
11-09-2018 11:55 AM
To get the first row, you don't need to wire any indices. (as as has been mentioned, the index would be zero)
To get the last column, the index depends on the number of columns, so you should do it based on the array size and not use a constant. You can get the number of columns directly using matrix size. The desired index would be "number of columns -1"