31.5.16 mips_vec_sum_squares32
Description
Computes the sum of squared values of all elements of indata. The number of samples to be processed is given by the parameter N. The scale parameter specifies the amount of right shift applied to the final result.
Mathematically,
Include
dsplib_dsp.h
Prototype
int32
mips_vec_sum_squares32
(
int32 *indata,
int N,
int scale
);
Argument
indata: Input array with 32-bit fixed-point elements in Q31 format.
N: Number of samples.
scale: Scaling factor: divide the result by 2scale.
Return Value
Scaled result of the calculation in fractional Q31 format.
Remarks
- The pointer indata must be aligned on a 4-byte boundary.
- N must be larger than or equal to 4 and a multiple of 4.