The areas / V34. The tactics of Mathlib
Mathlib.Tactic.PNatToNat
6 declarations. Mathlib docs · Source
pnat_to_nat
This file implements the pnat_to_nat tactic that shifts PNats in the context to Nat.
Implementation notes
The implementation follows these steps:
- For each
x : PNatin the context, add the hypothesis0 < (↑x : ℕ). - Translate arithmetic on
PNattoNatusing thepnat_to_nat_coesimp set.
def Mathlib.Tactic.PNatToNat.tacticPnat_positivity E1 #
Lean.ParserDescr
For each x : PNat in the context, add the hypothesis 0 < (↑x : ℕ).
theorem Mathlib.Tactic.PNatToNat.coe_inj E0 #
∀ (m n : ℕ+), m = n ↔ ↑m = ↑n
theorem Mathlib.Tactic.PNatToNat.coe_le_coe E0 #
∀ (m n : ℕ+), m ≤ n ↔ ↑m ≤ ↑n
theorem Mathlib.Tactic.PNatToNat.coe_lt_coe E0 #
∀ (m n : ℕ+), m < n ↔ ↑m < ↑n
theorem Mathlib.Tactic.PNatToNat.sub_coe E0 #
∀ (a b : ℕ+), ↑(a - b) = ↑a - 1 - ↑b + 1
def Mathlib.Tactic.PNatToNat.tacticPnat_to_nat E1 #
Lean.ParserDescr
pnat_to_nat shifts all PNats in the context to Nat, rewriting propositions about them.
A typical use case is pnat_to_nat; lia.