AFTD Auto-Formalizing Theoretical Domains

ising_inverse_square_ring_free_energy

def

For natural L and real x and h, the reduced free energy per spin is 1/L times the real logarithm of the sum over functions s from Fin L to Bool of exp(x times the sum over i,j in Fin L with i.val<j.val of the periodized kernel times the real spins at i and j, plus h times the sum over i in Fin L of the real spin at i). True represents spin +1 and false represents -1.

Statement

noncomputable def ising_inverse_square_ring_free_energy (L : ℕ) (x h : ℝ) : ℝ
Defined in
arXiv:2610.39815, Sections 2–4; helper for OP-806.
Verified
01 Nov 2026
Axioms
none listed
Built on 2
  • ising_ring_spinMaps a Boolean spin to the real value +1 for true and -1 for false.
  • ising_inverse_square_ring_kernelFor a natural-number ring size L and sites i and j in Fin L, use their real-valued indices i.val and j.val: the kernel is 0 if i=j and…
Used by 2

Read back from the Lean

The definition ising_inverse_square_ring_free_energy takes a natural number $L$ and two real numbers $x$ and $h$, and returns the real number given by: $$\frac{1}{L} \ln \left( \sum_{s : \text{Fin } L \to \text{Bool}} \exp \left( x \sum_{i : \text{Fin } L} \sum_{j : \text{Fin } L} \left( \text{if } i < j \text{ then } K_L(i, j) \cdot \sigma(s(i)) \cdot \sigma(s(j)) \text{ else } 0 \right) + h \sum_{i : \text{Fin } L} \sigma(s(i)) \right) \right)$$ where: - $K_L(i, j) = \text{ising\_inverse\_square\_ring\_kernel}(L, i, j)$ is the interaction kernel, - $\sigma(b) = \text{ising\_ring\_spin}(b)$ maps a boolean spin configuration at site $i$ to $+1$ or $-1$.

Written by a model that saw only the Lean, never the English above. If the two disagree, that is worth a challenge.

Lean source view module on GitHub

noncomputable def ising_inverse_square_ring_free_energy (L : ℕ) (x h : ℝ) : ℝ := (1 / (L : ℝ)) * Real.log (∑ s : Fin L → Bool,
    Real.exp (x * (∑ i : Fin L, ∑ j : Fin L,
      if i.val < j.val then ising_inverse_square_ring_kernel L i j *
        ising_ring_spin (s i) * ising_ring_spin (s j) else 0) +
      h * (∑ i : Fin L, ising_ring_spin (s i))))
See it in the graphDiscuss this resultChallenge it