DSPF_sp_lms2
[Adaptive filtering]

Collaboration diagram for DSPF_sp_lms2:


Detailed Description

float DSPF_sp_lms (const float *x, float *restrict h, const float *y_i, float *restrict y_o, const float ar, float error, const int nh, const int nx)


Function Documentation

float DSPF_sp_lms ( const float *  x,
float *restrict  h,
const float *  y_i,
float *restrict  y_o,
const float  ar,
float  error,
const int  nh,
const int  nx 
)

The DSPF_sp_lms implements an LMS adaptive filter. Given an actual input signal and a desired input signal, the filter produces an output signal, the final coefficient values, and returns the final output error signal.

Parameters:
x Pointer to input samples
h Pointer to the coefficient array
y_i Pointer to the desired output array
y_o Pointer to filtered output array
ar Adaptation rate
error Initial error
nh Number of coefficients
nx Number of output samples
Algorithm:
DSPF_sp_lms2_cn.c is the natural C equivalent of the optimized intrinsic C code without restrictions note that the intrinsic C code is optimized and restrictions may apply.
Assumptions:
nh must be a multiple of 4 and >= 4.
The coefficient array is assumed to be in reverse order; i.e., h(nh-1), h(nh-2), ..., h(0) will hold coefficients h0, h1, ..., hnh-1, repectively.
Implementation notes:
Endian Support: The code supports both big and little endian modes.
Interruptibility: The code is interruptible.


Copyright 2014, Texas Instruments Incorporated