url
stringclasses
147 values
commit
stringclasses
147 values
file_path
stringlengths
7
101
full_name
stringlengths
1
94
start
stringlengths
6
10
end
stringlengths
6
11
tactic
stringlengths
1
11.2k
state_before
stringlengths
3
2.09M
state_after
stringlengths
6
2.09M
input
stringlengths
73
2.09M
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.lt_abs
[31, 1]
[50, 15]
linarith
case inr.mpr.inl x y : ℝ h : 0 > y h' : x < y ⊒ x < -y
no goals
Please generate a tactic in lean4 to solve the state. STATE: case inr.mpr.inl x y : ℝ h : 0 > y h' : x < y ⊒ x < -y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.lt_abs
[31, 1]
[50, 15]
exact h'
case inr.mpr.inr x y : ℝ h : 0 > y h' : x < -y ⊒ x < -y
no goals
Please generate a tactic in lean4 to solve the state. STATE: case inr.mpr.inr x y : ℝ h : 0 > y h' : x < -y ⊒ x < -y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
rcases le_or_gt 0 x with h | h
x y : ℝ ⊒ |x| < y ↔ -y < x ∧ x < y
case inl x y : ℝ h : 0 ≀ x ⊒ |x| < y ↔ -y < x ∧ x < y case inr x y : ℝ h : 0 > x ⊒ |x| < y ↔ -y < x ∧ x < y
Please generate a tactic in lean4 to solve the state. STATE: x y : ℝ ⊒ |x| < y ↔ -y < x ∧ x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
rw [abs_of_nonneg h]
case inl x y : ℝ h : 0 ≀ x ⊒ |x| < y ↔ -y < x ∧ x < y
case inl x y : ℝ h : 0 ≀ x ⊒ x < y ↔ -y < x ∧ x < y
Please generate a tactic in lean4 to solve the state. STATE: case inl x y : ℝ h : 0 ≀ x ⊒ |x| < y ↔ -y < x ∧ x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
constructor
case inl x y : ℝ h : 0 ≀ x ⊒ x < y ↔ -y < x ∧ x < y
case inl.mp x y : ℝ h : 0 ≀ x ⊒ x < y β†’ -y < x ∧ x < y case inl.mpr x y : ℝ h : 0 ≀ x ⊒ -y < x ∧ x < y β†’ x < y
Please generate a tactic in lean4 to solve the state. STATE: case inl x y : ℝ h : 0 ≀ x ⊒ x < y ↔ -y < x ∧ x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
. intro h' rcases h' with ⟨h1, h2⟩ exact h2
case inl.mpr x y : ℝ h : 0 ≀ x ⊒ -y < x ∧ x < y β†’ x < y
no goals
Please generate a tactic in lean4 to solve the state. STATE: case inl.mpr x y : ℝ h : 0 ≀ x ⊒ -y < x ∧ x < y β†’ x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
intro h'
case inl.mp x y : ℝ h : 0 ≀ x ⊒ x < y β†’ -y < x ∧ x < y
case inl.mp x y : ℝ h : 0 ≀ x h' : x < y ⊒ -y < x ∧ x < y
Please generate a tactic in lean4 to solve the state. STATE: case inl.mp x y : ℝ h : 0 ≀ x ⊒ x < y β†’ -y < x ∧ x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
constructor
case inl.mp x y : ℝ h : 0 ≀ x h' : x < y ⊒ -y < x ∧ x < y
case inl.mp.left x y : ℝ h : 0 ≀ x h' : x < y ⊒ -y < x case inl.mp.right x y : ℝ h : 0 ≀ x h' : x < y ⊒ x < y
Please generate a tactic in lean4 to solve the state. STATE: case inl.mp x y : ℝ h : 0 ≀ x h' : x < y ⊒ -y < x ∧ x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
exact h'
case inl.mp.right x y : ℝ h : 0 ≀ x h' : x < y ⊒ x < y
no goals
Please generate a tactic in lean4 to solve the state. STATE: case inl.mp.right x y : ℝ h : 0 ≀ x h' : x < y ⊒ x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
linarith
case inl.mp.left x y : ℝ h : 0 ≀ x h' : x < y ⊒ -y < x
no goals
Please generate a tactic in lean4 to solve the state. STATE: case inl.mp.left x y : ℝ h : 0 ≀ x h' : x < y ⊒ -y < x TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
intro h'
case inl.mpr x y : ℝ h : 0 ≀ x ⊒ -y < x ∧ x < y β†’ x < y
case inl.mpr x y : ℝ h : 0 ≀ x h' : -y < x ∧ x < y ⊒ x < y
Please generate a tactic in lean4 to solve the state. STATE: case inl.mpr x y : ℝ h : 0 ≀ x ⊒ -y < x ∧ x < y β†’ x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
rcases h' with ⟨h1, h2⟩
case inl.mpr x y : ℝ h : 0 ≀ x h' : -y < x ∧ x < y ⊒ x < y
case inl.mpr.intro x y : ℝ h : 0 ≀ x h1 : -y < x h2 : x < y ⊒ x < y
Please generate a tactic in lean4 to solve the state. STATE: case inl.mpr x y : ℝ h : 0 ≀ x h' : -y < x ∧ x < y ⊒ x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
exact h2
case inl.mpr.intro x y : ℝ h : 0 ≀ x h1 : -y < x h2 : x < y ⊒ x < y
no goals
Please generate a tactic in lean4 to solve the state. STATE: case inl.mpr.intro x y : ℝ h : 0 ≀ x h1 : -y < x h2 : x < y ⊒ x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
rw [abs_of_neg h]
case inr x y : ℝ h : 0 > x ⊒ |x| < y ↔ -y < x ∧ x < y
case inr x y : ℝ h : 0 > x ⊒ -x < y ↔ -y < x ∧ x < y
Please generate a tactic in lean4 to solve the state. STATE: case inr x y : ℝ h : 0 > x ⊒ |x| < y ↔ -y < x ∧ x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
constructor
case inr x y : ℝ h : 0 > x ⊒ -x < y ↔ -y < x ∧ x < y
case inr.mp x y : ℝ h : 0 > x ⊒ -x < y β†’ -y < x ∧ x < y case inr.mpr x y : ℝ h : 0 > x ⊒ -y < x ∧ x < y β†’ -x < y
Please generate a tactic in lean4 to solve the state. STATE: case inr x y : ℝ h : 0 > x ⊒ -x < y ↔ -y < x ∧ x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
. intro h' linarith
case inr.mpr x y : ℝ h : 0 > x ⊒ -y < x ∧ x < y β†’ -x < y
no goals
Please generate a tactic in lean4 to solve the state. STATE: case inr.mpr x y : ℝ h : 0 > x ⊒ -y < x ∧ x < y β†’ -x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
intro h'
case inr.mp x y : ℝ h : 0 > x ⊒ -x < y β†’ -y < x ∧ x < y
case inr.mp x y : ℝ h : 0 > x h' : -x < y ⊒ -y < x ∧ x < y
Please generate a tactic in lean4 to solve the state. STATE: case inr.mp x y : ℝ h : 0 > x ⊒ -x < y β†’ -y < x ∧ x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
constructor
case inr.mp x y : ℝ h : 0 > x h' : -x < y ⊒ -y < x ∧ x < y
case inr.mp.left x y : ℝ h : 0 > x h' : -x < y ⊒ -y < x case inr.mp.right x y : ℝ h : 0 > x h' : -x < y ⊒ x < y
Please generate a tactic in lean4 to solve the state. STATE: case inr.mp x y : ℝ h : 0 > x h' : -x < y ⊒ -y < x ∧ x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
. linarith
case inr.mp.right x y : ℝ h : 0 > x h' : -x < y ⊒ x < y
no goals
Please generate a tactic in lean4 to solve the state. STATE: case inr.mp.right x y : ℝ h : 0 > x h' : -x < y ⊒ x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
linarith
case inr.mp.left x y : ℝ h : 0 > x h' : -x < y ⊒ -y < x
no goals
Please generate a tactic in lean4 to solve the state. STATE: case inr.mp.left x y : ℝ h : 0 > x h' : -x < y ⊒ -y < x TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
linarith
case inr.mp.right x y : ℝ h : 0 > x h' : -x < y ⊒ x < y
no goals
Please generate a tactic in lean4 to solve the state. STATE: case inr.mp.right x y : ℝ h : 0 > x h' : -x < y ⊒ x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
intro h'
case inr.mpr x y : ℝ h : 0 > x ⊒ -y < x ∧ x < y β†’ -x < y
case inr.mpr x y : ℝ h : 0 > x h' : -y < x ∧ x < y ⊒ -x < y
Please generate a tactic in lean4 to solve the state. STATE: case inr.mpr x y : ℝ h : 0 > x ⊒ -y < x ∧ x < y β†’ -x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C03_Logic/solutions/Solutions_S05_Disjunction.lean
C03S05.MyAbs.abs_lt
[52, 1]
[70, 15]
linarith
case inr.mpr x y : ℝ h : 0 > x h' : -y < x ∧ x < y ⊒ -x < y
no goals
Please generate a tactic in lean4 to solve the state. STATE: case inr.mpr x y : ℝ h : 0 > x h' : -y < x ∧ x < y ⊒ -x < y TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture3after.lean
Lec3After.my_lemma_
[37, 1]
[37, 86]
exact add_left_cancel h
a b c : ℝ h : a + b = a + c ⊒ b = c
no goals
Please generate a tactic in lean4 to solve the state. STATE: a b c : ℝ h : a + b = a + c ⊒ b = c TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C07_Hierarchies/S02_Morphisms.lean
map_inv_of_inv
[75, 1]
[77, 61]
rw [← MonoidHomClassβ‚‚.map_mul, h, MonoidHomClassβ‚‚.map_one]
M N F : Type inst✝² : Monoid M inst✝¹ : Monoid N inst✝ : MonoidHomClassβ‚‚ F M N f : F m m' : M h : m * m' = 1 ⊒ ↑f m * ↑f m' = 1
no goals
Please generate a tactic in lean4 to solve the state. STATE: M N F : Type inst✝² : Monoid M inst✝¹ : Monoid N inst✝ : MonoidHomClassβ‚‚ F M N f : F m m' : M h : m * m' = 1 ⊒ ↑f m * ↑f m' = 1 TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
intro hl hl'
u : β„• β†’ ℝ l l' : ℝ ⊒ SequentialLimit u l β†’ SequentialLimit u l' β†’ l = l'
u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' ⊒ l = l'
Please generate a tactic in lean4 to solve the state. STATE: u : β„• β†’ ℝ l l' : ℝ ⊒ SequentialLimit u l β†’ SequentialLimit u l' β†’ l = l' TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
by_contra hll'
u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' ⊒ l = l'
u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' hll' : Β¬l = l' ⊒ False
Please generate a tactic in lean4 to solve the state. STATE: u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' ⊒ l = l' TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
have : |l - l'| > 0
u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' hll' : Β¬l = l' ⊒ False
case this u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' hll' : Β¬l = l' ⊒ |l - l'| > 0 u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' hll' : Β¬l = l' this : |l - l'| > 0 ⊒ False
Please generate a tactic in lean4 to solve the state. STATE: u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' hll' : Β¬l = l' ⊒ False TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
rw [SequentialLimit] at hl hl'
u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' hll' : Β¬l = l' this : |l - l'| > 0 ⊒ False
u : β„• β†’ ℝ l l' : ℝ hl : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l| < Ξ΅ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 ⊒ False
Please generate a tactic in lean4 to solve the state. STATE: u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' hll' : Β¬l = l' this : |l - l'| > 0 ⊒ False TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
specialize hl (|l - l'| / 2) (by linarith)
u : β„• β†’ ℝ l l' : ℝ hl : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l| < Ξ΅ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 ⊒ False
u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 hl : βˆƒ N, βˆ€ n β‰₯ N, |u n - l| < |l - l'| / 2 ⊒ False
Please generate a tactic in lean4 to solve the state. STATE: u : β„• β†’ ℝ l l' : ℝ hl : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l| < Ξ΅ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 ⊒ False TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
obtain ⟨N, hN⟩ := hl
u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 hl : βˆƒ N, βˆ€ n β‰₯ N, |u n - l| < |l - l'| / 2 ⊒ False
case intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N : β„• hN : βˆ€ n β‰₯ N, |u n - l| < |l - l'| / 2 ⊒ False
Please generate a tactic in lean4 to solve the state. STATE: u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 hl : βˆƒ N, βˆ€ n β‰₯ N, |u n - l| < |l - l'| / 2 ⊒ False TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
obtain ⟨N', hN'⟩ := hl' (|l - l'| / 2) (by linarith)
case intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N : β„• hN : βˆ€ n β‰₯ N, |u n - l| < |l - l'| / 2 ⊒ False
case intro.intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N : β„• hN : βˆ€ n β‰₯ N, |u n - l| < |l - l'| / 2 N' : β„• hN' : βˆ€ n β‰₯ N', |u n - l'| < |l - l'| / 2 ⊒ False
Please generate a tactic in lean4 to solve the state. STATE: case intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N : β„• hN : βˆ€ n β‰₯ N, |u n - l| < |l - l'| / 2 ⊒ False TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
let Nβ‚€ := max N N'
case intro.intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N : β„• hN : βˆ€ n β‰₯ N, |u n - l| < |l - l'| / 2 N' : β„• hN' : βˆ€ n β‰₯ N', |u n - l'| < |l - l'| / 2 ⊒ False
case intro.intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N : β„• hN : βˆ€ n β‰₯ N, |u n - l| < |l - l'| / 2 N' : β„• hN' : βˆ€ n β‰₯ N', |u n - l'| < |l - l'| / 2 Nβ‚€ : β„• := max N N' ⊒ False
Please generate a tactic in lean4 to solve the state. STATE: case intro.intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N : β„• hN : βˆ€ n β‰₯ N, |u n - l| < |l - l'| / 2 N' : β„• hN' : βˆ€ n β‰₯ N', |u n - l'| < |l - l'| / 2 ⊒ False TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
specialize hN Nβ‚€ (Nat.le_max_left N N')
case intro.intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N : β„• hN : βˆ€ n β‰₯ N, |u n - l| < |l - l'| / 2 N' : β„• hN' : βˆ€ n β‰₯ N', |u n - l'| < |l - l'| / 2 Nβ‚€ : β„• := max N N' ⊒ False
case intro.intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N N' : β„• hN' : βˆ€ n β‰₯ N', |u n - l'| < |l - l'| / 2 Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 ⊒ False
Please generate a tactic in lean4 to solve the state. STATE: case intro.intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N : β„• hN : βˆ€ n β‰₯ N, |u n - l| < |l - l'| / 2 N' : β„• hN' : βˆ€ n β‰₯ N', |u n - l'| < |l - l'| / 2 Nβ‚€ : β„• := max N N' ⊒ False TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
specialize hN' Nβ‚€ (Nat.le_max_right N N')
case intro.intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N N' : β„• hN' : βˆ€ n β‰₯ N', |u n - l'| < |l - l'| / 2 Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 ⊒ False
case intro.intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N N' : β„• Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 hN' : |u Nβ‚€ - l'| < |l - l'| / 2 ⊒ False
Please generate a tactic in lean4 to solve the state. STATE: case intro.intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N N' : β„• hN' : βˆ€ n β‰₯ N', |u n - l'| < |l - l'| / 2 Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 ⊒ False TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
have : |l - l'| < |l - l'| := by calc |l - l'| = |l - u Nβ‚€ + (u Nβ‚€ - l')| := by ring _ ≀ |l - u Nβ‚€| + |u Nβ‚€ - l'| := by exact abs_add (l - u Nβ‚€) (u Nβ‚€ - l') _ = |u Nβ‚€ - l| + |u Nβ‚€ - l'| := by rw [abs_sub_comm] _ < |l - l'| := by linarith
case intro.intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N N' : β„• Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 hN' : |u Nβ‚€ - l'| < |l - l'| / 2 ⊒ False
case intro.intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this✝ : |l - l'| > 0 N N' : β„• Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 hN' : |u Nβ‚€ - l'| < |l - l'| / 2 this : |l - l'| < |l - l'| ⊒ False
Please generate a tactic in lean4 to solve the state. STATE: case intro.intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N N' : β„• Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 hN' : |u Nβ‚€ - l'| < |l - l'| / 2 ⊒ False TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
linarith
case intro.intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this✝ : |l - l'| > 0 N N' : β„• Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 hN' : |u Nβ‚€ - l'| < |l - l'| / 2 this : |l - l'| < |l - l'| ⊒ False
no goals
Please generate a tactic in lean4 to solve the state. STATE: case intro.intro u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this✝ : |l - l'| > 0 N N' : β„• Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 hN' : |u Nβ‚€ - l'| < |l - l'| / 2 this : |l - l'| < |l - l'| ⊒ False TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
apply abs_pos.2
case this u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' hll' : Β¬l = l' ⊒ |l - l'| > 0
case this u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' hll' : Β¬l = l' ⊒ l - l' β‰  0
Please generate a tactic in lean4 to solve the state. STATE: case this u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' hll' : Β¬l = l' ⊒ |l - l'| > 0 TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
apply sub_ne_zero.2
case this u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' hll' : Β¬l = l' ⊒ l - l' β‰  0
case this u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' hll' : Β¬l = l' ⊒ l β‰  l'
Please generate a tactic in lean4 to solve the state. STATE: case this u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' hll' : Β¬l = l' ⊒ l - l' β‰  0 TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
exact hll'
case this u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' hll' : Β¬l = l' ⊒ l β‰  l'
no goals
Please generate a tactic in lean4 to solve the state. STATE: case this u : β„• β†’ ℝ l l' : ℝ hl : SequentialLimit u l hl' : SequentialLimit u l' hll' : Β¬l = l' ⊒ l β‰  l' TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
linarith
u : β„• β†’ ℝ l l' : ℝ hl : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l| < Ξ΅ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 ⊒ |l - l'| / 2 > 0
no goals
Please generate a tactic in lean4 to solve the state. STATE: u : β„• β†’ ℝ l l' : ℝ hl : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l| < Ξ΅ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 ⊒ |l - l'| / 2 > 0 TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
linarith
u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N : β„• hN : βˆ€ n β‰₯ N, |u n - l| < |l - l'| / 2 ⊒ |l - l'| / 2 > 0
no goals
Please generate a tactic in lean4 to solve the state. STATE: u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N : β„• hN : βˆ€ n β‰₯ N, |u n - l| < |l - l'| / 2 ⊒ |l - l'| / 2 > 0 TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
calc |l - l'| = |l - u Nβ‚€ + (u Nβ‚€ - l')| := by ring _ ≀ |l - u Nβ‚€| + |u Nβ‚€ - l'| := by exact abs_add (l - u Nβ‚€) (u Nβ‚€ - l') _ = |u Nβ‚€ - l| + |u Nβ‚€ - l'| := by rw [abs_sub_comm] _ < |l - l'| := by linarith
u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N N' : β„• Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 hN' : |u Nβ‚€ - l'| < |l - l'| / 2 ⊒ |l - l'| < |l - l'|
no goals
Please generate a tactic in lean4 to solve the state. STATE: u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N N' : β„• Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 hN' : |u Nβ‚€ - l'| < |l - l'| / 2 ⊒ |l - l'| < |l - l'| TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
ring
u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N N' : β„• Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 hN' : |u Nβ‚€ - l'| < |l - l'| / 2 ⊒ |l - l'| = |l - u Nβ‚€ + (u Nβ‚€ - l')|
no goals
Please generate a tactic in lean4 to solve the state. STATE: u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N N' : β„• Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 hN' : |u Nβ‚€ - l'| < |l - l'| / 2 ⊒ |l - l'| = |l - u Nβ‚€ + (u Nβ‚€ - l')| TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
exact abs_add (l - u Nβ‚€) (u Nβ‚€ - l')
u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N N' : β„• Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 hN' : |u Nβ‚€ - l'| < |l - l'| / 2 ⊒ |l - u Nβ‚€ + (u Nβ‚€ - l')| ≀ |l - u Nβ‚€| + |u Nβ‚€ - l'|
no goals
Please generate a tactic in lean4 to solve the state. STATE: u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N N' : β„• Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 hN' : |u Nβ‚€ - l'| < |l - l'| / 2 ⊒ |l - u Nβ‚€ + (u Nβ‚€ - l')| ≀ |l - u Nβ‚€| + |u Nβ‚€ - l'| TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
rw [abs_sub_comm]
u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N N' : β„• Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 hN' : |u Nβ‚€ - l'| < |l - l'| / 2 ⊒ |l - u Nβ‚€| + |u Nβ‚€ - l'| = |u Nβ‚€ - l| + |u Nβ‚€ - l'|
no goals
Please generate a tactic in lean4 to solve the state. STATE: u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N N' : β„• Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 hN' : |u Nβ‚€ - l'| < |l - l'| / 2 ⊒ |l - u Nβ‚€| + |u Nβ‚€ - l'| = |u Nβ‚€ - l| + |u Nβ‚€ - l'| TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
sequentialLimit_unique
[128, 1]
[150, 2]
linarith
u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N N' : β„• Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 hN' : |u Nβ‚€ - l'| < |l - l'| / 2 ⊒ |u Nβ‚€ - l| + |u Nβ‚€ - l'| < |l - l'|
no goals
Please generate a tactic in lean4 to solve the state. STATE: u : β„• β†’ ℝ l l' : ℝ hl' : βˆ€ Ξ΅ > 0, βˆƒ N, βˆ€ n β‰₯ N, |u n - l'| < Ξ΅ hll' : Β¬l = l' this : |l - l'| > 0 N N' : β„• Nβ‚€ : β„• := max N N' hN : |u Nβ‚€ - l| < |l - l'| / 2 hN' : |u Nβ‚€ - l'| < |l - l'| / 2 ⊒ |u Nβ‚€ - l| + |u Nβ‚€ - l'| < |l - l'| TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
convergesTo_const
[161, 1]
[161, 80]
sorry
a : ℝ ⊒ SequentialLimit (fun n => a) a
no goals
Please generate a tactic in lean4 to solve the state. STATE: a : ℝ ⊒ SequentialLimit (fun n => a) a TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture5.lean
SequentialLimit.add
[164, 1]
[166, 60]
sorry
s t : β„• β†’ ℝ a b : ℝ hs : SequentialLimit s a ht : SequentialLimit t b ⊒ SequentialLimit (fun n => s n + t n) (a + b)
no goals
Please generate a tactic in lean4 to solve the state. STATE: s t : β„• β†’ ℝ a b : ℝ hs : SequentialLimit s a ht : SequentialLimit t b ⊒ SequentialLimit (fun n => s n + t n) (a + b) TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture2.lean
inverse_of_a_commutator
[93, 1]
[102, 2]
rw [commutatorElement_def, commutatorElement_def]
G : Type u_1 inst✝ : Group G g h : G ⊒ ⁅g, h⁆⁻¹ = ⁅h, g⁆
G : Type u_1 inst✝ : Group G g h : G ⊒ (g * h * g⁻¹ * h⁻¹)⁻¹ = h * g * h⁻¹ * g⁻¹
Please generate a tactic in lean4 to solve the state. STATE: G : Type u_1 inst✝ : Group G g h : G ⊒ ⁅g, h⁆⁻¹ = ⁅h, g⁆ TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture2.lean
inverse_of_a_commutator
[93, 1]
[102, 2]
rw [mul_inv_rev (g * h * g⁻¹) h⁻¹]
G : Type u_1 inst✝ : Group G g h : G ⊒ (g * h * g⁻¹ * h⁻¹)⁻¹ = h * g * h⁻¹ * g⁻¹
G : Type u_1 inst✝ : Group G g h : G ⊒ h⁻¹⁻¹ * (g * h * g⁻¹)⁻¹ = h * g * h⁻¹ * g⁻¹
Please generate a tactic in lean4 to solve the state. STATE: G : Type u_1 inst✝ : Group G g h : G ⊒ (g * h * g⁻¹ * h⁻¹)⁻¹ = h * g * h⁻¹ * g⁻¹ TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture2.lean
inverse_of_a_commutator
[93, 1]
[102, 2]
rw [mul_inv_rev]
G : Type u_1 inst✝ : Group G g h : G ⊒ h⁻¹⁻¹ * (g * h * g⁻¹)⁻¹ = h * g * h⁻¹ * g⁻¹
G : Type u_1 inst✝ : Group G g h : G ⊒ h⁻¹⁻¹ * (g⁻¹⁻¹ * (g * h)⁻¹) = h * g * h⁻¹ * g⁻¹
Please generate a tactic in lean4 to solve the state. STATE: G : Type u_1 inst✝ : Group G g h : G ⊒ h⁻¹⁻¹ * (g * h * g⁻¹)⁻¹ = h * g * h⁻¹ * g⁻¹ TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture2.lean
inverse_of_a_commutator
[93, 1]
[102, 2]
rw [mul_inv_rev]
G : Type u_1 inst✝ : Group G g h : G ⊒ h⁻¹⁻¹ * (g⁻¹⁻¹ * (g * h)⁻¹) = h * g * h⁻¹ * g⁻¹
G : Type u_1 inst✝ : Group G g h : G ⊒ h⁻¹⁻¹ * (g⁻¹⁻¹ * (h⁻¹ * g⁻¹)) = h * g * h⁻¹ * g⁻¹
Please generate a tactic in lean4 to solve the state. STATE: G : Type u_1 inst✝ : Group G g h : G ⊒ h⁻¹⁻¹ * (g⁻¹⁻¹ * (g * h)⁻¹) = h * g * h⁻¹ * g⁻¹ TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture2.lean
inverse_of_a_commutator
[93, 1]
[102, 2]
rw [inv_inv, inv_inv]
G : Type u_1 inst✝ : Group G g h : G ⊒ h⁻¹⁻¹ * (g⁻¹⁻¹ * (h⁻¹ * g⁻¹)) = h * g * h⁻¹ * g⁻¹
G : Type u_1 inst✝ : Group G g h : G ⊒ h * (g * (h⁻¹ * g⁻¹)) = h * g * h⁻¹ * g⁻¹
Please generate a tactic in lean4 to solve the state. STATE: G : Type u_1 inst✝ : Group G g h : G ⊒ h⁻¹⁻¹ * (g⁻¹⁻¹ * (h⁻¹ * g⁻¹)) = h * g * h⁻¹ * g⁻¹ TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture2.lean
inverse_of_a_commutator
[93, 1]
[102, 2]
rw [mul_assoc]
G : Type u_1 inst✝ : Group G g h : G ⊒ h * (g * (h⁻¹ * g⁻¹)) = h * g * h⁻¹ * g⁻¹
G : Type u_1 inst✝ : Group G g h : G ⊒ h * (g * (h⁻¹ * g⁻¹)) = h * g * (h⁻¹ * g⁻¹)
Please generate a tactic in lean4 to solve the state. STATE: G : Type u_1 inst✝ : Group G g h : G ⊒ h * (g * (h⁻¹ * g⁻¹)) = h * g * h⁻¹ * g⁻¹ TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture2.lean
inverse_of_a_commutator
[93, 1]
[102, 2]
rw [mul_assoc]
G : Type u_1 inst✝ : Group G g h : G ⊒ h * (g * (h⁻¹ * g⁻¹)) = h * g * (h⁻¹ * g⁻¹)
no goals
Please generate a tactic in lean4 to solve the state. STATE: G : Type u_1 inst✝ : Group G g h : G ⊒ h * (g * (h⁻¹ * g⁻¹)) = h * g * (h⁻¹ * g⁻¹) TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture16Before.lean
my_equality
[31, 1]
[35, 8]
have c := a + b
a b : β„• ⊒ a + b + a ≀ 2 * (a + b)
a b c : β„• ⊒ a + b + a ≀ 2 * (a + b)
Please generate a tactic in lean4 to solve the state. STATE: a b : β„• ⊒ a + b + a ≀ 2 * (a + b) TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture16Before.lean
my_equality
[31, 1]
[35, 8]
have h : c = a + b := sorry
a b c : β„• ⊒ a + b + a ≀ 2 * (a + b)
a b c : β„• h : c = a + b ⊒ a + b + a ≀ 2 * (a + b)
Please generate a tactic in lean4 to solve the state. STATE: a b c : β„• ⊒ a + b + a ≀ 2 * (a + b) TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture16Before.lean
my_equality
[31, 1]
[35, 8]
rw [← h]
a b c : β„• h : c = a + b ⊒ a + b + a ≀ 2 * (a + b)
a b c : β„• h : c = a + b ⊒ c + a ≀ 2 * c
Please generate a tactic in lean4 to solve the state. STATE: a b c : β„• h : c = a + b ⊒ a + b + a ≀ 2 * (a + b) TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture16Before.lean
my_equality
[31, 1]
[35, 8]
sorry
a b c : β„• h : c = a + b ⊒ c + a ≀ 2 * c
no goals
Please generate a tactic in lean4 to solve the state. STATE: a b c : β„• h : c = a + b ⊒ c + a ≀ 2 * c TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Lectures/Lecture16Before.lean
my_lemma
[119, 1]
[121, 53]
rw [Nat.add_succ, my_lemma n]
n : β„• ⊒ 0 + Nat.succ n = Nat.succ n + 0
no goals
Please generate a tactic in lean4 to solve the state. STATE: n : β„• ⊒ 0 + Nat.succ n = Nat.succ n + 0 TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Common.lean
pow_self_ne_zero
[151, 1]
[154, 15]
by_cases hn : n = 0
n : β„• ⊒ n ^ n β‰  0
case pos n : β„• hn : n = 0 ⊒ n ^ n β‰  0 case neg n : β„• hn : Β¬n = 0 ⊒ n ^ n β‰  0
Please generate a tactic in lean4 to solve the state. STATE: n : β„• ⊒ n ^ n β‰  0 TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Common.lean
pow_self_ne_zero
[151, 1]
[154, 15]
simp [hn]
case pos n : β„• hn : n = 0 ⊒ n ^ n β‰  0
no goals
Please generate a tactic in lean4 to solve the state. STATE: case pos n : β„• hn : n = 0 ⊒ n ^ n β‰  0 TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/Common.lean
pow_self_ne_zero
[151, 1]
[154, 15]
positivity
case neg n : β„• hn : Β¬n = 0 ⊒ n ^ n β‰  0
no goals
Please generate a tactic in lean4 to solve the state. STATE: case neg n : β„• hn : Β¬n = 0 ⊒ n ^ n β‰  0 TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.two_le
[9, 1]
[14, 18]
cases m
m : β„• h0 : m β‰  0 h1 : m β‰  1 ⊒ 2 ≀ m
case zero h0 : 0 β‰  0 h1 : 0 β‰  1 ⊒ 2 ≀ 0 case succ n✝ : β„• h0 : n✝ + 1 β‰  0 h1 : n✝ + 1 β‰  1 a✝ : n✝ + 1 = n✝ β†’ 2 ≀ n✝ + 1 ⊒ 2 ≀ n✝ + 1
Please generate a tactic in lean4 to solve the state. STATE: m : β„• h0 : m β‰  0 h1 : m β‰  1 ⊒ 2 ≀ m TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.two_le
[9, 1]
[14, 18]
contradiction
case zero h0 : 0 β‰  0 h1 : 0 β‰  1 ⊒ 2 ≀ 0 case succ n✝ : β„• h0 : n✝ + 1 β‰  0 h1 : n✝ + 1 β‰  1 a✝ : n✝ + 1 = n✝ β†’ 2 ≀ n✝ + 1 ⊒ 2 ≀ n✝ + 1
case succ n✝ : β„• h0 : n✝ + 1 β‰  0 h1 : n✝ + 1 β‰  1 a✝ : n✝ + 1 = n✝ β†’ 2 ≀ n✝ + 1 ⊒ 2 ≀ n✝ + 1
Please generate a tactic in lean4 to solve the state. STATE: case zero h0 : 0 β‰  0 h1 : 0 β‰  1 ⊒ 2 ≀ 0 case succ n✝ : β„• h0 : n✝ + 1 β‰  0 h1 : n✝ + 1 β‰  1 a✝ : n✝ + 1 = n✝ β†’ 2 ≀ n✝ + 1 ⊒ 2 ≀ n✝ + 1 TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.two_le
[9, 1]
[14, 18]
case succ m hm => cases m; contradiction repeat' apply Nat.succ_le_succ apply zero_le
m : β„• h0 : m + 1 β‰  0 h1 : m + 1 β‰  1 hm : m + 1 = m β†’ 2 ≀ m + 1 ⊒ 2 ≀ m + 1
no goals
Please generate a tactic in lean4 to solve the state. STATE: m : β„• h0 : m + 1 β‰  0 h1 : m + 1 β‰  1 hm : m + 1 = m β†’ 2 ≀ m + 1 ⊒ 2 ≀ m + 1 TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.two_le
[9, 1]
[14, 18]
cases m
m : β„• h0 : m + 1 β‰  0 h1 : m + 1 β‰  1 hm : m + 1 = m β†’ 2 ≀ m + 1 ⊒ 2 ≀ m + 1
case zero h0 : 0 + 1 β‰  0 h1 : 0 + 1 β‰  1 hm : 0 + 1 = 0 β†’ 2 ≀ 0 + 1 ⊒ 2 ≀ 0 + 1 case succ n✝ : β„• h0 : n✝ + 1 + 1 β‰  0 h1 : n✝ + 1 + 1 β‰  1 hm : n✝ + 1 + 1 = n✝ + 1 β†’ 2 ≀ n✝ + 1 + 1 a✝ : n✝ + 1 = n✝ β†’ 2 ≀ n✝ + 1 + 1 ⊒ 2 ≀ n✝ + 1 + 1
Please generate a tactic in lean4 to solve the state. STATE: m : β„• h0 : m + 1 β‰  0 h1 : m + 1 β‰  1 hm : m + 1 = m β†’ 2 ≀ m + 1 ⊒ 2 ≀ m + 1 TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.two_le
[9, 1]
[14, 18]
contradiction
case zero h0 : 0 + 1 β‰  0 h1 : 0 + 1 β‰  1 hm : 0 + 1 = 0 β†’ 2 ≀ 0 + 1 ⊒ 2 ≀ 0 + 1 case succ n✝ : β„• h0 : n✝ + 1 + 1 β‰  0 h1 : n✝ + 1 + 1 β‰  1 hm : n✝ + 1 + 1 = n✝ + 1 β†’ 2 ≀ n✝ + 1 + 1 a✝ : n✝ + 1 = n✝ β†’ 2 ≀ n✝ + 1 + 1 ⊒ 2 ≀ n✝ + 1 + 1
case succ n✝ : β„• h0 : n✝ + 1 + 1 β‰  0 h1 : n✝ + 1 + 1 β‰  1 hm : n✝ + 1 + 1 = n✝ + 1 β†’ 2 ≀ n✝ + 1 + 1 a✝ : n✝ + 1 = n✝ β†’ 2 ≀ n✝ + 1 + 1 ⊒ 2 ≀ n✝ + 1 + 1
Please generate a tactic in lean4 to solve the state. STATE: case zero h0 : 0 + 1 β‰  0 h1 : 0 + 1 β‰  1 hm : 0 + 1 = 0 β†’ 2 ≀ 0 + 1 ⊒ 2 ≀ 0 + 1 case succ n✝ : β„• h0 : n✝ + 1 + 1 β‰  0 h1 : n✝ + 1 + 1 β‰  1 hm : n✝ + 1 + 1 = n✝ + 1 β†’ 2 ≀ n✝ + 1 + 1 a✝ : n✝ + 1 = n✝ β†’ 2 ≀ n✝ + 1 + 1 ⊒ 2 ≀ n✝ + 1 + 1 TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.two_le
[9, 1]
[14, 18]
repeat' apply Nat.succ_le_succ
case succ n✝ : β„• h0 : n✝ + 1 + 1 β‰  0 h1 : n✝ + 1 + 1 β‰  1 hm : n✝ + 1 + 1 = n✝ + 1 β†’ 2 ≀ n✝ + 1 + 1 a✝ : n✝ + 1 = n✝ β†’ 2 ≀ n✝ + 1 + 1 ⊒ 2 ≀ n✝ + 1 + 1
case succ.a.a n✝ : β„• h0 : n✝ + 1 + 1 β‰  0 h1 : n✝ + 1 + 1 β‰  1 hm : n✝ + 1 + 1 = n✝ + 1 β†’ 2 ≀ n✝ + 1 + 1 a✝ : n✝ + 1 = n✝ β†’ 2 ≀ n✝ + 1 + 1 ⊒ 0 ≀ n✝
Please generate a tactic in lean4 to solve the state. STATE: case succ n✝ : β„• h0 : n✝ + 1 + 1 β‰  0 h1 : n✝ + 1 + 1 β‰  1 hm : n✝ + 1 + 1 = n✝ + 1 β†’ 2 ≀ n✝ + 1 + 1 a✝ : n✝ + 1 = n✝ β†’ 2 ≀ n✝ + 1 + 1 ⊒ 2 ≀ n✝ + 1 + 1 TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.two_le
[9, 1]
[14, 18]
apply zero_le
case succ.a.a n✝ : β„• h0 : n✝ + 1 + 1 β‰  0 h1 : n✝ + 1 + 1 β‰  1 hm : n✝ + 1 + 1 = n✝ + 1 β†’ 2 ≀ n✝ + 1 + 1 a✝ : n✝ + 1 = n✝ β†’ 2 ≀ n✝ + 1 + 1 ⊒ 0 ≀ n✝
no goals
Please generate a tactic in lean4 to solve the state. STATE: case succ.a.a n✝ : β„• h0 : n✝ + 1 + 1 β‰  0 h1 : n✝ + 1 + 1 β‰  1 hm : n✝ + 1 + 1 = n✝ + 1 β†’ 2 ≀ n✝ + 1 + 1 a✝ : n✝ + 1 = n✝ β†’ 2 ≀ n✝ + 1 + 1 ⊒ 0 ≀ n✝ TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.two_le
[9, 1]
[14, 18]
apply Nat.succ_le_succ
case succ.a n✝ : β„• h0 : n✝ + 1 + 1 β‰  0 h1 : n✝ + 1 + 1 β‰  1 hm : n✝ + 1 + 1 = n✝ + 1 β†’ 2 ≀ n✝ + 1 + 1 a✝ : n✝ + 1 = n✝ β†’ 2 ≀ n✝ + 1 + 1 ⊒ 1 ≀ n✝ + 1
case succ.a.a n✝ : β„• h0 : n✝ + 1 + 1 β‰  0 h1 : n✝ + 1 + 1 β‰  1 hm : n✝ + 1 + 1 = n✝ + 1 β†’ 2 ≀ n✝ + 1 + 1 a✝ : n✝ + 1 = n✝ β†’ 2 ≀ n✝ + 1 + 1 ⊒ 0 ≀ n✝
Please generate a tactic in lean4 to solve the state. STATE: case succ.a n✝ : β„• h0 : n✝ + 1 + 1 β‰  0 h1 : n✝ + 1 + 1 β‰  1 hm : n✝ + 1 + 1 = n✝ + 1 β†’ 2 ≀ n✝ + 1 + 1 a✝ : n✝ + 1 = n✝ β†’ 2 ≀ n✝ + 1 + 1 ⊒ 1 ≀ n✝ + 1 TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.exists_prime_factor
[28, 1]
[44, 27]
by_cases np : n.Prime
n : β„• h : 2 ≀ n ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
case pos n : β„• h : 2 ≀ n np : Nat.Prime n ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n case neg n : β„• h : 2 ≀ n np : Β¬Nat.Prime n ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
Please generate a tactic in lean4 to solve the state. STATE: n : β„• h : 2 ≀ n ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.exists_prime_factor
[28, 1]
[44, 27]
induction' n using Nat.strong_induction_on with n ih
case neg n : β„• h : 2 ≀ n np : Β¬Nat.Prime n ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
case neg.h n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : Β¬Nat.Prime n ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
Please generate a tactic in lean4 to solve the state. STATE: case neg n : β„• h : 2 ≀ n np : Β¬Nat.Prime n ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.exists_prime_factor
[28, 1]
[44, 27]
rw [Nat.prime_def_lt] at np
case neg.h n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : Β¬Nat.Prime n ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
case neg.h n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : Β¬(2 ≀ n ∧ βˆ€ m < n, m ∣ n β†’ m = 1) ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
Please generate a tactic in lean4 to solve the state. STATE: case neg.h n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : Β¬Nat.Prime n ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.exists_prime_factor
[28, 1]
[44, 27]
push_neg at np
case neg.h n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : Β¬(2 ≀ n ∧ βˆ€ m < n, m ∣ n β†’ m = 1) ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
case neg.h n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
Please generate a tactic in lean4 to solve the state. STATE: case neg.h n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : Β¬(2 ≀ n ∧ βˆ€ m < n, m ∣ n β†’ m = 1) ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.exists_prime_factor
[28, 1]
[44, 27]
rcases np h with ⟨m, mltn, mdvdn, mne1⟩
case neg.h n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
case neg.h.intro.intro.intro n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
Please generate a tactic in lean4 to solve the state. STATE: case neg.h n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.exists_prime_factor
[28, 1]
[44, 27]
have : m β‰  0 := by intro mz rw [mz, zero_dvd_iff] at mdvdn linarith
case neg.h.intro.intro.intro n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
case neg.h.intro.intro.intro n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
Please generate a tactic in lean4 to solve the state. STATE: case neg.h.intro.intro.intro n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.exists_prime_factor
[28, 1]
[44, 27]
have mgt2 : 2 ≀ m := two_le this mne1
case neg.h.intro.intro.intro n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
case neg.h.intro.intro.intro n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 mgt2 : 2 ≀ m ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
Please generate a tactic in lean4 to solve the state. STATE: case neg.h.intro.intro.intro n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.exists_prime_factor
[28, 1]
[44, 27]
by_cases mp : m.Prime
case neg.h.intro.intro.intro n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 mgt2 : 2 ≀ m ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
case pos n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 mgt2 : 2 ≀ m mp : Nat.Prime m ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n case neg n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 mgt2 : 2 ≀ m mp : Β¬Nat.Prime m ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
Please generate a tactic in lean4 to solve the state. STATE: case neg.h.intro.intro.intro n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 mgt2 : 2 ≀ m ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.exists_prime_factor
[28, 1]
[44, 27]
. rcases ih m mltn mgt2 mp with ⟨p, pp, pdvd⟩ use p, pp apply pdvd.trans mdvdn
case neg n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 mgt2 : 2 ≀ m mp : Β¬Nat.Prime m ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
no goals
Please generate a tactic in lean4 to solve the state. STATE: case neg n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 mgt2 : 2 ≀ m mp : Β¬Nat.Prime m ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.exists_prime_factor
[28, 1]
[44, 27]
use n, np
case pos n : β„• h : 2 ≀ n np : Nat.Prime n ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
no goals
Please generate a tactic in lean4 to solve the state. STATE: case pos n : β„• h : 2 ≀ n np : Nat.Prime n ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.exists_prime_factor
[28, 1]
[44, 27]
intro mz
n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 ⊒ m β‰  0
n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 mz : m = 0 ⊒ False
Please generate a tactic in lean4 to solve the state. STATE: n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 ⊒ m β‰  0 TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.exists_prime_factor
[28, 1]
[44, 27]
rw [mz, zero_dvd_iff] at mdvdn
n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 mz : m = 0 ⊒ False
n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : n = 0 mne1 : m β‰  1 mz : m = 0 ⊒ False
Please generate a tactic in lean4 to solve the state. STATE: n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 mz : m = 0 ⊒ False TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.exists_prime_factor
[28, 1]
[44, 27]
linarith
n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : n = 0 mne1 : m β‰  1 mz : m = 0 ⊒ False
no goals
Please generate a tactic in lean4 to solve the state. STATE: n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : n = 0 mne1 : m β‰  1 mz : m = 0 ⊒ False TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.exists_prime_factor
[28, 1]
[44, 27]
use m, mp
case pos n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 mgt2 : 2 ≀ m mp : Nat.Prime m ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
no goals
Please generate a tactic in lean4 to solve the state. STATE: case pos n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 mgt2 : 2 ≀ m mp : Nat.Prime m ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.exists_prime_factor
[28, 1]
[44, 27]
rcases ih m mltn mgt2 mp with ⟨p, pp, pdvd⟩
case neg n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 mgt2 : 2 ≀ m mp : Β¬Nat.Prime m ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
case neg.intro.intro n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 mgt2 : 2 ≀ m mp : Β¬Nat.Prime m p : β„• pp : Nat.Prime p pdvd : p ∣ m ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
Please generate a tactic in lean4 to solve the state. STATE: case neg n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 mgt2 : 2 ≀ m mp : Β¬Nat.Prime m ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.exists_prime_factor
[28, 1]
[44, 27]
use p, pp
case neg.intro.intro n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 mgt2 : 2 ≀ m mp : Β¬Nat.Prime m p : β„• pp : Nat.Prime p pdvd : p ∣ m ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n
case right n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 mgt2 : 2 ≀ m mp : Β¬Nat.Prime m p : β„• pp : Nat.Prime p pdvd : p ∣ m ⊒ p ∣ n
Please generate a tactic in lean4 to solve the state. STATE: case neg.intro.intro n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 mgt2 : 2 ≀ m mp : Β¬Nat.Prime m p : β„• pp : Nat.Prime p pdvd : p ∣ m ⊒ βˆƒ p, Nat.Prime p ∧ p ∣ n TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.exists_prime_factor
[28, 1]
[44, 27]
apply pdvd.trans mdvdn
case right n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 mgt2 : 2 ≀ m mp : Β¬Nat.Prime m p : β„• pp : Nat.Prime p pdvd : p ∣ m ⊒ p ∣ n
no goals
Please generate a tactic in lean4 to solve the state. STATE: case right n : β„• ih : βˆ€ m < n, 2 ≀ m β†’ Β¬Nat.Prime m β†’ βˆƒ p, Nat.Prime p ∧ p ∣ m h : 2 ≀ n np : 2 ≀ n β†’ βˆƒ m < n, m ∣ n ∧ m β‰  1 m : β„• mltn : m < n mdvdn : m ∣ n mne1 : m β‰  1 this : m β‰  0 mgt2 : 2 ≀ m mp : Β¬Nat.Prime m p : β„• pp : Nat.Prime p pdvd : p ∣ m ⊒ p ∣ n TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.primes_infinite
[46, 1]
[60, 8]
intro n
⊒ βˆ€ (n : β„•), βˆƒ p > n, Nat.Prime p
n : β„• ⊒ βˆƒ p > n, Nat.Prime p
Please generate a tactic in lean4 to solve the state. STATE: ⊒ βˆ€ (n : β„•), βˆƒ p > n, Nat.Prime p TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.primes_infinite
[46, 1]
[60, 8]
have : 2 ≀ Nat.factorial (n + 1) + 1 := by sorry
n : β„• ⊒ βˆƒ p > n, Nat.Prime p
n : β„• this : 2 ≀ Nat.factorial (n + 1) + 1 ⊒ βˆƒ p > n, Nat.Prime p
Please generate a tactic in lean4 to solve the state. STATE: n : β„• ⊒ βˆƒ p > n, Nat.Prime p TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.primes_infinite
[46, 1]
[60, 8]
rcases exists_prime_factor this with ⟨p, pp, pdvd⟩
n : β„• this : 2 ≀ Nat.factorial (n + 1) + 1 ⊒ βˆƒ p > n, Nat.Prime p
case intro.intro n : β„• this : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ⊒ βˆƒ p > n, Nat.Prime p
Please generate a tactic in lean4 to solve the state. STATE: n : β„• this : 2 ≀ Nat.factorial (n + 1) + 1 ⊒ βˆƒ p > n, Nat.Prime p TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.primes_infinite
[46, 1]
[60, 8]
refine' ⟨p, _, pp⟩
case intro.intro n : β„• this : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ⊒ βˆƒ p > n, Nat.Prime p
case intro.intro n : β„• this : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ⊒ p > n
Please generate a tactic in lean4 to solve the state. STATE: case intro.intro n : β„• this : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ⊒ βˆƒ p > n, Nat.Prime p TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.primes_infinite
[46, 1]
[60, 8]
by_contra ple
case intro.intro n : β„• this : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ⊒ p > n
case intro.intro n : β„• this : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ple : Β¬p > n ⊒ False
Please generate a tactic in lean4 to solve the state. STATE: case intro.intro n : β„• this : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ⊒ p > n TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.primes_infinite
[46, 1]
[60, 8]
push_neg at ple
case intro.intro n : β„• this : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ple : Β¬p > n ⊒ False
case intro.intro n : β„• this : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ple : p ≀ n ⊒ False
Please generate a tactic in lean4 to solve the state. STATE: case intro.intro n : β„• this : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ple : Β¬p > n ⊒ False TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.primes_infinite
[46, 1]
[60, 8]
have : p ∣ Nat.factorial (n + 1) := by sorry
case intro.intro n : β„• this : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ple : p ≀ n ⊒ False
case intro.intro n : β„• this✝ : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ple : p ≀ n this : p ∣ Nat.factorial (n + 1) ⊒ False
Please generate a tactic in lean4 to solve the state. STATE: case intro.intro n : β„• this : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ple : p ≀ n ⊒ False TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.primes_infinite
[46, 1]
[60, 8]
have : p ∣ 1 := by sorry
case intro.intro n : β„• this✝ : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ple : p ≀ n this : p ∣ Nat.factorial (n + 1) ⊒ False
case intro.intro n : β„• this✝¹ : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ple : p ≀ n this✝ : p ∣ Nat.factorial (n + 1) this : p ∣ 1 ⊒ False
Please generate a tactic in lean4 to solve the state. STATE: case intro.intro n : β„• this✝ : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ple : p ≀ n this : p ∣ Nat.factorial (n + 1) ⊒ False TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.primes_infinite
[46, 1]
[60, 8]
sorry
case intro.intro n : β„• this✝¹ : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ple : p ≀ n this✝ : p ∣ Nat.factorial (n + 1) this : p ∣ 1 ⊒ False
no goals
Please generate a tactic in lean4 to solve the state. STATE: case intro.intro n : β„• this✝¹ : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ple : p ≀ n this✝ : p ∣ Nat.factorial (n + 1) this : p ∣ 1 ⊒ False TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.primes_infinite
[46, 1]
[60, 8]
sorry
n : β„• ⊒ 2 ≀ Nat.factorial (n + 1) + 1
no goals
Please generate a tactic in lean4 to solve the state. STATE: n : β„• ⊒ 2 ≀ Nat.factorial (n + 1) + 1 TACTIC:
https://github.com/fpvandoorn/LeanCourse23.git
7b0a3cf61b802764dc7baee9d9825e9c62cf9c5d
LeanCourse/MIL/C05_Elementary_Number_Theory/S03_Infinitely_Many_Primes.lean
C05S03.primes_infinite
[46, 1]
[60, 8]
sorry
n : β„• this : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ple : p ≀ n ⊒ p ∣ Nat.factorial (n + 1)
no goals
Please generate a tactic in lean4 to solve the state. STATE: n : β„• this : 2 ≀ Nat.factorial (n + 1) + 1 p : β„• pp : Nat.Prime p pdvd : p ∣ Nat.factorial (n + 1) + 1 ple : p ≀ n ⊒ p ∣ Nat.factorial (n + 1) TACTIC: