import MyNat.Definition
import MultiplicationWorld.Level1 -- zero_mul
import AdvancedMultiplicationWorld.Level2 -- eq_zero_or_eq_zero_of_mul_eq_zero
import Mathlib.Tactic.LeftRight
namespace MyNat
open MyNat
Advanced Multiplication World
Level 3: mul_eq_zero_iff
Now you have eq_zero_or_eq_zero_of_mul_eq_zero
this is pretty straightforward.
Theorem
ab = 0
, if and only if at least one of a
or b
is equal to zero.
theoremmul_eq_zero_iff (mul_eq_zero_iff: ∀ (a b : MyNat), a * b = 0 ↔ a = 0 ∨ b = 0aa: MyNatb :b: MyNatMyNat):MyNat: Typea *a: MyNatb =b: MyNat0 ↔0: MyNata =a: MyNat0 ∨0: MyNatb =b: MyNat0 :=0: MyNata, b: MyNata * b = 0 ↔ a = 0 ∨ b = 0a, b: MyNat
mpa * b = 0 → a = 0 ∨ b = 0a, b: MyNata = 0 ∨ b = 0 → a * b = 0a, b: MyNat
mpa * b = 0 → a = 0 ∨ b = 0a, b: MyNat
h: a * b = 0
mpa = 0 ∨ b = 0Goals accomplished! 🐙a, b: MyNat
mpra = 0 ∨ b = 0 → a * b = 0a, b: MyNat
mpra = 0 ∨ b = 0 → a * b = 0a, b: MyNat
hab: a = 0 ∨ b = 0
mpra * b = 0a, b: MyNat
hab: a = 0 ∨ b = 0
mpra * b = 0a, b: MyNat
ha: a = 0
mpr.inla * b = 0a, b: MyNat
ha: a = 0
mpr.inla * b = 0a, b: MyNat
ha: a = 0
mpr.inl0 * b = 0a, b: MyNat
ha: a = 0
mpr.inl0 * b = 0a, b: MyNat
ha: a = 0
mpr.inl0 * b = 0a, b: MyNat
ha: a = 0
mpr.inl0 = 0Goals accomplished! 🐙a, b: MyNat
hb: b = 0
mpr.inra * b = 0a, b: MyNat
hb: b = 0
mpr.inra * b = 0a, b: MyNat
hb: b = 0
mpr.inra * 0 = 0a, b: MyNat
hb: b = 0
mpr.inra * 0 = 0a, b: MyNat
hb: b = 0
mpr.inra * 0 = 0a, b: MyNat
hb: b = 0
mpr.inr0 = 0Goals accomplished! 🐙Goals accomplished! 🐙
Next up Level 4