You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
lean4game/server/nng/NNG/Levels/Multiplication/Level_1.lean

36 lines
736 B
Plaintext

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

import NNG.MyNat.Multiplication
import NNG.Levels.Addition
Game "NNG"
World "Multiplication"
Level 1
Title "zero_mul"
open MyNat
Introduction
"
As a side note, the lemmas about addition are still available in your inventory
in the lemma tab \"Add\" while the new lemmas about multiplication appear in the
tab \"Mul\".
We are given `mul_zero`, and the first thing to prove is `zero_mul`.
Like `zero_add`, we of course prove it by induction.
"
Statement MyNat.zero_mul
"For all natural numbers $m$, we have $ 0 \\cdot m = 0$."
(m : ) : 0 * m = 0 := by
induction m
rw [mul_zero]
rfl
rw [mul_succ]
rw [n_ih]
rw [add_zero]
rfl
NewTactic simp
NewLemma MyNat.mul_zero MyNat.mul_succ
NewDefinition Mul
LemmaTab "Mul"