EEG Inverse Problem & Source Localization Studio

Electrophysiology · Underdetermined Ill-Posed Inverses, Minimum Norm Estimation (MNE), Depth Weighting & LCMV Beamforming

Ground Truth Dipole (Click to place)
Estimated Current Density |Ĵ|
Scalp Electrodes (10-20)
Localization Error
--
Peak to Nearest True Source
Point-Spread (PSF FWHM)
--
Spatial Dispersion
Goodness of Fit (R2)
--
Scalp Field Explained
Tikhonov Regularizer (λ) 0.32
Under-reg (Noise spikes) Over-reg (Over-smoothed)
λ is relative: λ2 is multiplied by the mean eigenvalue of the leadfield Gram matrix (trace/M), so λ = 1 regularizes as strongly as the average signal the leadfield passes.
Scalp Sensor Noise (SNR) 15 dB
Ground Truth Sources 1 Dipole
Preset Dipole Locations:
Interactive Guidance:

Click anywhere on the gray cortical mantle to position the active dipole. Watch how unweighted MNE pulls a deep source up toward the superficial electrodes. Depth-Weighted MNE moves much of the estimate back down, but here its peak still sits in the superficial tier, so the localization error barely changes. The LCMV beamformer puts the peak on a single deep source, but fails with Two Sources, because they fire together.

Mathematical Formulations of Inverse Solvers

1. The Discrete Leadfield Matrix:

The forward problem discretizes the cortex into \(P = 48\) target locations, mapping dipole moments \(J \in \mathbb{R}^P\) to \(M = 16\) scalp electrode measurements: \(V = L J + \epsilon\). The leadfield column \(L_{:,p}\) represents the scalp potential pattern generated by a unit dipole at location \(p\). Because \(M \ll P\), the nullspace \(\text{null}(L)\) is non-empty: infinitely many silent source configurations produce exactly \(0\text{ V}\) on the scalp.

2. Minimum Norm Estimation (MNE):

MNE resolves ambiguity by penalizing total source energy via Tikhonov regularization:

\[ \hat{J}_{\text{MNE}} = \arg\min_J \left( ||V - LJ||_2^2 + \lambda^2 ||J||_2^2 \right) = L^T (L L^T + \lambda^2 I)^{-1} V \]
While numerically stable, leadfield magnitude falls off rapidly with distance from the scalp (\(||L_p|| \propto 1/r^2\)), inherently biasing unweighted MNE to place spurious activity in the most superficial cortical layers. On this page \(\lambda\) is relative, as in most MNE packages: \(\lambda^2\) is multiplied by \(\text{tr}(L L^T)/M\), the mean eigenvalue of \(L L^T\).

3. Depth-Weighted wMNE:

To counteract superficial bias, depth-weighting scales each source by its leadfield norm, so that \(W^{-1}\) gives weakly seen (deep) sources a larger prior variance:

\[ W = \text{diag}(||L_{:,p}||^{\gamma}) \quad (\gamma = 0.8) \]
The regularized solution becomes:
\[ \hat{J}_{\text{wMNE}} = W^{-1} L^T (L W^{-1} L^T + \lambda^2 I)^{-1} V \]
This shifts much of the estimate toward deep locations. In this model, with \(\gamma = 0.8\), a deep source's own location rises from about 15% to about 60% of the peak, but the peak itself still lands in the superficial tier. Stronger weighting moves deep peaks down but starts to push superficial sources too deep, so no single \(\gamma\) is right everywhere.

4. LCMV Spatial Beamforming:

The Linearly Constrained Minimum Variance beamformer constructs an adaptive spatial filter \(w_p\) for each location \(p\) that passes unit gain from \(p\) (\(w_p^T L_p = 1\)) while minimizing overall variance from all other brain regions:

\[ w_p = \frac{C_v^{-1} L_p}{L_p^T C_v^{-1} L_p} \quad \text{where } C_v = \text{Cov}(V) \]
The map shows each filter's output divided by its noise gain, \(w_p^T V / ||w_p||\) (the neural activity index). Without that step the unit-gain output grows wherever \(||L_p||\) is small, which biases the map toward deep locations. Beamformers work well when several uncorrelated sources are active. The two sources here fire together in a single snapshot, so they are perfectly correlated, the filter partly cancels them, and the peak lands deep, between them. R2 is not shown for LCMV, because each location is scanned with its own filter rather than fitted jointly.