EEG and MEG Fundamentals: Brain Imaging Principles
Posted on Jul 23, 2025 in Technology
EEG and MEG Hardware & Sensors
- EEG: Measures electrical potential (voltage) differences on the scalp, originating from secondary/volume currents in the extracellular space. Uses electrodes (e.g., Ag/AgCl) that convert ionic flow to electrical current. Requires a reference electrode. Signal significantly smeared/distorted by low conductivity skull. Sensitive to both radial and tangential sources. Standardized placement (e.g., 10-20 system) ensures replicability.
- MEG: Measures magnetic fields outside the head, generated by primary/intraneuronal currents (mainly in dendrites). Traditionally uses SQUIDs. Magnetic fields are not significantly distorted by skull/scalp, offering potentially better spatial localization for tangential sources. Primarily sensitive to tangential sources; largely blind to radial sources in a spherical model. Requires extensive magnetic shielding (MSR).
- SQUID (Superconducting Quantum Interference Device): The highly sensitive detector in traditional MEG. Works via quantum effects (electron pair tunneling across Josephson junctions) in superconductors, making it extremely sensitive to tiny magnetic flux changes. Requires cryogenic cooling (liquid helium).
- MEG Pick-up Coils: Detect the brain’s weak magnetic fields.
- Magnetometer: Single coil, measures absolute field perpendicular to coil. Most sensitive to all sources/noise.
- Gradiometer (Axial/Planar): Measures spatial gradient (difference) of the magnetic field. Reduces noise from distant sources. Axial measures gradient radially; Planar measures gradient tangentially along the scalp.
- OPM (Optically Pumped Magnetometer): Newer MEG sensor technology. Does not require cooling. Uses laser interactions with polarized atomic vapor (e.g., Rubidium) to measure magnetic fields. Key advantage: allows sensors to be placed directly on the scalp (closer proximity, higher potential SNR) and permits subject movement (wearable MEG).
Signal Origins and EEG vs. MEG
- Primary Signal Source: Postsynaptic Potentials (PSPs) in the dendrites of large populations of synchronously active pyramidal neurons. Their longer duration and synchronized activity summate effectively compared to brief Action Potentials (APs).
- Primary Current: Flow inside neurons (dendrites/soma). Directly generates the MEG signal via Biot-Savart Law (right-hand rule).
- Secondary Current: Passive return flow outside neurons (extracellular space/volume conductor). Generates the EEG signal (Ohm’s Law).
- Key EEG vs. MEG Differences Summary:
- Origin: EEG from secondary/volume currents; MEG from primary/intraneuronal currents.
- Distortion: EEG high (skull); MEG low.
- Sensitivity: EEG sees radial and tangential; MEG mainly tangential.
- Visibility: MEG “sees” activity EEG might miss (tangential in sulci), EEG “sees” activity MEG might miss (radial in gyri). Complementary techniques.
Noise, Artifacts, and Cleaning
- Noise: Unwanted signals. Environmental (Earth’s field, power lines, equipment – requires MSR for MEG), Instrument (thermal noise in electronics).
- Artifacts: Biological signals not of interest. Ocular (blinks/movements), Cardiac (ECG/MCG – R wave), Muscular (EMG – often high frequency), Head movement (especially for fixed MEG sensors).
- Cleaning Strategies:
- Hardware: MSR (passive shielding for MEG), Gradiometers (hardware noise cancellation for MEG), Active Shielding (coils cancel external fields).
- Software: Digital Filtering (band-pass, notch for 50/60Hz), Artifact Rejection (removing contaminated data segments), ICA (Independent Component Analysis) – powerful technique that statistically separates signals into components, often isolating artifacts (blinks, ECG) for removal.
Sampling, Quantization, Nyquist, and SNR
- ADC (Analog-to-Digital Conversion): Process of digitizing continuous signals.
- Sampling: Measuring amplitude at discrete time intervals (rate fs). Determines temporal resolution.
- Quantization: Representing amplitude with discrete levels (bit depth). Determines amplitude resolution and dynamic range.
- Nyquist Theorem and Aliasing: To accurately represent frequencies up to fm, must sample at fs > 2fm. Sampling below this rate causes aliasing (high frequencies masquerading as lower frequencies). Prevented using an analog anti-aliasing low-pass filter before ADC.
- SNR (Signal-to-Noise Ratio): Measure of signal strength relative to background noise. SNR = Psignal / Pnoise or 20 log10(RMSsignal / RMSnoise) in dB. Higher SNR is crucial. Primary method to improve SNR for evoked responses is signal averaging.
Time-Domain Averaging and ERP/ERFs
- Signal Averaging: Averaging M/EEG epochs time-locked to a repeated event. Improves SNR for phase-locked activity because the consistent signal sums constructively, while random noise averages towards zero. SNR improvement scales with √N (number of trials).
- ERP/ERF: The resulting averaged waveform (Event-Related Potential for EEG, Event-Related Field for MEG). Represents the average neural response that is strictly time- and phase-locked to the event.
- Models of Averaged Response:
- Additive: ERP/ERF is a new neural response added to background EEG.
- Phase Reset: ERP/ERF results from stimulus realigning the phase of ongoing oscillations across trials.
- Nomenclature: ERP/ERF components named by Polarity (P/N in EEG), typical Latency (e.g., P300 = positive peak around 300ms), or functional relevance (e.g., MMN).
Fourier Transform (FT, DFT, FFT)
- Fourier Transform: Mathematical tool to convert a signal from the time domain (amplitude vs. time) to the frequency domain (amplitude/power & phase vs. frequency). Reveals the frequency content of a signal.
- DFT/FFT: DFT is the FT adapted for discrete, finite digital signals. FFT is a very efficient algorithm to compute the DFT. Commonly used to calculate the power spectrum (power at each frequency).
Filtering Brain Signals
- Purpose: Modify frequency content – remove noise (e.g., 60Hz notch filter) or isolate bands of interest (e.g., alpha band-pass filter).
- Types: Low-pass, High-pass, Band-pass, Band-stop (Notch). Defined by their frequency response.
- Effects: Alters amplitude across frequencies. Can also introduce phase shifts (timing distortions). Zero-phase digital filters are often preferred for ERP/ERF analysis to preserve timing relationships.
Evoked vs. Induced Responses
- Evoked: Strictly phase-locked (and time-locked) to the event. Consistent waveform shape across trials. Captured by time-domain averaging (ERP/ERF). Often reflects early sensory processing.
- Induced: NOT phase-locked, but still time-locked in terms of power modulation. Represents changes (increase/decrease) in the power of ongoing oscillations. Averaged out in time-domain average. Requires time-frequency analysis (e.g., spectrograms, wavelets) to detect power changes over time. Often reflects later cognitive processing, event-related desynchronization (ERD).
Forward vs. Inverse Problem and Lead Field
- Inverse Problem: The fundamental challenge: Estimate brain source activity (Q) from external sensor data (B). It is ill-posed – infinitely many source solutions can explain the same sensor data. Requires adding mathematical/physiological constraints or assumptions.
- Forward Problem: Calculate the expected sensor data (B) for a known source configuration (Q) within a head model. Physics-based, well-posed (unique solution). A necessary step for solving the inverse problem.
- Lead Field (L): The result of the forward solution. A matrix that ‘maps’ activity from each possible source location/orientation to the pattern it would produce across all sensors. B = L * Q.
- Forward Solution Ingredients: Accurate sensor locations, realistic volume conductor model (head model accounting for tissue shapes/conductivities), definition of source space (where sources can be), and precise coregistration between sensor and anatomical (MRI) space.
Source Analysis Techniques
- 1. Dipole Fitting (Equivalent Current Dipole – ECD):
- Method: Assumes one or a few focal sources (dipoles). Iteratively finds best dipole parameters (location/orientation/strength) to match data, usually at one time point. Overdetermined system.
- Best for: Strong, focal activity with high SNR (epileptic spikes, early sensory ERPs).
- Limitations: Fails for distributed activity, sensitive to initial guess and number of dipoles specified.
- 2. Distributed Models (e.g., Minimum Norm Estimate – MNE):
- Method: Assumes many dipoles (e.g., across cortex). Finds the source distribution with minimum overall power (L2 norm) that fits the data. Underdetermined system. Variants (dSPM, sLORETA) reduce depth bias.
- Best for: Representing distributed activity patterns.
- Limitations: Spatially blurred solutions, inherent depth bias (basic MNE), solution is mathematically simplest, not necessarily most physiological.
- 3. Adaptive Beamforming (e.g., Linearly Constrained Minimum Variance – LCMV):
- Method: Creates spatial filters for each brain location (voxel) to pass signal from that location while suppressing others. Filter adapts based on data covariance. Estimates power voxel-by-voxel.
- Best for: Localizing induced (non-phase-locked) activity, potentially better spatial resolution than MNE if sources are uncorrelated.
- Limitations: Assumes sources are uncorrelated (performance degrades otherwise), requires good covariance estimate (needs sufficient data).