Basic operations on the natural numbers #
This file builds on Mathlib/Data/Nat/Init.lean by adding basic lemmas on natural numbers
depending on Mathlib definitions.
See note [foundational algebra order theory].
succ, pred #
div #
Recursion and induction principles #
This section is here due to dependencies -- the lemmas here require some of the lemmas proved above, and some of the results in later sections depend on the definitions in this section.
theorem
Nat.leRecOn_injective
{C : ℕ → Sort u_1}
{n m : ℕ}
(hnm : n ≤ m)
(next : {k : ℕ} → C k → C (k + 1))
(Hnext : ∀ (n : ℕ), Function.Injective next)
:
Function.Injective (leRecOn hnm fun {k : ℕ} => next)
theorem
Nat.leRecOn_surjective
{C : ℕ → Sort u_1}
{n m : ℕ}
(hnm : n ≤ m)
(next : {k : ℕ} → C k → C (k + 1))
(Hnext : ∀ (n : ℕ), Function.Surjective next)
:
Function.Surjective (leRecOn hnm fun {k : ℕ} => next)
theorem
Nat.set_induction_bounded
{n k : ℕ}
{S : Set ℕ}
(hk : k ∈ S)
(h_ind : ∀ k ∈ S, k + 1 ∈ S)
(hnk : k ≤ n)
:
n ∈ S
A subset of ℕ containing k : ℕ and closed under Nat.succ contains every n ≥ k.
A subset of ℕ containing zero and closed under Nat.succ contains all of ℕ.
mod, dvd #
dvd is injective in the left argument