Scene 01 / 04

First-Order: Spatial Covariance Polarity

For an M-channel EEG window of N samples, the spatial covariance matrix Σ = (1/N)XXT is a point on the SPD(M) manifold. Its eigendecomposition Σ = QΛQT describes the principal axes of neural activity. The A-Gate circuit measures this point and produces a polarity observable.

P1(Σ) = sgn(⟨Z⟩) ∈ {−1, +1}
First-order invariant: sign of the expectation value from 1024 shots

The key empirical finding: P1 is invariant within each patient across seizures and across window sizes from 1s to 30s. The same patient always inverts (or doesn’t). Drag the slider to see polarity stability across window durations.

Drag to reveal window sizes 1.0s → 20.0s
1s 15s 30s
Within a given basis and channel configuration, each patient shows a stable polarity direction with varying strength. Polarity is not binary — it is a continuous geometric signal whose magnitude depends on circuit depth and coherence budget. Hardware results show AUC ranging from 0.28 to 0.68 across patients.
Scene 02 / 04

Second-Order: Cross-Frequency Coupling

Bandpass-filter the EEG into frequency bands f. The cross-frequency PLV between bands f1 and f2 measures how the phase of one band relates to the phase of another — a form of phase-amplitude or phase-phase coupling.

PLVf1,f2(i,j) = |⟨ei(φf1,i(t) − φf2,j(t))t|
Cross-frequency PLV between channels i and j across bands f1 and f2

Each (f1, f2) pair produces an M×M PLV matrix — still SPD after regularization. Each has its own polarity: P2f1,f2) = sgn(⟨Z⟩f1,f2). Click a frequency pair to see the predicted PLV matrix and polarity.

θ × α
4–8 × 8–13 Hz
P₂ = ?
θ × β
4–8 × 13–30 Hz
P₂ = ?
α × β
8–13 × 13–30 Hz
P₂ = ?
θ × γ
4–8 × 30–70 Hz
P₂ = ?
α × γ
8–13 × 30–70 Hz
P₂ = ?
β × γ
13–30 × 30–70 Hz
P₂ = ?
θ × θ
4–13 Hz (1st order)
P₁ = confirmed
Full grid
all band pairs
N(N−1)/2

θ × α cross-frequency PLV matrix. Does polarity sign persist, differ, or vanish across frequency couplings?

PREDICTED — Testable: run the A-Gate on cross-frequency PLV matrices for all 22 patients. If polarity is a genuine geometric property, cross-frequency polarity should show patient-specific structure correlated with P1.
Scene 03 / 04

Third-Order: Manifold Trajectory Geometry

The sequence of SPD matrices across consecutive windows {Σ(t1), Σ(t2), …, Σ(tk)} traces a curve on SPD(M). The geometric properties of this trajectory — velocity, curvature, acceleration — are higher-order invariants.

v(t) = dBures(Σ(t), Σ(t+δ)) / δ
κ(t) from discrete Frenet frame on SPD(M)
dBures = [tr(Σ1) + tr(Σ2) − 2tr(Σ1½ Σ2 Σ1½)½]½

Interictal trajectory: slow, smooth movement on the SPD manifold. The neural field is near equilibrium.

PREDICTED — Ictal trajectories should have higher curvature and velocity than interictal. The neural field moves faster on the manifold during seizure. Requires multi-window temporal analysis to test.
Scene 04 / 04

The Hierarchy as Testable Predictions

QNFM identifies the class of invariants. Polarity is confirmed as the first member. Higher-order members are predictions with specific falsification criteria.

Order Observable Status Falsification Criterion
1st P1 = sgn(⟨Z⟩) from single-band PLV CONFIRMED Would be falsified by within-patient polarity inconsistency
2nd P2 = sgn(⟨Z⟩f1,f2) from cross-frequency PLV PREDICTED Test: run A-Gate on cross-frequency PLV matrices for all 22 patients
3rd κ(t), v(t) from SPD trajectory PREDICTED Test: compare trajectory curvature distributions ictal vs interictal

External validation: Barachant (Melbourne 2016) and Hills (2014) independently found that cross-frequency coherence matrices and auto-correlation matrices with log-spaced delays carry seizure-discriminative information — empirical evidence that these higher-order geometric objects are information-bearing.

Within each order, the A-Gate is a fixed geometric probe — the same circuit applied to every SPD element at that level. This per-order rigidity is what makes each invariant testable: any signal must come from the geometry, not from circuit tuning. Higher-order invariants may require a different gate architecture to remain stable.
← A-Gate Architecture Math Index ↑ QNFM Hierarchy →