Jump to content

Component: Math (DSP Operators)

From Flowcode Help
Revision as of 14:37, 13 July 2026 by SteveT (talk | contribs) (Text replacement - "style="background-color:#EAE1EA;"" to "class="mtx-class-propfolder"")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Author Matrix Ltd
Version 1.2
Category DSP Operators


Math component

Component to combine together two DSP buffers into one an index at a time. Functions include: Add, Average, Difference, Max, Min, Subtract

Component Source Code

Please click here to download the component source project: FC_Comp_Source_DSP_Math.fcfx

Please click here to view the component source code (Beta): FC_Comp_Source_DSP_Math.fcfx

Detailed description

No detailed description exists yet for this component

Examples

Here is a example file which generates a sine wave and a triangle wave and then uses the DSP sum component to merge together the two signals. DSPSum Here is the kind of waveform you can expect to see using the scope window when adding the two signals together.


Here is the kind of waveform you can expect to see using the scope window when subtracting the two readings.


Here is the kind of waveform you can expect to see using the scope window when taking the maximum of the two signals.


Here is the kind of waveform you can expect to see using the scope window when taking the minimum of the two signals.


Here is the kind of waveform you can expect to see using the scope window when taking the average between the two signals.


Here is the kind of waveform you can expect to see using the scope window when taking the difference between the two signals.








Macro reference

Calculate

Calculate
Performs a single calculation on the two input buffers and provides a result into the output buffer 
- VOID Return


CalculateArray

CalculateArray
Performs a single calculation on the two input buffers and provides a result into the output buffer 
- VOID Return


Property reference

Properties
Connect To A
DSP component with output buffer to collect our data from. 
Connect To B
DSP component with output buffer to collect our data from. 
Buffer Size
Number of individual elements the buffer can store, default 1. 
Buffer Type
Sets the buffer data type. 
Direction
Sets the data direction flow of the component 
Calculation
Sum Type
Defines the type of calculation performed on the two input buffers to obtain the output value. Data shown in brackets indicates operation  ? = a decision followed by the true value and then the false value seperated with a colon.