0
$\begingroup$

I'm trying to find the particular solution $y_p$ for:

$$y''+y=\sin x$$

I set $y_p(x)=A\sin x + B\cos x$ and differentiate 2 times: $$y_p'(x)=A\cos x - B\sin x$$ $$y_p''(x)=-A\sin x - B\cos x$$ I Insert into $$y_p''+y_p=\sin x$$

$$-A\sin x - B\cos x+ A\sin x + B\cos x=\sin x$$

And this cant be right, because the LHS. is $=0$

Where did I go wrong?

$\endgroup$
  • 3
    $\begingroup$ Thats because your $y_p$ is solution to the homogenous $y''+y=0$. $\endgroup$ – Yadati Kiran Nov 25 '18 at 16:30
  • 3
    $\begingroup$ The method of undetermined coefficients demands that you add a factor $x$ in the resonance case (with multiplicity one), $y_p(x)=Ax\sin x+Bx\cos x.$ $\endgroup$ – Lutz Lehmann Nov 25 '18 at 16:36
  • $\begingroup$ @Curl: In such cases you may take $y_p=Ax\sin x$ alone (if you are adventurous). $\endgroup$ – Yadati Kiran Nov 25 '18 at 16:48
  • $\begingroup$ @LutzL Nice, this works. $\endgroup$ – Curl Nov 25 '18 at 16:48
  • 1
    $\begingroup$ @Isham: That's why I said "if you are adventurous" (i.e. if you realise you can't if you have terms in $\cos x$). $\endgroup$ – Yadati Kiran Nov 25 '18 at 17:18
0
$\begingroup$

When the RHS has the form $$P_n(x)\sin(\omega x)$$

and $(i\omega)$ is a root of the caracteristic equation, the particular solution of the equation $$y''+y=P_n(x)\sin(\omega x)$$

will be as $$y_p=\color{red}{xQ_n(x)}\Bigl(A\cos(\omega x)+B\sin(\omega x)\Bigr)$$

$P_n$ and $Q_n$ are polynomial of degree $=n$.

| cite | improve this answer | |
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.