What does In-Ear Noise Cancelling, Occlusion and Listening Effort conclude, in numbers, about “LMS and Filtered-x LMS: Where the Step-Size Bound 2/(L·P) Really Sits”?

Answer: Chapter 1 runs least-mean-squares and filtered-x least-mean-squares on synthetic noise and shows that the textbook step bound 2/(L·P) is too loose for Gaussian input: for 16 taps the exact bound is 0.1111, and the algorithm diverges once the phase error of its secondary-path model passes 90 degrees.

Scope of the numbers: Chapter 3 checks Bode's sensitivity integral numerically: the quiet side and the loud side of an illustrative feedback loop are each 32.9 dB·kHz. Chapter 5 prices cancellation with the Speech Intelligibility Index: one decibel at 250 Hz is worth only 0.00206 and one at 2000 Hz 0.00883, and in the illustrative scene cancellation lowers the playback level needed for equal intelligibility by 5.1 dB.

中文版

Data table

The numbers below are printed verbatim by the chapter's Python program and can be reproduced by running it. standard-library Python onlyprinted values that match the answer: 0.1111

bound 2/(L P)= 0.1250
bound 2/((L+2) P) = 0.1111
fastest Gaussian step 1/((L+2) P) = 0.0556
murho_G theoryrho_G runrho_B theoryrho_B run
0.02000.967200.965890.966400.96410
0.05560.944440.935220.938260.92360
0.10000.980000.980880.960000.95900
0.10800.993950.996860.970620.97037
0.11501.008051.012550.981600.98149
0.12201.023911.048380.994140.99414
0.13001.044201.069971.010401.01037
rho > 1 means the deviation grows: the filter diverges
Show the full program
# Chapter 1. p12: Where the step-size bound 0 < mu < 2/(L P) really sits.
# Model: noise-free LMS with L = 16 taps and white input of power P = 1.
# Exact mean-square factor per step (Gaussian input, isotropic case):
#   rho_G(mu) = 1 - 2 mu P + mu^2 P^2 (L + 2)  -> stable iff mu < 2/((L+2)P)
# For binary +-1 input x'x = L P exactly, so
#   rho_B(mu) = 1 - 2 mu P + mu^2 P^2 L       -> stable iff mu < 2/(L P)
# The run estimates the per-step factor from the slope of the log of the
# ensemble-mean deviation (24 runs, 1200 steps, fixed seed). Illustrative.
import math
import random

L, P = 16, 1.0
STEPS, RUNS = 1200, 24


def measured_rho(mu, gaussian, rng):
    acc = [0.0] * (STEPS + 1)
    for _ in range(RUNS):
        v = [rng.gauss(0.0, 1.0) for _ in range(L)]
        buf = [0.0] * L
        acc[0] += math.fsum(t * t for t in v)
        for k in range(1, STEPS + 1):
            if gaussian:
                xn = rng.gauss(0.0, math.sqrt(P))
            else:
                xn = math.sqrt(P) * rng.choice((-1.0, 1.0))
            buf.insert(0, xn)
            buf.pop()
            e = math.fsum(a * b for a, b in zip(v, buf))
            v = [a - mu * e * b for a, b in zip(v, buf)]
            acc[k] += math.fsum(t * t for t in v)
    lo, hi = acc[200], acc[STEPS]
    return math.exp((math.log(hi) - math.log(lo)) / (STEPS - 200))


if __name__ == "__main__":
    rng = random.Random(20261112)
    print("bound 2/(L P)     = {:.4f}".format(2 / (L * P)))
    print("bound 2/((L+2) P) = {:.4f}".format(2 / ((L + 2) * P)))
    print("fastest Gaussian step 1/((L+2) P) = {:.4f}".format(
        1 / ((L + 2) * P)))
    print("   mu     rho_G theory  rho_G run   rho_B theory  rho_B run")
    for mu in (0.02, 0.0556, 0.10, 0.108, 0.115, 0.122, 0.13):
        tg = 1 - 2 * mu * P + mu * mu * P * P * (L + 2)
        tb = 1 - 2 * mu * P + mu * mu * P * P * L
        rg = measured_rho(mu, True, rng)
        rb = measured_rho(mu, False, rng)
        print("{:>7.4f}  {:>11.5f}  {:>10.5f}  {:>12.5f}  {:>10.5f}".format(
            mu, tg, rg, tb, rb))
    print("rho > 1 means the deviation grows: the filter diverges")

Single source and citation

Fan, Y. (2026). LMS Adaptive Filtering in In-Ear Active Noise Cancellation, Occlusion-Effect Bone-Conduction Gain and SNR-Driven Cognitive Recovery (Version 1.0.0), Chapter 1: LMS and Filtered-x LMS: Where the Step-Size Bound 2/(L·P) Really Sits. 5D Library. DOI pending

DOI pending · monograph page goes live after publication · 5DL-B-164 · v1.0.0 · CC-BY-NC-ND-4.0

BibTeX
@book{fan2026164,
  author    = {Fan, Yafu},
  title     = {LMS Adaptive Filtering in In-Ear Active Noise Cancellation, Occlusion-Effect Bone-Conduction Gain and SNR-Driven Cognitive Recovery},
  year      = {2026},
  publisher = {5D Library},
  edition   = {1.0.0},
  note      = {DOI pending}
}

Other chapter answers in this book