== check_note.py: Branden's Conjectures 2 and 5 (OWR-15219-013) ==
Python 3.9.6

-- A. P and P_inf --
PASS A1 P = P_A with A = (J-I)/2
PASS A2 P homogeneous of degree 3
PASS A3 P: dQ/dx_i(1) = 1 = d/m for i = 1,2,3
PASS A4 P symmetric under all 6 permutations
PASS A5 P(1) = 1
PASS A2 P_inf homogeneous of degree 3
PASS A3 P_inf: dQ/dx_i(1) = 1 = d/m for i = 1,2,3
PASS A4 P_inf symmetric under all 6 permutations
PASS A5 P_inf(1) = 1
PASS A6 A = (J-I)/2 doubly stochastic, entries >= 0
PASS A7 P_{J/3} = P_inf

-- B. chi_P (Theorem A) --
PASS B1 chi_P = t^3 - 3t^2 + (9/4)t - 1/4 (operator definition) | (-1/4)t^0 + (9/4)t^1 + (-3)t^2 + (1)t^3
PASS B2 chi_P = (t-1)(4t^2-8t+1)/4
PASS B3 E_k(P) = sigma_k(A) (sums of k x k permanental minors) = 1, 3, 9/4, 1/4 | ['1', '3', '9/4', '1/4']
PASS B4 chi_P(1) = 0, chi_P(1 + sqrt3/2) = 0, chi_P(1 - sqrt3/2) = 0 in Q(sqrt3)

-- C. chi_{P_inf} and the failed partial sum --
PASS C1 chi_{P_inf} = t^3 - 3t^2 + 2t - 2/9 (operator definition) | (-2/9)t^0 + (2)t^1 + (-3)t^2 + (1)t^3
PASS C2 E_k(P_inf) = sigma_k(J/3) = C(3,k)^2 k!/3^k
PASS C3 chi_{P_inf}(1 + y) = y^3 - y - 2/9
PASS C4 g(-sqrt3/2) = sqrt3/8 - 2/9
PASS C5 sqrt3/8 - 2/9 < 0, i.e. (9 sqrt3)^2 = 243 < 256 = 16^2
PASS C6 g'(y) = 3y^2 - 1 >= 5/4 > 0 for y <= -sqrt3/2 (since y^2 >= 3/4)
PASS C7 sign changes of g: g(-1) < 0 < g(-1/2), g(1/2) < 0 < g(2) (three real zeros)
PASS C8 chi_{P_inf} has 3 real zeros (Sturm)
     mu (rational isolating intervals, width <= 1e-12):
       [2.0966483609791, 2.0966483609800]
       [0.7647601200924, 0.7647601200933]
       [0.1385915189276, 0.1385915189285]
PASS C9 lambda_3(P) = 1 - sqrt3/2 < mu_3 (rational lower bound of mu_3 exceeds 1 - sqrt3/2)
PASS C10 k = 2: lambda1+lambda2 (P) = 2 + sqrt3/2 > 3 - mu_3 >= mu1+mu2 (upper bound) | 2.8660254038 > 2.8614084811
PASS C11 k = 1 holds: lambda_1(P) = 1 + sqrt3/2 < mu_1 | 1.866025 < 2.096648

-- D. the operator T on cubic forms in 3 variables --
PASS D1 T(P_inf) = P_inf
PASS D2 T(B0) = B0/3
PASS D3 T(C0) = 0
PASS D4 P = P_inf + B0/36 - C0/216
PASS D5 chi_{B0} = 9t - 3, chi_{C0} = -12
PASS D6 B0(1) = C0(1) = 0
PASS D7 char. polynomial of T on all 10 cubic forms = (x-1)(x-2/3)^2(x-1/3)^3 x^4 | {'0': 4, '1/3': 3, '2/3': 2, '1': 1}
PASS D8 Proposition 5.1(a) on small cases: spectrum of T on V_d in {0,1/d,...,1}, eigenvalue 1 simple (m,d) in {(2,1..5),(3,1..4),(4,2..3)}
PASS D9 Proposition 5.1(b),(d): grad_1(TQ) = K grad_1(Q), K = (J + m(d-1)I)/(md), and (TQ)(1) = Q(1) on all monomials, (m,d) in {(2,3),(3,3),(4,2)}

-- E. the flow orbit as a family of products --
PASS E1 P_inf + q^2 B0/36 - q^3 C0/216 = P_{A(q)} at 10 values of q (both sides of degree <= 3 in q: identity)
PASS E2 A(q) has row and column sums 1 for all q (checked at 10 values; linear in q)
PASS E3 entries of A(q) >= 0 at q = 0 and q = 1, hence on [0,1] (linear in q)
PASS E4 A(1) = (J-I)/2, A(0) = J/3
PASS E5 printed sign: diagonal entry (1-u)/3 < 0 for u = 6/5, 3/2, 2

-- F. chi along the orbit --
PASS F1 chi_{P_{A(q)}} (operator definition) = t^3 - 3t^2 + (2+q^2/4)t - 2/9 - q^2/12 + q^3/18 at 10 values of q (identity)
PASS F2 sigma_2(A(q)) = 2 + q^2/4 and per A(q) = 2/9 + q^2/12 - q^3/18 at 10 values of q
PASS F3 chi_q(1+y) = y^3 + (q^2/4 - 1) y + (q-1)(q+2)^2/18 (10 q, 7 y)
PASS F4 d/dq chi_q(t) = (q/6)(3t - 1 + q): t^0 part (q^2 - q)/6, t^1 part q/2

-- G. discriminant --
PASS G1 disc_t(chi_q) = (2+q)^3 (16 - 24q + 18q^2 - 7q^3)/48 at 13 values of q (degree 6: identity)
PASS G2 ... = 8/3 - q^2 + 2q^3/3 - q^5/2 - 7q^6/48 (13 values)
PASS G3 h'(q) = -3(7q^2 - 12q + 8) and 12^2 - 4*7*8 = -80 < 0, so h is strictly decreasing; h(1) = 3 > 0
PASS G4 hence disc > 0 on (-2, 1]: e.g. disc(0) = 8/3, disc(1) = 27/16
PASS G5 h has exactly one real zero u0 (Sturm)
     u0 in [1.287354371509, 1.287354371510],  3 ln u0 = 0.757767713

-- H. Theorem B and the printed sign: values at 1 -+ sqrt3/2 --
PASS H1 chi_q(1 - sqrt3/2) = (q-1)[(q+2)^2/18 - (sqrt3/8)(q+1)] (10 q, degree 3: identity)
PASS H2 chi_q(1 + sqrt3/2) = (q-1)[(q+2)^2/18 + (sqrt3/8)(q+1)] (identity)
PASS H3 (q+2)^2/18 - (sqrt3/8)(q+1) = [4q^2 + (16 - 9 sqrt3)(1+q)]/72 (10 q)
PASS H4 16 - 9 sqrt3 > 0
PASS H5 the printed-sign form: chi_u(1+sqrt3/2) = (u^2-1)(1/6+sqrt3/8) + (u^3-1)/18 (10 u)
PASS H6 d/dy chi_q(1+y) = 3y^2 + q^2/4 - 1 >= 5/4 + q^2/4 > 0 for y^2 >= 3/4 (coefficient check)

-- I. rational instances, flow exp(s(T-I)), q = exp(-s/3) --
PASS I1 q = 1/2 (s = 3 ln 2): 144 chi = 144t^3 - 432t^2 + 297t - 34
     zeros at q = 1/2: [2.0501523367, 2.0501523367], [0.8071662917, 0.8071662917], [0.1426813716, 0.1426813716]
PASS I2 q = 1/2: lambda1+lambda2 <= 3 - (lower bound of lambda3) < 2 + sqrt3/2 | 2.857318628 < 2.866025404
PASS I3 q = 1/10: three real zeros and lambda_3 > 1 - sqrt3/2 | lambda_3 in [0.1389428352, 0.1389428352]
PASS I3 q = 1/2: three real zeros and lambda_3 > 1 - sqrt3/2 | lambda_3 in [0.1426813716, 0.1426813716]
PASS I3 q = 9/10: three real zeros and lambda_3 > 1 - sqrt3/2 | lambda_3 in [0.1378471748, 0.1378471748]
PASS I3 q = 99/100: three real zeros and lambda_3 > 1 - sqrt3/2 | lambda_3 in [0.1344152244, 0.1344152244]
PASS I3 q = 999/1000: three real zeros and lambda_3 > 1 - sqrt3/2 | lambda_3 in [0.1340191949, 0.1340191949]
PASS I4 pair with r > 0: lambda_3(q = 99/100) < lambda_3(q = 1/2), so the k = 2 inequality fails for r = 3 ln(100/99), s = 3 ln 2 | 0.1344152244 < 0.1426813716
PASS I5 (numerical illustration) lambda_1 along q = 1, 0.95, ..., 0 increases strictly from 1+sqrt3/2 to mu_1 | 1.86603 -> 2.09665
PASS I6 (numerical illustration) lambda_3 along the orbit is not monotone | max at q = 11/20

-- J. printed sign exp(s(I-T)), u = exp(s/3) > 1 --
PASS J1 u = 3/2: 288 chi = 288t^3 - 864t^2 + 738t - 64
PASS J2 u = 3/2: discriminant < 0 and exactly one real zero (Sturm) | disc = -8575/3072
PASS J3 u = 6/5: three real zeros, lambda_1 < 1 + sqrt3/2 = lambda_1(P) | 1.68913, 1.18819, 0.12268
PASS J4 u0 in (6/5, 3/2): h(6/5) > 0 > h(3/2)

-- K. coefficient inequalities for A = (J-I)/2 (n = 3) --
PASS K1 Holens-Dokovic inequalities k n sigma_k >= (n-k+1)^2 sigma_{k-1} hold: 9>=9, 27/2>=12, 9/4>=9/4 | [('9', '9'), ('27/2', '12'), ('9/4', '9/4')]
PASS K2 Tverberg-Friedland sigma_k(A) >= sigma_k(J/3): 3>=3, 9/4>=2, 1/4>=2/9
PASS K3 van der Waerden/Gurvits bound (1): per A = 1/4 >= 3!/3^3 = 2/9
PASS K4 equality case: (n-k+1)^2/(k n) = sigma_k(J/n)/sigma_{k-1}(J/n) for n = 2..9

-- L. the orbit as the family alpha I + (1-alpha)(J-I)/2, alpha = (1-q)/3 --
PASS L1 A(q) = alpha I + (1-alpha)(J-I)/2 with alpha = (1-q)/3 (10 q)
PASS L2 chi_q(mu_3) = q^2 (mu_3/4 - 1/12 + q/18): chi_q - chi_0 = q^2 (t/4 - 1/12) + q^3/18 (coefficients)
     alpha* = (9 mu_3 - 1)/6 in [0.041220611725, 0.041220611726];  q* = (3 - 9 mu_3)/2 in [0.876338164822, 0.876338164826]
PASS L3 alpha = 1/25 (q = 22/25): k = 2 fails (certified by intervals) | lambda_3 ~ 0.138480572, mu_3 ~ 0.138591519
PASS L3 alpha = 41/1000 (q = 877/1000): k = 2 fails (certified by intervals) | lambda_3 ~ 0.138571581, mu_3 ~ 0.138591519
PASS L3 alpha = 21/500 (q = 437/500): k = 2 holds (certified by intervals) | lambda_3 ~ 0.138661551, mu_3 ~ 0.138591519
PASS L3 alpha = 1/10 (q = 7/10): k = 2 holds (certified by intervals) | lambda_3 ~ 0.142175652, mu_3 ~ 0.138591519

-- M. P_inf for m = d = n and Laguerre polynomials; multiaffine polynomials --
PASS M1 chi_{P_inf} = (-1)^n n! n^{-n} L_n(nt) for m = d = n, n = 2..8
PASS M2 operator definition agrees with E_k = C(n,k)^2 k!/n^k for P_inf, n = 2, 3, 4
PASS M3 multiaffine homogeneous Q with Q(1) = 1 has chi_Q = (t-1)^d (several examples)

-- N. cycle family A_n = (I + C_n)/2, P_n = prod_i (x_i + x_{i+1})/2 (computation, 3 <= n <= 12) --
PASS N1 P_3 = P
PASS N2 sigma_k(A_n) = (2n/(2n-k)) C(2n-k,k)/2^k agrees with permanental minors for n = 3, 4, 5
PASS N3 ... and with the operator definition of chi for n = 3, 4
PASS N4 n =  3: both chi have n real zeros; lambda_n(P_n) < lambda_n(P_inf) (certified), so the k = n-1 partial sum fails | 0.1339746 < 0.1385915
PASS N4 n =  4: both chi have n real zeros; lambda_n(P_n) < lambda_n(P_inf) (certified), so the k = n-1 partial sum fails | 0.0761205 < 0.0806369
PASS N4 n =  5: both chi have n real zeros; lambda_n(P_n) < lambda_n(P_inf) (certified), so the k = n-1 partial sum fails | 0.0489435 < 0.0527121
PASS N4 n =  6: both chi have n real zeros; lambda_n(P_n) < lambda_n(P_inf) (certified), so the k = n-1 partial sum fails | 0.0340742 < 0.0371411
PASS N4 n =  7: both chi have n real zeros; lambda_n(P_n) < lambda_n(P_inf) (certified), so the k = n-1 partial sum fails | 0.0250721 < 0.0275777
PASS N4 n =  8: both chi have n real zeros; lambda_n(P_n) < lambda_n(P_inf) (certified), so the k = n-1 partial sum fails | 0.0192147 < 0.0212849
PASS N4 n =  9: both chi have n real zeros; lambda_n(P_n) < lambda_n(P_inf) (certified), so the k = n-1 partial sum fails | 0.0151922 < 0.0169247
PASS N4 n = 10: both chi have n real zeros; lambda_n(P_n) < lambda_n(P_inf) (certified), so the k = n-1 partial sum fails | 0.0123117 < 0.0137793
PASS N4 n = 11: both chi have n real zeros; lambda_n(P_n) < lambda_n(P_inf) (certified), so the k = n-1 partial sum fails | 0.0101786 < 0.0114360
PASS N4 n = 12: both chi have n real zeros; lambda_n(P_n) < lambda_n(P_inf) (certified), so the k = n-1 partial sum fails | 0.0085551 < 0.0096435

TOTAL checks: 95   TOTAL failures: 0
