typos
This commit is contained in:
@@ -19,7 +19,7 @@ Also z.B. `(h : A)` und `(g : ¬ A)`.
|
|||||||
Da `≠` als `¬(· = ·)` gelesen wird, gilt dasselbe für Annahmen `(h : a = b)` und `(g : a ≠ b)`.
|
Da `≠` als `¬(· = ·)` gelesen wird, gilt dasselbe für Annahmen `(h : a = b)` und `(g : a ≠ b)`.
|
||||||
"
|
"
|
||||||
|
|
||||||
Statement absurd
|
Statement
|
||||||
"Sei $n$ eine natürliche Zahl die sowohl gleich als auch ungleich `10` ist.
|
"Sei $n$ eine natürliche Zahl die sowohl gleich als auch ungleich `10` ist.
|
||||||
Zeige, dass daraus $n = 42$ folgt. (oder, tatsächlich $n = x$ für jedes beliebige $x$)"
|
Zeige, dass daraus $n = 42$ folgt. (oder, tatsächlich $n = x$ für jedes beliebige $x$)"
|
||||||
(n : ℕ) (h : n = 10) (g : (n ≠ 10)) : n = 42 := by
|
(n : ℕ) (h : n = 10) (g : (n ≠ 10)) : n = 42 := by
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ welche Seite man beweisen möchte.
|
|||||||
"
|
"
|
||||||
|
|
||||||
Statement
|
Statement
|
||||||
"Angenommen $A$ ist wahr, zeige $A \\lor (\\neg B))$"
|
"Angenommen $A$ ist wahr, zeige $A \\lor (\\neg B))$."
|
||||||
(A B : Prop) (hA : A) : A ∨ (¬ B) := by
|
(A B : Prop) (hA : A) : A ∨ (¬ B) := by
|
||||||
left
|
left
|
||||||
assumption
|
assumption
|
||||||
|
|||||||
@@ -11,93 +11,33 @@ Game "TestGame"
|
|||||||
World "Proposition"
|
World "Proposition"
|
||||||
Level 12
|
Level 12
|
||||||
|
|
||||||
Title "Oder - Bonus"
|
Title "Oder"
|
||||||
|
|
||||||
Introduction
|
Introduction
|
||||||
"
|
"
|
||||||
Wenn man hingegen ein ODER `(h : A ∨ B)` in den Annahmen hat, kann man dieses
|
Wenn man hingegen ein ODER `(h : A ∨ B)` in den Annahmen hat, kann man dieses
|
||||||
ähnlich wie beim UND mit `rcases h` aufteilen.
|
ähnlich wie beim UND mit `rcases h` aufteilen.
|
||||||
|
|
||||||
**Wichtig:** der Syntax dafür ist `rcases h with h₁ | h₂`.
|
**Wichtig:** der Syntax dafür ist `rcases h with h | h`. Das \"`h | h`\" bedeutet, dass
|
||||||
|
wir in beiden Fälle (linke oder rechte Seite wahr) diese Seite wieder `h` nennen wollen.
|
||||||
|
|
||||||
Der Unterschied ist, dass man beim UND eine Annahme in zwei Einzelteile zerlegt (mit `⟨h₁, h₂⟩`).
|
Der Unterschied ist, dass man beim UND eine Annahme in zwei Einzelteile zerlegt (mit `⟨h₁, h₂⟩`).
|
||||||
Beim ODER hingegen, kriegt man stattdessen zwei *Goals*, nämlich eines wo man annimmt,
|
Beim ODER hingegen, kriegt man stattdessen zwei *Goals*, nämlich eines wo man annimmt,
|
||||||
die linke Seite sei wahr und eines wo man annimmt, rechts sei wahr.
|
die linke Seite sei wahr und eines wo man annimmt, rechts sei wahr.
|
||||||
"
|
"
|
||||||
|
|
||||||
Statement distributivity
|
Statement
|
||||||
"Angenommen $ A \\lor (B \\land C)$ is wahr, zeige, dass $(A \\lor B) \\land (A \\lor C)$."
|
"Angenommen \"$A$ oder ($A$ und $B$)\" wahr ist, zeige, dass $A$ wahr ist."
|
||||||
(A B C : Prop) (h : A ∨ (B ∧ C)) : (A ∨ B) ∧ (A ∨ C) := by
|
(A B : Prop) (h : A ∨ (A ∧ B)) : A := by
|
||||||
rcases h with ha | h
|
rcases h with h | h
|
||||||
constructor
|
|
||||||
left
|
|
||||||
assumption
|
|
||||||
left
|
|
||||||
assumption
|
assumption
|
||||||
rcases h with ⟨h₁, h₂⟩
|
rcases h with ⟨h₁, h₂⟩
|
||||||
constructor
|
|
||||||
right
|
|
||||||
assumption
|
|
||||||
right
|
|
||||||
assumption
|
assumption
|
||||||
|
|
||||||
Message (A : Prop) (B : Prop) (C : Prop) (h : A ∨ (B ∧ C)) : (A ∨ B) ∧ (A ∨ C) =>
|
Message (A : Prop) (B : Prop) (h : A ∨ (A ∧ B)) : A =>
|
||||||
"Als erstes solltest du das OR in der Annahme `(h: A ∨ (B ∧ C))` aufteilen:"
|
"Als erstes kannst du das ODER in den Annahmen mit `rcases h with h | h` zerlegen."
|
||||||
|
|
||||||
Hint (A : Prop) (B : Prop) (C : Prop) (h : A) : (A ∨ B) ∧ (A ∨ C) =>
|
Message (A : Prop) (B : Prop) (h : A ∧ B) : A =>
|
||||||
"Wie wär's mit zerlegen?"
|
"Jetzt noch das UND in den Annahmen mit `rcases h with ⟨h₁, h₂⟩` zerlegen."
|
||||||
|
|
||||||
Hint (A : Prop) (B : Prop) : (A ∨ B) =>
|
Tactics assumption rcases
|
||||||
"`left` oder `right`?"
|
|
||||||
|
|
||||||
Message (A : Prop) (B : Prop) (C : Prop) (h : (B ∧ C)) : (A ∨ B) ∧ (A ∨ C) =>
|
|
||||||
"Und jetzt der Fall, falls die rechte Seite $B \\land C$ wahr ist. Zerlege diese
|
|
||||||
Annahme doch als erstes."
|
|
||||||
|
|
||||||
Message (A : Prop) (B : Prop) (C : Prop) (h : A ∨ (B ∧ C)) : (A ∨ B) =>
|
|
||||||
"Jetzt musst du die Annahme $A \\lor (B \\land C)$ trotzdem noch mit `rcases` zerlegen."
|
|
||||||
|
|
||||||
Message (A : Prop) (B : Prop) (C : Prop) (h : A ∨ (B ∧ C)) : (A ∨ C) =>
|
|
||||||
"So musst du die Annahme $A \\lor (B \\land C)$ nochmals mit `rcases` zerlegen...
|
|
||||||
|
|
||||||
Wenn du am Anfang zuerst `rcases` und dann `constructor` aufrufst,
|
|
||||||
musst du das hier nur einmal machen..."
|
|
||||||
|
|
||||||
Message (A : Prop) (B : Prop) (C : Prop) (h : B ∧ C) : A ∨ B =>
|
|
||||||
"Die Annahme `B ∧ C` kannst du auch mit `rcases` zerlegen."
|
|
||||||
|
|
||||||
Message (A : Prop) (B : Prop) (C : Prop) (h : B ∧ C) : A ∨ C =>
|
|
||||||
"Die Annahme `B ∧ C` kannst du auch mit `rcases` zerlegen."
|
|
||||||
|
|
||||||
Message (A : Prop) (B : Prop) (C : Prop) (h : B ∧ C) : C =>
|
|
||||||
"Die Annahme `B ∧ C` kannst du auch mit `rcases` zerlegen."
|
|
||||||
|
|
||||||
|
|
||||||
-- Statement umsortieren
|
|
||||||
-- "Angenommen $(A \\land B) \\lor (D \\lor C)$ is wahr, zeige, dass "
|
|
||||||
-- (A B C D : Prop) (h : (A ∧ B) ∨ (D ∨ C)) : (A ∧ B) ∨ (C ∨ D) := by
|
|
||||||
-- rcases h with x | (h | h)
|
|
||||||
-- left
|
|
||||||
-- assumption
|
|
||||||
-- right
|
|
||||||
-- right
|
|
||||||
-- assumption
|
|
||||||
-- right
|
|
||||||
-- left
|
|
||||||
-- assumption
|
|
||||||
|
|
||||||
-- Message (A : Prop) (B : Prop) (C : Prop) (D : Prop) (h : (A ∧ B) ∨ (D ∨ C)) : (A ∧ B) ∨ (C ∨ D) =>
|
|
||||||
-- "Man kann hier entweder in mehren Schritten `rcases` anwenden:
|
|
||||||
-- ```
|
|
||||||
-- rcases h with h₁ | h₂
|
|
||||||
-- rcases h₁ with ⟨hA, hB⟩
|
|
||||||
-- [...]
|
|
||||||
-- rcases h₂ with h | h
|
|
||||||
-- ```
|
|
||||||
-- oder man kann dies in einem Schritt verschachteln:
|
|
||||||
-- ```
|
|
||||||
-- rcases h with ⟨ha, hb⟩ | (h | h)
|
|
||||||
-- ```
|
|
||||||
-- "
|
|
||||||
|
|
||||||
Tactics left right assumption constructor rcases apply
|
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ umzugehen um folgende Aussage zu beweisen.
|
|||||||
|
|
||||||
-- Note: The other direction would need arguing by cases.
|
-- Note: The other direction would need arguing by cases.
|
||||||
|
|
||||||
Statement or_and_left
|
Statement
|
||||||
"Angenommen $A \\lor (B \\land C)$ ist wahr, zeige dass
|
"Angenommen $A \\lor (B \\land C)$ ist wahr, zeige dass
|
||||||
$(A \\lor B) \\land (A \\lor C)$ wahr ist."
|
$(A \\lor B) \\land (A \\lor C)$ wahr ist."
|
||||||
(A B C : Prop) (h : A ∨ (B ∧ C)) : (A ∨ B) ∧ (A ∨ C) := by
|
(A B C : Prop) (h : A ∨ (B ∧ C)) : (A ∨ B) ∧ (A ∨ C) := by
|
||||||
|
|||||||
Reference in New Issue
Block a user