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/testgame/TestGame/Levels/Predicate/L04_Ring.lean

34 lines
863 B
Plaintext

import TestGame.Metadata
import Mathlib.Tactic.Ring
Game "TestGame"
World "Predicate"
Level 4
Title "Natürliche Zahlen"
Introduction
"
Oft braucht man eine Kombination von `rw` und `ring` um Gleichungen zu lösen.
Zuerst setzt man mit `rw` die vorhandenen Annahmen ein, und sobald die beiden Seiten
einer Gleichung im Goal rechnerisch gleich sind, kan `ring` dies beweisen.
"
2 years ago
Statement
"Angenommen, man hat die Gleichung $x = 2 * y + 1$, zeige
$x ^ 2 = 4 * y ^ 2 + 3 * y + 1 + y$. "
(x y : ) (h : x = 2 * y + 1) : x ^ 2 = 4 * y ^ 2 + 3 * y + 1 + y := by
rw [h]
ring
Hint (x : ) (y : ) (h : x = 2 * y + 1) : x ^ 2 = 4 * y ^ 2 + 3 * y + 1 + y =>
2 years ago
"Die Annahme `h` kannst du mit `rw [h]` benützen."
Hint (y : ) : (2 * y + 1) ^ 2 = 4 * y ^ 2 + 3 * y + 1 + y =>
2 years ago
"Jetzt kann `ring` übernehmen."
Conclusion ""
2 years ago
Tactics ring rw