Mianzhi Wang

Ph.D. in Electrical Engineering

Bartlett Beamformer and MVDR Beamformer in the Browser


With the fast development of web technology, many complex algorithms can run directly in modern browsers. With some tinkering, it is possible to implement DOA estimation algorithms in JavaScript and create an interactive page to illustrate various DOA estimators. However, it turns that this is not an easy task. The lack of complex number support and complex matrix library makes it cumbersome to implement most of the existing DOA estimators in JavaScript. Based on my own JavaScript matrix library (which is still quite basic), I managed to get the conventional (Bartlett) beamformer and the MVDR (Capon) beamformer working in the browser. The power spectra formulas for the two beamformers are given below[1]:

PBartlett(θ)=aH(θ)R^a(θ),P_{Bartlett}(\theta) = \mathbf{a}^H(\theta) \hat{\mathbf{R}} \mathbf{a}(\theta),
(1)
PMVDR(θ)=1aH(θ)R^1a(θ).P_{MVDR}(\theta) = \frac{1}{\mathbf{a}^H(\theta) \hat{\mathbf{R}}^{-1} \mathbf{a}(\theta)}.
(2)

The resulting interactive figure is shown below (it even works on mobile devices), which is powered by Chart.js. The underlying array is a uniform linear array with half-wavelength inter-element spacing. The snapshots are generated according to the unconditional/stochastic model[2]. They are regenerated when any of the parameters changes. You can tinker with the sliders to see how the two pseudo-spectrum response as the parameters change.

0 dB
50
12
6
[-60°, 60°]


  1. H. L. Van Trees, Optimum array processing. New York: Wiley, 2002.

  2. P. Stoica and A. Nehorai, "Performance study of conditional and unconditional direction-of-arrival estimation," IEEE Transactions on Acoustics, Speech and Signal Processing, vol. 38, no. 10, pp. 1783–1795, Oct. 1990.