Hi, I am attempting to use the Linear Algebra Matrix Multiply function in Labview 2013. I am attempting to multiply a 288x576 matrix by a 576x1 vector. The matrix is loaded from a file on the host computer and sent via a DMA FIFO to the target, and the vector is (for now) just filled with constants. In the future, the vector will be populated by data from an I/O module attached to the FPGA unit.
I am wondering if anyone knows about/has any experience with using the Linear Algebra Matrix Multiply function to multiply a constant 2D matrix by a vector.
I have attached a screenshot of my current attempt at a solution to this post. Because FPGA only supports 1D arrays, I have the matrix coming into my timed loop as a 1D array with a length of 288 * 576 = 165,888. I then take the first 576 elements using the Array Subset function and feed them into the Matrix Multiply function. The next iteration takes the second 576 elements, then the third, etc. Each of these sets corresponds to a row of my matrix, so I am effectively feeding the matrix in one row at a time, which is the type of input I have the Matrix Multiply function configured to accept (see the screenshot of the dialog attached).
The issue with my current solution is that the Array Subset function does not return a fixed-size array unless the "index" input is wired to a constant (http://zone.ni.com/reference/en-XX/help/371599H-01/lvfpgahelp/returning_fixedsize_arrays/). For my application, the index at which I take the subset needs to change, and so the type of the wire coming out is labeled as "bounded size" instead of "fixed size." The code I attached a screenshot of performs as I would like it to when I run it on the development computer, however when attempting to compile to the FPGA I get an error about the small bit of wire (circled in the picture) that is "bounded size" instead of "fixed size."
If anyone knows any alternative methods to perform the type of matrix multiplication I described above, or a fix for the problem I am having with my code, it would be greatly appreciated.