LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Looking for efficient way to get sum of all elements of large 1D array (FPGA)

Is there a function that would let me quickly get the sum of all elements in a 1D array? I could iterate through all of the elements, but that would be both inefficient to code and to execute.  Is there a more convenient way to do so?

 

I need to implement this on an FPGA, BTW.

0 Kudos
Message 1 of 6
(1,608 Views)

Use Index Array and Compound Add?

Might not be user friendly if you have many elements but you cannot have an array of dynamic size in FPGA anyway.

ZYOng_0-1691772205139.png

 

-------------------------------------------------------
Applications Engineer | TME Systems
0 Kudos
Message 2 of 6
(1,593 Views)

Try this below.

GRCK5000_0-1691772603920.png

GRCK5000_0-1691772652420.png

 

 

 

 

#GodIsGood

 

 

 

0 Kudos
Message 3 of 6
(1,588 Views)

I was hoping to try that but I couldn't find the Add Array Elements VI anywhere.

0 Kudos
Message 4 of 6
(1,577 Views)

Add them as they are being collected or stored to the array.  This is the 'FPGA' way of doing things.  The 'software' way is to collect the data and then sum them. (I am generalizing)


Certified LabVIEW Architect, Certified Professional Instructor
ALE Consultants

Introduction to LabVIEW FPGA for RF, Radar, and Electronic Warfare Applications
Message 5 of 6
(1,571 Views)

@GRCK5000 wrote:

Try this below.


You probably missed the (FPGA) term in the subject. 😄

 

There is no such function, either in the FPGA numeric or in the FPGA array palette.

0 Kudos
Message 6 of 6
(1,546 Views)