Composition of implications
Sebastian Pokutta
v1 2026-10-19 · last 2026-11-28
Note: An example: it shows what an entry can contain, on a deliberately simple result.
Abstract. If and then . The archive’s worked example: a result small enough to read at a glance, used to show numbered results, a diagram, an interactive widget and a Mathlib corollary.
Implications chain. This is the archive’s worked example: it shows the pieces an entry can use — numbered results, a diagram, a widget, a Mathlib corollary — on a result small enough to read at a glance.
Composing with self-implication () on either side changes nothing:
/-- Every proposition implies itself. -/
theorem self_implication (P : Prop) : P → P :=
fun hp => hp
/-- Implications compose. -/
theorem implication_composition {P Q R : Prop} (hpq : P → Q) (hqr : Q → R) : P → R :=
fun hp => Lemmata.Shared.mp hqr (Lemmata.Shared.mp hpq hp)
/-- Composing with self-implication changes nothing. -/
theorem compose_self {P Q : Prop} (hpq : P → Q) : P → Q :=
implication_composition (self_implication P) hpqTry it: pick which hypotheses hold, and see whether follows.
Formal verification — ✅ all 2 formal results are kernel-checked
✓ kernel-checked (Lean v4.35.0) Theorem 1 —
Lemmata.ImplicationComposition.implication_composition(source)✓ kernel-checked (Lean v4.35.0) Corollary 1 —
Lemmata.ImplicationComposition.le_compose(source)
Checked at commit 3b355a656ef3. The formal statement is machine-checked; that it matches the prose is checked by review. What “checked” means.
Lean implication_composition · ✅ kernel-checked · source
Statement in Lean
/-- Implications compose. -/
theorem implication_composition {P Q R : Prop} (hpq : P → Q) (hqr : Q → R) : P → RLean le_compose · ✅ kernel-checked · source
Statement in Lean
/-- On a preorder, transitivity of `≤` is composition of the two inequalities. -/
theorem le_compose {α : Type*} [Preorder α] {a b c : α} (h₁ : a ≤ b) (h₂ : b ≤ c) : a ≤ cLicense: CC BY 4.0
Comments.
Comments are external content (GitHub Discussions, shown with giscus) and need JavaScript.