# Randić index and the second adjacency eigenvalue: R ≥ λ₂ + 1

**Result.** The conjecture is TRUE. `Proof.lean` (Lean 4 + Mathlib, single `import Mathlib`, no `sorry`,
axioms used: `propext`, `Classical.choice`, `Quot.sound`) proves

    theorem nullius_main {n : ℕ} (hn : 2 ≤ n) (G : SimpleGraph (Fin n)) [DecidableRel G.Adj]
        (hc : G.Connected) :
        (G.isHermitian_adjMatrix ℝ).eigenvalues₀ ⟨1, _⟩ + 1 ≤ Spectral.randic G

**Reading the Lean statement.** Every finite simple graph on n vertices can be labelled by `Fin n`, and
connectivity, spectrum and Randić index do not depend on the labelling. Mathlib's `eigenvalues₀` lists the
eigenvalues of the (real symmetric) adjacency matrix in decreasing order with multiplicity
(`Matrix.IsHermitian.eigenvalues₀_antitone`), so index 0 is λ₁ and index 1 is λ₂. `Spectral.randic G` is
the sum over the unordered edges uv of G, each once, of 1/√(d_u d_v).

## The proof

Let G be connected with n ≥ 2 vertices, m edges, adjacency matrix A, Randić index R.
Write L = λ₁ and t = max(λ₂, 0). The proof gives the stronger bound L(t+1) ≤ m.

1. **λ₂ + 1 ≤ n/2** (`RandicSecondBound.randic_second_bound`; connectivity not needed).
   In the span of orthonormal eigenvectors for λ₁ and λ₂ pick a nonzero vector x whose coordinates sum to
   zero (possible since the span has dimension two). Its Rayleigh quotient is at least λ₂. With J the
   all-ones matrix, every entry of 2(A+I) − J is ±1 and Jx = 0, so
   2 xᵀ(A+I)x ≤ Σ_{i,j} |x_i x_j| ≤ ½ Σ_{i,j} (x_i² + x_j²) = n‖x‖².
   Dividing by 2‖x‖² gives λ₂ + 1 ≤ n/2. Since n ≥ 2 the same bound holds for t: 2t + 1 ≤ n − 1.

2. **Positive square energy: s⁺ := Σ_i max(λ_i, 0)² ≤ 2m − n + 1 for connected G**
   (`SquareEnergy.positiveSquareEnergy_le_graphQ`). This is the theorem of Liu, Tang and Zhang,
   "The positive and negative square-energy conjecture", arXiv:2607.18031 (min(s⁺, s⁻) ≥ n − 1 for
   connected graphs, together with s⁺ + s⁻ = tr A² = 2m). The Lean development in `Proof.lean`
   (namespace `SquareEnergy`, an induction over cut vertices / vertex deletion on a sparse
   matrix inequality) is adapted from the authors' formalization
   github.com/ShengtongZhang-alt/Sq at revision df80e517 (Apache 2.0), merged into one file.
   Because the two largest eigenvalues contribute L² and t² to s⁺ (L > 0 as G has an edge):
   L² + t² ≤ 2m − n + 1.

3. **Complete the square.** L² + (t+1)² = (L² + t²) + (2t+1) ≤ (2m − n + 1) + (n − 1) = 2m.
   Since (L − (t+1))² ≥ 0, this gives 2L(t+1) ≤ L² + (t+1)² ≤ 2m, i.e. L(t+1) ≤ m.

4. **Favaron–Mahéo–Saclé: m ≤ λ₁ R** (`Spectral.l1_R_ge_m`, adapted from Cazenave's Lean archive
   accompanying arXiv:2611.03879). For each edge uv let w_uv = √(d_u d_v) > 0. The vector
   y_u = √d_u has ‖y‖² = 2m and yᵀAy = 2 Σ_{uv∈E} w_uv, so the Rayleigh quotient gives
   Σ w_uv ≤ mL. Summing 2 ≤ w_uv/L + L/w_uv over the edges gives 2m ≤ m + LR.

5. **Conclude.** L(t+1) ≤ m ≤ LR and L > 0, so λ₂ + 1 ≤ t + 1 ≤ R. ∎

## Remarks

- Connectivity is used only in step 2 (and it is necessary: for two disjoint K_k the inequality of step 3
  fails by exactly 1).
- The same argument proves the paper's stronger statements m ≥ λ₁(λ₂+1) (always, since λ₂+1 ≤ t+1 and
  λ₁ > 0) and 2m ≥ λ₁² + (λ₂+1)² whenever λ₂ ≥ 0; these are not formalized as separate theorems.
- Checked with: `cd /opt/nullius/lean_project && lake env lean Proof.lean` → exit 0, two style-linter
  warnings (`letI`/`haveI`), no errors; `#print axioms nullius_main` → [propext, Classical.choice, Quot.sound].
