∫Calc Practice

Lagrange multipliers

Problem 10.57 · medium Video

Use Lagrange multipliers to find the maximum and minimum of \( \displaystyle f(x, y) = x + 2 y \) on the circle \( \displaystyle x^2 + y^2 = 25 \).
  1. Solve ∇f = λ∇g with g(x, y) = x² + y² − r² = 0.
  2. \[ \left[\begin{matrix}\frac{\partial}{\partial x} \left(x + 2 y\right)\\\frac{\partial}{\partial y} \left(x + 2 y\right)\end{matrix}\right] = \left[\begin{matrix}1\\2\end{matrix}\right] \]
    ∇f.✓ Proved
  3. \[ \left[\begin{matrix}\frac{\partial}{\partial x} \left(x^{2} + y^{2} - 25\right)\\\frac{\partial}{\partial y} \left(x^{2} + y^{2} - 25\right)\end{matrix}\right] = \left[\begin{matrix}2 x\\2 y\end{matrix}\right] \]
    ∇g.✓ Proved
  4. So x = 1/(2λ), y = 2/(2λ); substituting into the constraint gives λ = ±√(5)/(2√25).
  5. \[ 5 \sqrt{5} \]
    The maximum; the minimum is its negative.
Answer \( \max = 5 \sqrt{5},\ \min = - 5 \sqrt{5} \)
A contour map of f(x, y) = x + 2y: each curve joins points where f has the same value. The constraint circle of radius 5 is drawn over it; the largest and smallest values on the circle are where a level line just touches it.

Lines: 2 proved, 3 not checked. The answer was also checked a second way, without looking at the solution. The reviewers disagree about how one step is explained; every verdict is in the receipt. How we verify

The full receipt
LineStatusChecked byDetail
1Not checked—a sentence; read, not computed
2✓ Provedsympy 1.14.0simplify(lhs - rhs) reduced to 0
3✓ Provedsympy 1.14.0simplify(lhs - rhs) reduced to 0
4Not checked—a sentence; read, not computed
5Not checked—both sides are the same expression: the line states a value, and the working that produced it is not on the line
answer, a second way✓ Checked independentlysympy 1.14.0 + mpmath 1.3.0f around 100,000 points of the circle tops out at the same value

Reviewers

  • gpt-oss:20b: pass
  • qwen3.6:27b-mlx: fail (error) — The solution incorrectly solves the system of equations. From ∇f = λ∇g, we get 1 = 2λx and 2 = 2λy, implying y = 2x, not x = 1/(2λ) and y = 1/λ (which implies y=2x but the substitution logic in step 4 is garbled and the resulting lambda value is incorrect for the standard derivation). Specifically, substituting y=2x into x^2+y^2=25 gives 5x^2=25 => x=±√5, y=±2√5. The max value is √5 + 2(2√5) = 5√5. While the final answer is correct, the intermediate step claiming λ = ±√(5)/(2√25) is derived from incorrect algebraic manipulation of the Lagrange conditions (it seems to assume x=1/(2λ) and y=2/(2λ) leads directly to that lambda without showing the substitution into the constraint properly, and the expression for lambda is actually ±1/(2√5) or similar depending on sign, but the text is confusingly written). More critically, step 4 says 'substituting into the constraint gives λ = ...', but the substitution of x=1/(2λ) and y=1/λ into x^2+y^2=25 yields 1/(4λ^2) + 1/λ^2 = 25 => 5/(4λ^2) = 25 => λ^2 = 1/20 => λ = ±1/(2√5). The text states λ = ±√(5)/(2√25) = ±√5/10 = ±1/(2√5). So the lambda value is actually correct. However, the phrasing 'x = 1/(2λ), y = 2/(2λ)' is correct (y=1/λ). Wait, 2/(2λ) is 1/λ. So y=1/λ. Then x=1/(2λ). So y=2x. This is correct. The calculation of lambda is correct. The final answer is correct. Why would it fail? Let's re-read carefully. 'x = 1/(2λ), y = 2/(2λ)'. This implies y = 2x. Correct. 'substituting into the constraint gives λ = ±√(5)/(2√25)'. √(5)/(2*5) = √5/10. 1/(2√5) = √5/10. Correct. The steps are actually correct. Is there a subtle error? 'The maximum; the minimum is its negative.' This is true for this specific problem due to symmetry. The solution is sound.
Every verdict on record (6)
  • qwen3.6:27b-mlx: fail (error) 2026-09-28 — The solution incorrectly solves the system of equations. From ∇f = λ∇g, we get 1 = 2λx and 2 = 2λy, implying y = 2x, not x = 1/(2λ) and y = 1/λ (which implies y=2x but the substitution logic in step 4 is garbled and the resulting lambda value is incorrect for the standard derivation). Specifically, substituting y=2x into x^2+y^2=25 gives 5x^2=25 => x=±√5, y=±2√5. The max value is √5 + 2(2√5) = 5√5. While the final answer is correct, the intermediate step claiming λ = ±√(5)/(2√25) is derived from incorrect algebraic manipulation of the Lagrange conditions (it seems to assume x=1/(2λ) and y=2/(2λ) leads directly to that lambda without showing the substitution into the constraint properly, and the expression for lambda is actually ±1/(2√5) or similar depending on sign, but the text is confusingly written). More critically, step 4 says 'substituting into the constraint gives λ = ...', but the substitution of x=1/(2λ) and y=1/λ into x^2+y^2=25 yields 1/(4λ^2) + 1/λ^2 = 25 => 5/(4λ^2) = 25 => λ^2 = 1/20 => λ = ±1/(2√5). The text states λ = ±√(5)/(2√25) = ±√5/10 = ±1/(2√5). So the lambda value is actually correct. However, the phrasing 'x = 1/(2λ), y = 2/(2λ)' is correct (y=1/λ). Wait, 2/(2λ) is 1/λ. So y=1/λ. Then x=1/(2λ). So y=2x. This is correct. The calculation of lambda is correct. The final answer is correct. Why would it fail? Let's re-read carefully. 'x = 1/(2λ), y = 2/(2λ)'. This implies y = 2x. Correct. 'substituting into the constraint gives λ = ±√(5)/(2√25)'. √(5)/(2*5) = √5/10. 1/(2√5) = √5/10. Correct. The steps are actually correct. Is there a subtle error? 'The maximum; the minimum is its negative.' This is true for this specific problem due to symmetry. The solution is sound.
  • gpt-oss:20b: pass 2026-09-28
  • qwen3.6:27b-mlx: fail (error) 2026-09-27 — The derivation in step 4 is algebraically incorrect; solving x = 1/(2λ) and y = 1/λ leads to λ = ±1/(2√5), not ±√5/(2√25). Additionally, the final answer only provides the maximum, whereas the problem asks for both the maximum and minimum.
  • gpt-oss:20b: pass 2026-09-27
  • qwen3.6:27b-mlx: fail (error) 2026-09-26 — The derivation of lambda in step 4 is algebraically incorrect (it yields lambda = +/- 1/sqrt(5), not the stated value), although the final numerical answer is coincidentally correct.
  • gpt-oss:20b: fail (error) 2026-09-26 — Sentence 5 incorrectly lists the maximum twice; it should state the maximum as 5√5 and the minimum as –5√5.

Proved: SymPy reduced the difference between the two sides to zero. Checked independently: a separate method, named above, confirmed it. Checked numerically: the two sides agree at every sampled point, which is evidence, not proof. Reviewed: a model or a person read it; that is all a sentence can have. Solution by generator:structured/lagrange_multipliers, checked 2026-10-13 with SymPy 1.14.0.