The conversion is a bijection. Here we use the existing capability (from Section 2.1) to map the Mathlib natural numbers to the Chapter 2 natural numbers.
Equations
- Chapter2.Nat.equivNat = { toFun := Chapter2.Nat.toNat, invFun := fun (n : ℕ) => ↑n, left_inv := Chapter2.Nat.equivNat._proof_1, right_inv := Chapter2.Nat.equivNat._proof_2 }
Instances For
Equations
- Chapter2.Nat.equivNat_ordered_ring = { toEquiv := Chapter2.Nat.equivNat, map_mul' := Chapter2.Nat.map_mul, map_add' := Chapter2.Nat.map_add, map_le_map_iff' := ⋯ }
Instances For
The Peano axioms for an abstract type Nat
Instances For
The Chapter 2 natural numbers obey the Peano axioms.
Equations
- PeanoAxioms.Chapter2_Nat = { Nat := Chapter2.Nat, zero := Chapter2.Nat.zero, succ := Chapter2.Nat.succ, succ_ne := Chapter2.Nat.succ_ne, succ_cancel := ⋯, induction := Chapter2.Nat.induction }
Instances For
The Mathlib natural numbers obey the Peano axioms.
Equations
- PeanoAxioms.Mathlib_Nat = { Nat := ℕ, zero := 0, succ := Nat.succ, succ_ne := Nat.succ_ne_zero, succ_cancel := @PeanoAxioms.Mathlib_Nat._proof_1, induction := ⋯ }
Instances For
One can start the proof here with unfold Function.Injective, although it is not strictly necessary.
One can start the proof here with unfold Function.Surjective, although it is not strictly necessary.
This exercise will require application of Mathlib's API for the Equiv class.
Some of this API can be invoked automatically via the simp tactic.
Instances For
This exercise will require application of Mathlib's API for the Equiv class.
Some of this API can be invoked automatically via the simp tactic.
Equations
- equiv1.trans equiv2 = { equiv := PeanoAxioms.Equiv.equiv.trans PeanoAxioms.Equiv.equiv, equiv_zero := ⋯, equiv_succ := ⋯ }
Instances For
Useful Mathlib tools for inverting bijections include Function.surjInv and Function.invFun.
Equations
Instances For
The task here is to establish that any two structures obeying the Peano axioms are equivalent.
Equations
- PeanoAxioms.Equiv.mk' P Q = sorry
Instances For
There is only one equivalence between any two structures obeying the Peano axioms.