∫Calc Practice

Undetermined coefficients

Problem 6.289 · hard

Solve \( \displaystyle y'' - 2y' - 3y = 3 x + 2 \) with \( \displaystyle y(0) = -1 \), \( \displaystyle y'(0) = 3 \).
  1. \[ r^{2} - 2 r - 3 = \left(r - 3\right) \left(r + 1\right) \]
    The characteristic equation has roots -1 and 3.✓ Proved
  2. So y_h = C₁e^(-1x) + C₂e^(3x). Guess y_p = A*x + B.
  3. \[ 3 x - 2 \frac{d}{d x} \left(- x\right) + \frac{d^{2}}{d x^{2}} \left(- x\right) = 3 x + 2 \]
    Matching coefficients gives y_p = -x; it satisfies the equation.✓ Proved
  4. \[ \left[\begin{matrix}\left. - x + \frac{3 e^{3 x}}{4} - \frac{7 e^{- x}}{4} \right|_{\substack{ x=0 }}\\\left. \frac{d}{d x} \left(- x + \frac{3 e^{3 x}}{4} - \frac{7 e^{- x}}{4}\right) \right|_{\substack{ x=0 }}\end{matrix}\right] = \left[\begin{matrix}-1\\3\end{matrix}\right] \]
    The initial conditions fix C₁ = -7/4 and C₂ = 3/4.✓ Proved
Answer \( y = - x + \frac{3 e^{3 x}}{4} - \frac{7 e^{- x}}{4} \)

Lines: 3 proved, 1 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.

The full receipt
LineStatusChecked byDetail
1✓ Provedsympy 1.14.0simplify(lhs - rhs) reduced to 0
2Not checked—a sentence; read, not computed
3✓ Provedsympy 1.14.0simplify(lhs - rhs) reduced to 0
4✓ Provedsympy 1.14.0simplify(lhs - rhs) reduced to 0
answer, a second way✓ Checked independentlysympy 1.14.0 + mpmath 1.3.0SymPy's dsolve with the same initial conditions agrees

Reviewers

  • gpt-oss:20b: pass
  • qwen3.6:27b-mlx: fail (error) — The particular solution is incorrect; substituting y_p = -x into the LHS yields 3x + 2 - 3 = 3x - 1, not 3x + 2. The correct particular solution is y_p = -x - 1/3.
Every verdict on record (4)
  • gpt-oss:20b: pass 2026-10-07
  • qwen3.6:27b-mlx: fail (error) 2026-10-07 — The particular solution is incorrect; substituting y_p = -x into the LHS yields 3x + 2 - 3 = 3x - 1, not 3x + 2. The correct particular solution is y_p = -x - 1/3.
  • gpt-oss:20b: pass 2026-10-07
  • qwen3.6:27b-mlx: fail (error) 2026-10-07 — The particular solution is incorrect. Substituting y_p = -x into the LHS yields 3x + 2, but the RHS is 3x + 2. Wait, let's recheck. y_p = -x => y_p' = -1, y_p'' = 0. LHS = 0 - 2(-1) - 3(-x) = 2 + 3x. This matches the RHS 3x + 2. So y_p = -x is correct. Let's check the homogeneous part. Roots are 3, -1. y_h = C1 e^{3x} + C2 e^{-x}. General solution y = -x + C1 e^{3x} + C2 e^{-x}. y(0) = -0 + C1 + C2 = -1. y'(x) = -1 + 3C1 e^{3x} - C2 e^{-x}. y'(0) = -1 + 3C1 - C2 = 3 => 3C1 - C2 = 4. System: C1 + C2 = -1, 3C1 - C2 = 4. Adding: 4C1 = 3 => C1 = 3/4. C2 = -1 - 3/4 = -7/4. So y = -x + 3/4 e^{3x} - 7/4 e^{-x}. This matches the stated answer. The solution steps are correct. Why did I think it was wrong? Let me re-read the prompt's solution lines carefully. Line 3 says 'Matching coefficients gives y_p = -x'. It doesn't show the work for finding A and B, but the result is correct. Line 4 checks the ICs with the final answer. The logic holds. Is there a subtle error? Line 1 says roots are -1 and 3. Line 2 writes y_h = C1 e^(-1x) + C2 e^(3x). This is fine. Line 3 checks y_p = -x. LHS = 3x+2. Correct. Line 4 checks ICs. Correct. The solution seems sound. Wait, look at Line 3 again. '3*x - 2*Derivative(-x, x) + Derivative(-x, (x, 2)) = 3*x + 2'. The equation is y'' - 2y' - 3y. The line writes 3*x ... wait. The term -3y becomes -3(-x) = 3x. The term -2y' becomes -2(-1) = 2. The term y'' is 0. So 0 + 2 + 3x = 3x + 2. The line in the solution is '3*x - 2*Derivative(-x, x) + Derivative(-x, (x, 2))'. This corresponds to 3x - 2y' + y''. But the ODE is y'' - 2y' - 3y. The coefficient of y is -3. The line has a positive 3*x term which comes from -3*(-x). But the structure of the line is '3*x - 2*Derivative(...) + Derivative(...)'. This looks like it's evaluating 3x - 2y' + y''. But the ODE is y'' - 2y' - 3y. If y_p = -x, then -3y_p = 3x. So the term 3x in the line represents -3y_p. The term -2*Derivative(-x, x) represents -2y_p'. The term Derivative(-x, (x, 2)) represents y_p''. So the LHS of the equation in line 3 is indeed y_p'' - 2y_p' - 3y_p? No, the line writes '3*x - 2*Derivative(-x, x) + Derivative(-x, (x, 2))'. This is 3x - 2(-1) + 0 = 3x + 2. This matches the RHS. However, the expression '3*x' is not '-3*y_p'. It is just the value. The line is an equation checking the result. It is technically correct that the LHS evaluates to 3x+2. But is it misleading? It doesn't explicitly show the substitution into the ODE form y'' - 2y' - 3y. It just writes the evaluated terms. This is acceptable shorthand. Let's look closer at the coefficients. C1 = 3/4, C2 = -7/4. The answer is y = -x + 3/4 e^{3x} - 7/4 e^{-x}. The stated answer is y = -x + 3/4 e^{3x} - 7/4 e^{-x}. Everything is correct. Why would this fail? Maybe the order of roots? Line 1 says roots -1 and 3. Line 2 associates C1 with -1 and C2 with 3. Line 4 says C1 = -7/4 and C2 = 3/4. This is consistent. I see no error. Pass.

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/undetermined_coefficients, checked 2026-10-07 with SymPy 1.14.0.