MODE COUPLING MATRIX — THE 7-MODE EQUILIBRIUM
======================================================================
Started: 2026-03-25 18:57:48
d = 3, gamma = 0.0650898425

PART 1: MODE PROFILES
-------------------------------------------------------
  n    eps_n  width integral(phi^2)     peak
---------------------------------------------
    1   0.0650   15.4         35.7937   1.0000
    2   0.1298    7.7         17.9348   1.0000
    3   0.1940    5.2         11.9989   1.0000
    4   0.2574    3.9          9.0439   1.0000
    5   0.3197    3.1          7.2816   1.0000
    6   0.3807    2.6          6.1157   1.0000
    7   0.4400    2.3          5.2910   1.0000

PART 2: OVERLAP MATRIX M_{nm} = ∫ φ_n² · φ_m² dx
-------------------------------------------------------
This is the mode-mode coupling strength.

              1         2         3         4         5         6         7
---------------------------------------------------------------------------
    1     24.57     15.72     11.24      8.70      7.10      6.01      5.22
    2     15.72     12.31      9.72      7.91      6.64      5.72      5.03
    3     11.24      9.72      8.24      7.02      6.08      5.34      4.76
    4      8.70      7.91      7.02      6.21      5.51      4.94      4.46
    5      7.10      6.64      6.08      5.51      5.00      4.55      4.17
    6      6.01      5.72      5.34      4.94      4.55      4.20      3.89
    7      5.22      5.03      4.76      4.46      4.17      3.89      3.63

Eigenvalues of M (overlap matrix):
  [0]       0.0000
  [1]       0.0001
  [2]       0.0039
  [3]       0.0745
  [4]       0.9158
  [5]       8.1560
  [6]      54.9981

Eigenvectors (columns = mode weights):
             v0        v1        v2        v3        v4        v5        v6
    1   -0.0009   -0.0074   +0.0376   -0.1383   -0.3728   -0.6819   -0.6127
    2   +0.0161   +0.0899   -0.2922   +0.5827   +0.5898   -0.0388   -0.4662
    3   -0.1129   -0.3855   +0.6276   -0.3117   +0.3996   +0.2195   -0.3739
    4   +0.3860   +0.6321   -0.1273   -0.4788   +0.0777   +0.3204   -0.3118
    5   -0.6774   -0.1440   -0.4934   -0.2212   -0.1735   +0.3554   -0.2675
    6   +0.5839   -0.5418   -0.2026   +0.1484   -0.3418   +0.3614   -0.2345
    7   -0.1951   +0.3596   +0.4676   +0.4939   -0.4478   +0.3546   -0.2090

PART 3: WELL-FILLING VECTOR W_n = ∫ φ_n² · V_kink dx
-------------------------------------------------------
How much does each mode's perturbation overlap the kink potential?

  n          W_n    W_n/W_1
------------------------------
    1      27.3520     1.0000
    2       9.6722     0.3536
    3       4.0132     0.1467
    4       1.4065     0.0514
    5       0.0353     0.0013
    6      -0.7219    -0.0264
    7      -1.1404    -0.0417

LEAST-SQUARES FIT: sum_n a_n · φ_n² ≈ V_kink
  Fit coefficients a_n (modes fill the kink well deviation):
    n=1: a = +7969.763142
    n=2: a = -25375.347552
    n=3: a = +38952.270518
    n=4: a = -39522.539753
    n=5: a = +27535.129447
    n=6: a = -11996.091613
    n=7: a = +2435.631397
  Residual / Total = 0.000000 (0.00%)

PART 4: RATIO STRUCTURE
-------------------------------------------------------
Are the mode ratios simple functions of n and gamma?

Fit coefficients normalized to a_1:
  n        a_n    a_n/a_1 eps_n/eps_1    omega_n
--------------------------------------------------
    1 +7969.7631    +1.0000      1.0000   0.997882
    2 -25375.3476    -3.1840      1.9958   0.991539
    3 +38952.2705    +4.8875      2.9831   0.980995
    4 -39522.5398    -4.9591      3.9578   0.966298
    5 +27535.1294    +3.4549      4.9157   0.947507
    6 -11996.0916    -1.5052      5.8528   0.924704
    7 +2435.6314    +0.3056      6.7651   0.897984

Testing ratio models:

  Model 1 (a_n ~ 1/eps_n, width weighting): error = 100.6%
  Model 2 (a_n ~ eps_n, inverse width): error = 167.7%
  Model 3 (a_n ~ omega_n, frequency weighting): error = 104.3%
  Model 4 (a_n ~ (-1)^n * eps_n): error = 96.5%
  Model 5 (a_n ~ cos(n·π/8)): error = 102.3%
  Model 6 (smallest eigenvector of M): error = 12672.7%
  Model 7 (M^{-1} W, matrix solution): error = 2777.0%

PART 5: THE SUM RULE
-------------------------------------------------------
Does sum_n a_n^2 * phi_n^2 = const (completeness)?
Or sum_n a_n * phi_n^2 = V_kink (well-filling)?

Profile comparison at key positions:
    x    delta_V        fit   equal_wt   phi_kink
--------------------------------------------------
     -8    -0.0000   112.3980     1.7499     0.0018
     -7    -0.0001    22.8751     2.0710     0.0049
     -6    -0.0009    -0.0009     2.4906     0.0134
     -5    -0.0066    -0.0066     3.0489     0.0365
     -4    -0.0481    -0.0481     3.7911     0.0991
     -3    -0.3279    -0.3279     4.7339     0.2654
     -2    -1.4700    -1.4700     5.7818     0.6557
     -1    -1.8062    -1.8062     6.6550     1.2015
      0    -1.1844    -1.1844     7.0000     1.4410
      1    -1.8062    -1.8062     6.6550     1.2015
      2    -1.4700    -1.4700     5.7818     0.6557
      3    -0.3279    -0.3279     4.7339     0.2654
      4    -0.0481    -0.0481     3.7911     0.0991
      5    -0.0066    -0.0066     3.0489     0.0365
      6    -0.0009    -0.0009     2.4906     0.0134
      7    -0.0001    22.8751     2.0710     0.0049
      8    -0.0000   112.3980     1.7499     0.0018

Sum rule: Σ_n φ_n²(x) vs V_kink(x) and delta_V(x)
  Integral of Σφ²: 60.0027
  Integral of |delta_V|: 8.5035
  Integral of -delta_V: 8.5035
  Ratio Σφ² / |delta_V|: 7.0563

PART 6: BONDING — EQUILIBRIUM SHIFT MODEL
-------------------------------------------------------
When a second proton arrives at distance R, the kink well changes.
The 7-mode equilibrium shifts. The energy change = bond energy.

Finding optimal single-proton mode weights...
Single proton optimal E0: -0.74042113 (bare: -0.37237471)
Optimal weights:
  n=1: c = -1.835861
  n=2: c = +0.556311
  n=3: c = +19.630263
  n=4: c = +2.842189
  n=5: c = -5.777430
  n=6: c = -2.496477
  n=7: c = -5.613482

OPTIMAL WEIGHT RATIOS (single proton):
  n        c_n    c_n/c_1    eps_n  omega_n
---------------------------------------------
    1    -1.8359    +1.0000   0.0650   0.9979
    2    +0.5563    -0.3030   0.1298   0.9915
    3   +19.6303   -10.6927   0.1940   0.9810
    4    +2.8422    -1.5482   0.2574   0.9663
    5    -5.7774    +3.1470   0.3197   0.9475
    6    -2.4965    +1.3598   0.3807   0.9247
    7    -5.6135    +3.0577   0.4400   0.8980

BONDING — OPTIMIZED WEIGHTS VS R:
-------------------------------------------------------
   R       V_bare  V_optimized    V_unit_wt opt_vs_bare%
----------------------------------------------------------
