LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

binary matrix multiplication

Solved!
Go to solution

If you use booleans, why don't you use an boolean array.

booleanarray.PNG

---

UnCertified LabVIEW Student
Mistakes are for learning, that's why suggestions are always welcome!
0 Kudos
Message 11 of 40
(2,461 Views)

Hi,

 

I tried your solution but there is is 2 in there in the result

 

binary3.png

0 Kudos
Message 12 of 40
(2,453 Views)

Hi sumalama,

 

yes, you're working with DBL values and perform a cross product operation...

 

Please define your desired operation more carefully. What will be the expected result for a given input? Until now you always presented "unexpected results"...

 

- Please state clearly: do you want a plain element-by-element multiplication or do you want to perform a matrix cross product?

- Please provided an expected result (maybe along with some explanation of the math behind) for some example inputs!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 13 of 40
(2,445 Views)
Hi Sumalama,

Still uhaven't answered few questions
What do u mean by multiplicating?
can u put what values u should be getting for
0x0=?
0x1=?
1x0=?
1x1=?

and as someone already mentioned, OR is not meant for multiplication, AND is for multiplication.
Thanks
uday
0 Kudos
Message 14 of 40
(2,443 Views)

Hi,

 

I want simple binary multiplication(AND) between the binary bits inside the array(matrix). The expected result is a matrix with binary values inside it which is shown in the figure-

 

binary4.png

 

 

0 Kudos
Message 15 of 40
(2,425 Views)

Hi sumalama,

 

???

 

Your inputs are two arrays (8×3 and 3×6 "bits"), the result should be an array of 8×6 bits.

Which bits are multiplied in that "simple multiplication"?

 

Can you write the formula to calculate the upper left bit (index 0,0) of the resulting array? And additionally the formula for calculating the lower right bit (index 5,7)?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 16 of 40
(2,421 Views)

What do you mean? the array X has dimension with 8 rows and 3 column so its 8x3 array (or matrix), isn't it? and similarly goes for Y.

 

 

binary4.png

0 Kudos
Message 17 of 40
(2,411 Views)

what about values at 2x1 and 2x6???

Thanks
uday
0 Kudos
Message 18 of 40
(2,405 Views)

Hi,

 

Could anybody give me the solution to my problem. One thing is how do I get the boolean array? I cannot find it?

 

thanks

0 Kudos
Message 19 of 40
(2,378 Views)
U didn't answer the previous question of how do u get values for 2x1 element and 2x6 element in ur end result.

Coming to ur latest question-create array control and then add boolean control to it u'll get boolean array.
Thanks
uday
0 Kudos
Message 20 of 40
(2,374 Views)