-- -- https://leanprover.zulipchat.com/#narrow/stream/270676-lean4/topic/Mechanics.20of.20Proof.201.2E3.2E11.20exercise.2015 import Mathlib -- -- https://hrmacbeth.github.io/math2001/01_Proofs_by_Calculation.html#id29 example {x y : ℝ} (h1 : x + 3 = 5) (h2 : 2 * x - y * x = 0) : y = 2 := calc y = 0 / x + y :=Goals accomplished! 🐙Goals accomplished! 🐙_ = (_: ℝ2 *2: ℝx -x: ℝy *y: ℝx) /x: ℝx +x: ℝy :=y: ℝGoals accomplished! 🐙x, y: ℝ
h1: x + 3 = 5
h2: 2 * x - y * x = 00 / x + y = (2 * x - y * x) / x + yx, y: ℝ
h1: x + 3 = 5
h2: 2 * x - y * x = 00 / x + y = 0 / x + yGoals accomplished! 🐙_ = ((_: ℝ2 -2: ℝy) * (y: ℝx +x: ℝ3 -3: ℝ3)) /3: ℝx +x: ℝy :=y: ℝGoals accomplished! 🐙Goals accomplished! 🐙_ = ((_: ℝ2 -2: ℝy) * (y: ℝ5 -5: ℝ3)) /3: ℝx +x: ℝy :=y: ℝGoals accomplished! 🐙x, y: ℝ
h1: x + 3 = 5
h2: 2 * x - y * x = 0(2 - y) * (x + 3 - 3) / x + y = (2 - y) * (5 - 3) / x + yx, y: ℝ
h1: x + 3 = 5
h2: 2 * x - y * x = 0(2 - y) * (5 - 3) / x + y = (2 - y) * (5 - 3) / x + yGoals accomplished! 🐙_ = (_: ℝ2 -2: ℝy) *y: ℝ2 /2: ℝx +x: ℝy :=y: ℝGoals accomplished! 🐙Goals accomplished! 🐙_ = (_: ℝ2 -2: ℝy) *y: ℝ2 / (2: ℝx +x: ℝ3 -3: ℝ3) +3: ℝy :=y: ℝGoals accomplished! 🐙Goals accomplished! 🐙_ = (_: ℝ2 -2: ℝy) *y: ℝ2 / (2: ℝ5 -5: ℝ3) +3: ℝy :=y: ℝGoals accomplished! 🐙x, y: ℝ
h1: x + 3 = 5
h2: 2 * x - y * x = 0(2 - y) * 2 / (x + 3 - 3) + y = (2 - y) * 2 / (5 - 3) + yx, y: ℝ
h1: x + 3 = 5
h2: 2 * x - y * x = 0(2 - y) * 2 / (5 - 3) + y = (2 - y) * 2 / (5 - 3) + yGoals accomplished! 🐙_ = (_: ℝ2 -2: ℝy) +y: ℝy :=y: ℝGoals accomplished! 🐙Goals accomplished! 🐙_ =_: ℝ2 :=2: ℝGoals accomplished! 🐙Goals accomplished! 🐙example :example: 6 = 3 + 36 =6: ℕ3 +3: ℕ3 :=3: ℕGoals accomplished! 🐙6 = 3 + 3Goals accomplished! 🐙6 = 2 + 4Goals accomplished! 🐙6 = 1 + 56 = Nat.succ 5Goals accomplished! 🐙_: ℕ6 = 2 + 4Goals accomplished! 🐙1 + 5 = 2 + 41 = 1Goals accomplished! 🐙_: ℕ6 = 2 + 4Goals accomplished! 🐙2 + 4 = 3 + 32 = 2Goals accomplished! 🐙Goals accomplished! 🐙Goals accomplished! 🐙