Samplinglib
Lean gate not recorded for this source state main · ed709a7f320d
Registry leaf card · entropy.two-point.signed-squared

two_point_squared_entropy_le_half_sq_sub

compiled Samplinglib leaf Not mapped explicit smoke test

Arbitrary signed a,b and zero cases; upper bound Ent(a squared,b squared) <= (a-b) squared/2. Minimal 26-helper positive-Rothaus port; upstream opposite-signed two_point_inequality unused. Independently verified 6d5df34cdb124e28022f16f566ff549145eb7e65. No GaussianLSI/T2/FIRST4.6/main/work/composition completion.

Plain-English statement

Arbitrary signed a,b and zero cases; upper bound Ent(a squared,b squared) <= (a-b) squared/2. Minimal 26-helper positive-Rothaus port; upstream opposite-signed two_point_inequality unused. Independently verified 6d5df34cdb124e28022f16f566ff549145eb7e65. No GaussianLSI/T2/FIRST4.6/main/work/composition completion.

Scope guard. This card records a compiled local declaration. Its mathematical scope is exactly the Lean statement below; the Registry note and source correspondence may describe motivation but do not strengthen it.
Lean learning studio · mathematics → formal proof

Read the mathematics first, then descend into Lean

You do not need to know Lean before opening this panel. The page keeps the paper-level theorem, rigorous proof obligations, exact Lean declaration, and proof dependencies as separate layers so a first-time reader can move down one layer at a time.

BeginnerWhy this theorem exists → intuition → statement → one hand calculation. Hide proof-engineering detail.
RigorousExpose assumptions, hidden measure/limit/domain issues, proof route, and rigorous references.
Lean learnerOpen the exact declaration, proof tree/network, syntax glossary, and line-by-line explanation.

Proof architecture

Start with the tree when learning: prerequisites sit below the theorem and downstream results sit above it. Switch to the network when you want to understand where this declaration lives in the local formal library. Every mapped node is clickable.

Loading source-derived dependency evidence…

Graph rule: only dependencies found by the ASTIS source scan are drawn. Missing tactic indirection is treated as an under-approximation; the site never invents an edge just to make a prettier graph.

How to read the exact Lean declaration

Read a Lean theorem left-to-right exactly as you would unpack a mathematical sentence: name → ambient types → automatically inferred structures → explicit hypotheses → conclusion → proof. Then read the proof top-to-bottom as transformations of the current goal.

  1. NameWhat reusable mathematical fact is being created?
  2. ParametersWhich symbols are arbitrary, and which structures are inferred by typeclass search?
  3. PropositionAfter the colon, translate the Lean expression back into a paper statement.
  4. Proof actionsAfter by, ask what each tactic does to the mathematical goal—not only what syntax it uses.

Syntax used on this page

This glossary is filtered to syntax that actually occurs in the declaration above. Open a symbol only when you meet it, rather than memorizing Lean grammar in advance.

Source voice and ASTIS voice stay separate

When Samplinglib shows a short quotation from Chewi, it is labeled as a source excerpt and linked to the canonical book page. Intuition, expanded proof steps, hidden regularity assumptions, and Lean explanations are ASTIS-authored commentary. A quotation never substitutes for a formal proof, and an ASTIS explanation is never attributed to the textbook author.

Lean statement

theorem two_point_squared_entropy_le_half_sq_sub (a b : ℝ) :
    (a ^ 2 * Real.log (a ^ 2) + b ^ 2 * Real.log (b ^ 2)) / 2 -
      ((a ^ 2 + b ^ 2) / 2) * Real.log ((a ^ 2 + b ^ 2) / 2) ≤
    (a - b) ^ 2 / 2 := by
  have hlog2 : Real.log 2 ≤ 1 := by
    have h := Real.log_le_sub_one_of_pos (by norm_num : (0 : ℝ) < 2)
    norm_num at h
    exact h
  by_cases ha : a = 0
  · subst a
    by_cases hb : b = 0
    · simp [hb]
    · have hb2 : b ^ 2 ≠ 0 := pow_ne_zero 2 hb
      have hlog := Real.log_div hb2 (by norm_num : (2 : ℝ) ≠ 0)
      simp only [zero_pow (by norm_num : (2 : ℕ) ≠ 0), zero_mul, zero_add,
        zero_sub, neg_sq]
      rw [hlog]
      nlinarith [sq_nonneg b, mul_le_mul_of_nonneg_left hlog2 (sq_nonneg b)]
  · by_cases hb : b = 0
    · subst b
      have ha2 : a ^ 2 ≠ 0 := pow_ne_zero 2 ha
      have hlog := Real.log_div ha2 (by norm_num : (2 : ℝ) ≠ 0)
      simp only [zero_pow (by norm_num : (2 : ℕ) ≠ 0), zero_mul, add_zero, sub_zero]
      rw [hlog]
      nlinarith [sq_nonneg a, mul_le_mul_of_nonneg_left hlog2 (sq_nonneg a)]
    · have h := rothaus_lemma (sq_pos_of_ne_zero ha) (sq_pos_of_ne_zero hb)
      rw [Real.sqrt_sq_eq_abs, Real.sqrt_sq_eq_abs] at h
      have hab : (|a| - |b|)^2 ≤ (a-b)^2 := by
        rw [sq_le_sq]
        exact abs_abs_sub_abs_le_abs_sub a b
      linarith

end AutoSamplingTheory.TechnicalLemmas.FunctionalInequalities.TwoPointEntropy

Proof architecture

Actual SPHMC omitted Gaussian LSI background; no SALD or second-route admission

Lean proof walkthrough

  • Read the quantified variables and typeclass brackets as part of the mathematical statement; inferred arguments are not missing assumptions.
  • `have` creates a named intermediate mathematical fact.
  • `rw` rewrites by an established identity.
  • `simp` normalizes through registered definitional and theorem rewrites.
  • `exact` closes the current goal with an already typed term.

Why the statement has this shape

The declaration is kept at the reusable level recorded by its Registry tags and direct consumers. Explicit measures, spaces, wrappers, and regularity hypotheses expose interfaces that paper notation often infers. A theorem card explains those interfaces but never widens the compiled statement.

Hidden assumptions and non-claims

  • No additional hidden-contract keyword was inferred; the exact Lean hypotheses remain controlling.
Common pitfall. A wrapper or display identity is not a new analytic theorem merely because it has its own Lean name. Check the statement, hypotheses, and downstream consumers before interpreting its mathematical contribution.