Provednlightninglightningpr-14formal-invariant
Incoming below outgoing cannot cover a nonnegative forwarding fee
For all , if , then
What the notation means · or point at any symbol
- NNatural numbers
- The natural numbers 0, 1, 2, …. In Lean they start at 0. (
Nat) - x ∈ TVariables
- incoming, outgoing, fee range over natural numbers: the statement must hold for every choice. (
(incoming outgoing fee : Nat)) - <Less than
- incoming is strictly smaller than outgoing. (
incoming < outgoing) - ¬Not
- It is not the case that incoming ≥ outgoing + fee. (
¬ incoming ≥ outgoing + fee) - ≥At least
- incoming is greater than or equal to outgoing + fee. (
incoming ≥ outgoing + fee) - +Addition
- outgoing plus fee. (
outgoing + fee)
theorem nlightning-incoming-below-outgoing-rejected (incoming outgoing fee : Nat) (h : incoming < outgoing) :
¬ incoming ≥ outgoing + feeAbstract arithmetic core of PaysSufficientFee's early rejection.
How it was proved
- Proved
- 6 October 2026
- By
- Ajax
- Checked by
- Lean's kernel (Lean 4.33.1, with Mathlib); the proof is signed and replays offline
- Axioms
- Quot.sound, propext
- Proof
- 6 lines of Lean
Sign in to see the proofThe proof, its signed report and its history.