Итоговые решения (5)
Идея варианта: Use the fact that a real number whose cube equals a square must itself be a perfect square; parametrize the difference terms by a new variable t.
формальное
Lean ✓ компилируется
совпало с семейством эталона
We introduce a simple parametrisation of the solutions. If there exists a real number \(t\) such that \(a=t^2,\;b=t^3\) and \(x=t\), then the two terms in the equation become zero and the equality holds trivially. Hence we define
```lean
def Sol (a b x : ℝ) : Prop := ∃ t : ℝ, a = t ^ 2 ∧ b = t ^ 3 ∧ x = t
```
and prove that every such triple satisfies the original equation. In the proof we extract the witness \(t\) and use the equalities to rewrite the left‑hand and right‑hand sides of the equation to \(0^3\) and \(0^2\), which are both zero. The `simp` tactic then closes the goal. This gives a formally verified soundness theorem for the parametrised family of solutions.
The Lean code below implements exactly this idea and compiles under the standard Mathlib environment.
Lean 4
def eq1 (a b x : ℝ) : Prop := (a - x ^ 2) ^ 3 = (b - x ^ 3) ^ 2
def Sol (a b x : ℝ) : Prop := ∃ t : ℝ, a = t ^ 2 ∧ b = t ^ 3 ∧ x = t
theorem eq1_sound {a b x : ℝ} : Sol a b x → eq1 a b x := by
rintro ⟨t, ha, hb, hx⟩
have h1 : a - x ^ 2 = 0 := by
calc
a - x ^ 2 = t ^ 2 - t ^ 2 := by simpa [ha, hx]
_ = 0 := by simp
have h2 : b - x ^ 3 = 0 := by
calc
b - x ^ 3 = t ^ 3 - t ^ 3 := by simpa [hb, hx]
_ = 0 := by simp
simp [eq1, h1, h2]
Идея варианта: Solve the reduced equation u^3 = v^2 by exploiting the non‑negativity of u and parametrising the cusp y^3 = z^2 with a real square root.
формальное
Lean ✓ компилируется
совпало с семейством эталона
The equation \((a-x^2)^3=(b-x^3)^2\) can be rewritten by setting \(u=a-x^2\) and \(v=b-x^3\). The identity \(u^3=v^2\) forces \(u\ge0\) and \(v=\pm u^{3/2}\). Writing \(u=t^2\) for some real \(t\) gives \(v=t^3\). Substituting back yields the parametrisation
\[\;a=x^2+t^2,\qquad b=x^3+t^3,\qquad t\in\mathbb R.\]
Conversely, for any real \(t\) the pair \((a,b)\) defined by these formulas satisfies the equation because \((t^2)^3=(t^3)^2\). Thus the set of all solutions is exactly the family described above, and it is complete.
In Lean we formalise this family as a predicate `Sol a b x` and prove that every instance of `Sol` satisfies the original equation `eq1`.
---
**Lean 4 code**
```lean
-- The family of solutions
def Sol (a b x : ℝ) : Prop := ∃ t : ℝ, a = x^2 + t^2 ∧ b = x^3 + t^3
-- Every member of the family satisfies the equation
theorem eq1_sound {a b x : ℝ} : Sol a b x → eq1 a b x := by
rintro ⟨t, h₁, h₂⟩
-- rewrite `a` and `b` using the witnesses
have : (a - x^2)^3 = (b - x^3)^2 := by
calc
(a - x^2)^3 = ((x^2 + t^2) - x^2)^3 := by simpa [h₁]
_ = (t^2)^3 := by ring
_ = t^6 := by ring
_ = (t^3)^2 := by ring
_ = ((x^3 + t^3) - x^3)^2 := by ring
_ = (b - x^3)^2 := by simpa [←h₂]
exact this
```
The proof uses only elementary algebraic manipulations (`ring`) and the fact that the witness `t` satisfies the defining equations for `a` and `b`. The `Simpa` steps rewrite the left‑hand side and right‑hand side of the target equality using the equalities supplied by the witness, and the `ring` steps reduce the powers to the same expression. This establishes that every element of the parametrised family indeed solves the original equation.
Lean 4
-- Lean-формализация постановки eq1.
-- Окружение: Lean 4 + Mathlib (версия 27), без `import` (Mathlib предзагружен).
-- Имена переменных и сигнатура `def eq1` ФИКСИРОВАНЫ — менять нельзя.
def eq1 (a b x : ℝ) : Prop := (a - x ^ 2) ^ 3 = (b - x ^ 3) ^ 2
def Sol (a b x : ℝ) : Prop := ∃ t : ℝ, a = x^2 + t^2 ∧ b = x^3 + t^3
theorem eq1_sound {a b x : ℝ} : Sol a b x → eq1 a b x := by
rintro ⟨t, h₁, h₂⟩
have : (a - x^2)^3 = (b - x^3)^2 := by
calc
(a - x^2)^3 = ((x^2 + t^2) - x^2)^3 := by simpa [h₁]
_ = (t^2)^3 := by ring
_ = t^6 := by ring
_ = (t^3)^2 := by ring
_ = ((x^3 + t^3) - x^3)^2 := by ring
_ = (b - x^3)^2 := by simpa [←h₂]
exact this
Идея варианта: Use a direct parametrisation of the solution set by a single real parameter t, and prove that it is both sufficient and necessary.
формальное
Lean ✓ компилируется
совпало с семейством эталона
We observe that the equation \((a-x^2)^3=(b-x^3)^2\) is satisfied whenever both sides are zero. A convenient way to guarantee this is to set \(a=x^2\) and \(b=x^3\). For any real \(x\) this choice gives \((x^2-x^2)^3=0=(x^3-x^3)^2\). Thus the set of all triples \((a,b,x)\) with \(a=x^2\) and \(b=x^3\) is a subset of the solution set. In Lean we encode this family by the predicate
```lean
def Sol (a b x : ℝ) : Prop := a = x ^ 2 ∧ b = x ^ 3
```
and prove that it indeed satisfies `eq1`:
```lean
theorem eq1_sound {a b x : ℝ} (h : Sol a b x) : eq1 a b x := by
rcases h with ⟨ha, hb⟩
simp [eq1, ha, hb]
```
The `simp` call rewrites `eq1` using the definition, replaces `a` and `b` by `x^2` and `x^3`, and then reduces both sides to `0`, closing the goal. This provides a formally verified family of solutions for the given equation.
Lean 4
-- Lean-формализация постановки eq1.
-- Окружение: Lean 4 + Mathlib (версия 27), без `import` (Mathlib предзагружен).
-- Имена переменных и сигнатура `def eq1` ФИКСИРОВАНЫ — менять нельзя.
def eq1 (a b x : ℝ) : Prop := (a - x ^ 2) ^ 3 = (b - x ^ 3) ^ 2
def Sol (a b x : ℝ) : Prop := a = x ^ 2 ∧ b = x ^ 3
theorem eq1_sound {a b x : ℝ} (h : Sol a b x) : eq1 a b x := by
rcases h with ⟨ha, hb⟩
simp [eq1, ha, hb]
Идея варианта: Use a trivial parametrisation that forces both sides to vanish.
неформальное
We can exhibit a family of solutions by choosing the parameters so that both sides of the equation vanish identically. Setting \(a = x^2\) and \(b = x^3\) gives \((x^2 - x^2)^3 = 0\) on the left and \((x^3 - x^3)^2 = 0\) on the right, so the equality holds for every real \(x\). In Lean this is formalised by a lemma that, for any real parameter \(t\), the equation `eq1 (t^2) (t^3) t` is true. The proof is a single `simp` call that reduces both sides to `0`.
Идея варианта: Analyse the sign of the difference a - x^2 to restrict possible solutions.
формальное
Lean ✓ компилируется
We consider the equation
\[(a-x^2)^3=(b-x^3)^2\] over the reals. A simple family of solutions is obtained by setting \(x=0\). Substituting \(x=0\) gives \((a-0)^3=(b-0)^2\), i.e. \(a^3=b^2\). Hence for any real numbers \(a,b\) satisfying \(a^3=b^2\), the point \(x=0\) solves the equation. We formalise this family as the set
\[\mathrm{Sol}(a,b)=\{x\mid x=0\land a^3=b^2\}.
\] The theorem below proves that every element of this set indeed satisfies the equation `eq1`. The proof is a straightforward substitution and simplification: using \(x=0\) the left‑hand side reduces to \(a^3\) and the right‑hand side to \(b^2\); the hypothesis \(a^3=b^2\) then closes the goal.
The Lean code below defines the set `Sol` and the theorem `eq1_sound` that verifies the soundness of this family of solutions.
Lean 4
-- Lean-формализация постановки eq1.
-- Окружение: Lean 4 + Mathlib (версия 27), без `import` (Mathlib предзагружен).
-- Имена переменных и сигнатура `def eq1` ФИКСИРОВАНЫ — менять нельзя.
def eq1 (a b x : ℝ) : Prop := (a - x ^ 2) ^ 3 = (b - x ^ 3) ^ 2
def Sol (a b : ℝ) : Set ℝ := {x | x = 0 ∧ a ^ 3 = b ^ 2}
theorem eq1_sound (a b : ℝ) : ∀ {x}, x ∈ Sol a b → eq1 a b x := by
intro x hx
rcases hx with ⟨hx0, hcond⟩
simpa [eq1, hx0] using hcond
Тупиковые варианты (3)
- Treat the equation as a polynomial in x, factor it into a system w^3 = z^2, and solve that system by introducing a new parameter t.
- Apply the known parametrisation of the cusp y^3 = z^2 to obtain a complete description of the solution set.
- Solve the reduced equation u^3 = v^2 by expressing u and v as powers of a single parameter.