1 minute read

In this post, I'll discuss the acoustic echo issue in communication systems and how the LMS filter can be used for Acoustic Echo Cancellation.

1. Problem Setup

In an acoustic echo cancellation system:

  • A far-end signal (e.g., voice from a remote speaker) is played through a loudspeaker.
  • Some portion of this sound reflects off surfaces and leaks back into the microphone as an echo.
  • The goal is to remove this echo from the microphone signal while preserving the near-end speech.

2. LMS Adaptive Filtering Approach

An adaptive filter attempts to model the echo path and subtract the estimated echo from the microphone signal.

Definitions:

  • \( x(n) \) → Far-end signal (input to the loudspeaker)
  • \( d(n) \) → Microphone signal (contains both near-end speech + echo)
  • \( y(n) \) → Adaptive filter output (estimated echo)
  • \( e(n) = d(n) - y(n) \) → Error signal (ideally just the near-end speech)
AEC - Acoustic Echo Cancellation

The LMS filter updates its weights to minimize the squared error:

\[ w(n+1) = w(n) + \mu e(n) x(n) \]

Where:

  • \( w(n) \) → Adaptive filter coefficients
  • \( \mu \) → Step size (controls convergence speed vs. stability)
  • \( e(n) \) → Error signal
  • \( x(n) \) → Input signal

Updated: