Skip to content

Commit

Permalink
fix: remove theorems which now exist in core
Browse files Browse the repository at this point in the history
  • Loading branch information
markusschmaus committed Jun 3, 2024
1 parent 030ed86 commit ad430b5
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions Mathlib/Data/Nat/Defs.lean
Original file line number Diff line number Diff line change
Expand Up @@ -138,14 +138,6 @@ lemma le_of_pred_lt : ∀ {m}, pred m < n → m ≤ n
lemma lt_iff_add_one_le : m < n ↔ m + 1 ≤ n := by rw [succ_le_iff]
#align nat.lt_iff_add_one_le Nat.lt_iff_add_one_le

-- Just a restatement of `Nat.lt_succ_iff` using `+1`.
lemma lt_add_one_iff : m < n + 1 ↔ m ≤ n := Nat.lt_succ_iff
#align nat.lt_add_one_iff Nat.lt_add_one_iff

-- A flipped version of `lt_add_one_iff`.
lemma lt_one_add_iff : m < 1 + n ↔ m ≤ n := by simp only [Nat.add_comm, Nat.lt_succ_iff]
#align nat.lt_one_add_iff Nat.lt_one_add_iff

-- This is true reflexively, by the definition of `≤` on ℕ,
-- but it's still useful to have, to convince Lean to change the syntactic type.
lemma add_one_le_iff : m + 1 ≤ n ↔ m < n := Iff.rfl
Expand Down Expand Up @@ -315,7 +307,7 @@ lemma add_eq_three_iff :
#align nat.add_eq_three_iff Nat.add_eq_three_iff

lemma le_add_one_iff : m ≤ n + 1 ↔ m ≤ n ∨ m = n + 1 := by
rw [Nat.le_iff_lt_or_eq, lt_add_one_iff]
rw [Nat.le_iff_lt_or_eq, Nat.lt_add_one_iff]
#align nat.le_add_one_iff Nat.le_add_one_iff

lemma le_and_le_add_one_iff : n ≤ m ∧ m ≤ n + 1 ↔ m = n ∨ m = n + 1 := by
Expand Down Expand Up @@ -1551,7 +1543,7 @@ private lemma sqrt_isSqrt (n : ℕ) : IsSqrt n (sqrt n) := by
simp only [IsSqrt, sqrt, h, ite_false]
refine ⟨sqrt.iter_sq_le _ _, sqrt.lt_iter_succ_sq _ _ ?_⟩
simp only [Nat.mul_add, Nat.add_mul, Nat.one_mul, Nat.mul_one, ← Nat.add_assoc]
rw [lt_add_one_iff, Nat.add_assoc, ← Nat.mul_two]
rw [Nat.lt_add_one_iff, Nat.add_assoc, ← Nat.mul_two]
refine le_trans (Nat.le_of_eq (div_add_mod' (n + 2) 2).symm) ?_
rw [Nat.add_comm, Nat.add_le_add_iff_right, add_mod_right]
simp only [Nat.zero_lt_two, add_div_right, succ_mul_succ]
Expand Down

0 comments on commit ad430b5

Please sign in to comment.