Coordinate-Free BT Monitor for Neural ODEs
Implementation & benchmark of arXiv:2608.13931 — An intrinsic characterization of the Bogdanov-Takens normal-form coefficients and a mixed-volume obstruction to non-isolated degeneracies
Source paper: An intrinsic characterization of the Bogdanov-Takens normal-form coefficients and a mixed-volume obstruction to non-isolated degeneracies arXiv:2608.13931 ⓘ · analyzed Sep 1, 2026
AI-generated research hypothesis, automatically tested. Not peer-reviewed.
Idea description
Add a bifurcation-aware monitor or regularizer to a continuous-time recurrent model by evaluating the trace and determinant of its local state Jacobian along the Jacobian kernel direction. Near a nilpotent rank-one equilibrium, these quantities estimate the Bogdanov-Takens coefficients a and b, allowing training to avoid uncontrolled higher-order degeneracies or deliberately target a controlled phase transition in latent dynamics.
Formulas
Mathematical statement
Let F: R² → R² be the neural vector field, p an equilibrium satisfying F(p) = 0, and J = DF(p) a nonzero nilpotent rank-one matrix. Thus J² = 0, trace(J) = 0, determinant(J) = 0, and rank(J) = 1. Let q₀ be a nonzero kernel vector satisfying Jq₀ = 0. The paper identifies the Bogdanov-Takens coefficients as a = −(1/2) D_q₀ det(DF)(p) and b = D_q₀ trace(DF)(p), where D_q₀ h(p) = (d/dε)h(p + εq₀) evaluated at ε = 0. The ordinary BT point is nondegenerate when ab ≠ 0. Penalizing small absolute values of a and b prevents the two principal degeneracies. Because q₀ can be rescaled, normalize it to unit Euclidean norm before applying thresholds.
Implementation notes
Use a two-dimensional continuous-time latent RNN or neural ODE, ż = Fθ(z,u), and apply the monitor at equilibria encountered during training. For a high-dimensional model, first use a two-dimensional latent bottleneck; a later extension can project onto the two eigenvectors whose eigenvalues have smallest absolute real parts. For each training checkpoint, find p by Newton iteration or by minimizing ||Fθ(p,0)||² until it is below a tolerance δ. Compute J = DFθ(p,0) with automatic differentiation. Obtain q₀ as the right singular vector associated with the smallest singular value of J and normalize q₀. For a small finite-difference scale ε, evaluate J₊ = DFθ(p + εq₀,0) and J₋ = DFθ(p − εq₀,0). Estimate a = −0.5(det(J₊) − det(J₋))/(2ε) and b = (trace(J₊) − trace(J₋))/(2ε). Add the displayed penalty to the task loss, or initially log a and b without changing optimization. The paper supplies the invariant formulas; equilibrium locations, Jacobians, kernel vectors, and derivatives are computed numerically. Repeat for ε, ε/2, and ε/4 and extrapolate to check convergence. The first experiment should use a two-dimensional neural ODE on damped-oscillator trajectory prediction, comparing Adam with and without the penalty. Sweep a scalar gain multiplying one vector-field layer. The predicted signature is a sharp change when |a| or |b| crosses zero: near a = 0, local drift becomes higher order and escape or relaxation times increase; near b = 0, the quadratic coefficient remains nonzero but the mixed u-v term disappears. The estimated zero-crossing should agree within 20% across finite-difference scales, and regularization should reduce the fraction of checkpoints with |ab| below a fixed threshold.
Verification
Stage 1 · Toy mechanism gate: Passed ✓
Stage 2 · Mechanism transferred to benchmark: Not reproduced ✗
Stage 2 · Practical benchmark result: No measurable effect
Methodology: 8 paired seeds, permutation test (p<0.05) against a learning-rate-tuned baseline. How verification works
Stage 1 — Mechanism check agent confidence 8/10
Built a coordinate-free BT monitor using automatic Jacobians, the smallest right-singular-vector kernel direction, and centered finite differences for a and b. The mechanism manifested in the controlled planar vector field: a scaled linearly with c, b scaled linearly with d, both zero crossings occurred at the predicted parameter values, and the finite-difference a error followed the predicted quadratic h² scaling while b remained constant. The BT penalty slightly improved the matched toy task loss, but this is not evidence of a general neural-ODE training win.
- Agent confidence
- 8/10
- Baseline
- 180 Adam steps: final task loss 1.5242e-08; final c=1.0000962, d=1.0000774
- Idea
- 180 Adam steps with BT hinge penalty: final task loss 2.5572e-10; final c=1.0000096, d=0.9999872; observed a(c) slope=1.0000000000000002 and b(d) slope=1.0000000000000002; finite-difference a at h=[0.1,0.05,0.025,0.0125,0.00625] was [0.746,0.734,0.731,0.73025,0.7300625], matching prediction, while b=-0.62 at every scale
Limitations: The experiment uses a controlled two-dimensional polynomial vector field rather than a learned neural ODE or damped-oscillator trajectory dataset. It does not test equilibrium search during training, high-dimensional projections, noisy Jacobians, runtime overhead, or robustness across architectures and tasks.
How to run: python3 bt_monitor_experiment.py
Stage 2 — Benchmark vs. tuned baseline (arXiv:2608.13931)
No significant difference vs. the tuned baseline (−-0.0%, p=1, wins 0 / 8 paired seeds).
- Benchmark
- Dynamics forecasting
- Model
- rnn_small
- Paired seeds
- 8
- Baseline mean
- 0.001
- Idea mean
- 0.001
- Effect (Δ)
- 0 (−-0.0%; negative = idea better)
- Wins
- 0 / 8 paired seeds
- p-value
- 1 (permutation test, 20 000 shuffles)
- Smallest detectable effect
- ±0.0%
- Mechanism
- Not confirmed ✗
- Practical effect
- No effect
- Baseline tuning
- swept over 3 configs
The monitor was applied at a zero hidden-state probe of the GRU recurrent map rather than solving per-checkpoint equilibria; it used a compact 400-train/200-test subset and 15 epochs for budget reasons. It did not test longer rollouts, alternative equilibrium-search strategies, larger latent projections, or a sweep over BT penalty strengths. The differentiable monitor is computationally expensive and its effect was numerically negligible in this setup.
How to run: python3 stage2_bench.py
Verdict computed by deterministic test code from paired-seed statistics — not by the language model.
Stage 2 — Benchmark latest Failed ✗
Agent confidence: 9/10
Implemented a BT monitor for the structurally matched dynamics track using the shared rnn_small recurrent architecture, centered finite differences, and the smallest right-singular-vector direction. Across 8 paired seeds and a three-point shared learning-rate sweep, the idea and baseline had identical test MSEs (delta_mean=0, permutation p=1.0), and the near-degeneracy fraction was unchanged (0.75 vs 0.75), so neither the promised mechanism nor a training win was observed.
- Baseline
- Best lr=0.006, weight_decay=0; full 8-seed test MSE mean 0.0009940864, std 0.0002634151; sweep means: lr 0.0015=0.00209760, 0.003=0.00122624, 0.006=0.00100919.
- Idea
- Best idea lr=0.006, weight_decay=0; full 8-seed test MSE mean 0.0009940864, std 0.0002634151. Paired delta_mean=0.0, p=1.0, wins=0/8; |ab| below 0.0004 fraction 0.75, identical to baseline.
Benchmark result
No significant difference vs. the tuned baseline (−-0.0%, p=1, wins 0 / 8 paired seeds).
- Benchmark
- Dynamics forecasting
- Model
- rnn_small
- Paired seeds
- 8
- Baseline mean
- 0.001
- Idea mean
- 0.001
- Effect (Δ)
- 0 (−-0.0%; negative = idea better)
- Wins
- 0 / 8 paired seeds
- p-value
- 1 (permutation test, 20 000 shuffles)
- Smallest detectable effect
- ±0.0%
- Mechanism
- Not confirmed ✗
- Practical effect
- No effect
- Baseline tuning
- swept over 3 configs
The monitor was applied at a zero hidden-state probe of the GRU recurrent map rather than solving per-checkpoint equilibria; it used a compact 400-train/200-test subset and 15 epochs for budget reasons. It did not test longer rollouts, alternative equilibrium-search strategies, larger latent projections, or a sweep over BT penalty strengths. The differentiable monitor is computationally expensive and its effect was numerically negligible in this setup.
How to run: python3 stage2_bench.py
Artifacts
- bench_report.json 6.4 KB View Raw
- bt_monitor_experiment.py 3.9 KB View Raw
- report.md 1.6 KB View
- report_bench_2026-09-01T135428.md 3.9 KB View
- results.json 2.8 KB View Raw
- stage2_bench.py 6.3 KB View Raw