Pages

Linear Differential equation of first and second order ODE


Exercise:

Solve the following differential equations :

1) $y''+y'-2y=\left( x-1 \right){{e}^{-x}}$

2) $\left( 1+{{x}^{2}} \right)\frac{dy}{dx}=2x$

Solution:

1) Consider the characteristic equation ${{r}^{2}}+r-2=0$ for  $y''+y'-2y=0$

$\Rightarrow {{r}^{2}}+r-2=\left( r+2 \right)\left( r-1 \right)=0$ $\Rightarrow r=-2\,\,or\,\,r=1$

So ${{y}_{H}}={{c}_{1}}{{e}^{-2x}}+{{c}_{2}}{{e}^{x}}$

${{y}_{G}}={{y}_{H}}+{{y}_{p}}$

Take ${{y}_{p}}=\left( ax+b \right){{e}^{-x}}\Leftrightarrow y{{'}_{p}}=a{{e}^{-x}}-{{e}^{-x}}\left( ax+b \right)$

$\Leftrightarrow y'{{'}_{p}}=-a{{e}^{-x}}-\left( -{{e}^{-x}}\left( ax+b \right)+a{{e}^{-x}} \right)$

Now by substitution the particular solution we get the values for a and b

So $-a{{e}^{-x}}+\left( ax+b \right){{e}^{-x}}-a{{e}^{-x}}+a{{e}^{-x}}-\left( ax+b \right){{e}^{-x}}-2\left( ax+b \right){{e}^{-x}}=\left( x-1 \right){{e}^{-x}}$

$\Rightarrow -a{{e}^{-x}}-2\left( ax+b \right){{e}^{-x}}=\left( x-1 \right){{e}^{-x}}\Rightarrow -a-2ax-2b=x-1$

Hence $-2a=1\,\,\And \,\,-a-2b=-1\Leftrightarrow a=-\frac{1}{2}\,\,\And \,\,b=\frac{3}{4}$

Thus $y\left( x \right)={{c}_{1}}{{e}^{-2x}}+{{c}_{2}}{{e}^{x}}\left( -\frac{1}{2}x+\frac{3}{4} \right){{e}^{-x}}$

2) We have $\left( 1+{{x}^{2}} \right)\frac{dy}{dx}=2x$ $\Leftrightarrow \left( 1+{{x}^{2}} \right)dy=2xdx\Leftrightarrow \frac{2x}{1+{{x}^{2}}}dx=dy\Leftrightarrow \int{\frac{2x}{1+{{x}^{2}}}dx}=\int{dy}$

So $y=\int{\frac{2x}{1+{{x}^{2}}}dx=\int{\frac{d\left( 1+{{x}^{2}} \right)}{1+{{x}^{2}}}}=\ln \left| 1+{{x}^{2}} \right|+c}$

Hence $y\left( x \right)=\ln \left| 1+{{x}^{2}} \right|+c$

No comments:

Post a Comment