What is the general solution of the differential equation y''' - y'' = e^xcosx ?

Jun 19, 2017

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

Explanation:

Given: $y ' ' ' - y ' ' = {e}^{x} \cos \left(x\right) \text{ [1]}$

Let u = $y ' '$, then $u ' = y ' ' '$ and substitute into equation [1]:

$u ' - u = {e}^{x} \cos \left(x\right) \text{ [2]}$

The integrating factor is $I = {e}^{\int - 1 \mathrm{dx}} = {e}^{-} x$

Multiply both sides of equation two by $I$:

${e}^{-} x u ' - {e}^{-} x u = {e}^{-} x {e}^{x} \cos \left(x\right)$

${e}^{-} x u ' - {e}^{-} x u = \cos \left(x\right)$

We know that the left side integrates to the product of $I u$ and the right side is well known:

${e}^{-} x u = \sin \left(x\right) + {c}_{1}$

$u = {e}^{x} \left(\sin \left(x\right) + {c}_{1}\right)$

Reverse the substitution:

$y ' ' = {e}^{x} \left(\sin \left(x\right) + {c}_{1}\right)$

$y ' = \int {e}^{x} \sin \left(x\right) \mathrm{dx} + {c}_{1} \int {e}^{x} \mathrm{dx}$

$y ' = \frac{1}{2} {e}^{x} \left(\sin \left(x\right) - \cos \left(x\right)\right) + {c}_{1} {e}^{x} \mathrm{dx} + {c}_{2}$

$y = \frac{1}{2} \int {e}^{x} \sin \left(x\right) \mathrm{dx} - \frac{1}{2} \int {e}^{x} \cos \left(x\right) + {c}_{1} \int {e}^{x} \mathrm{dx} + {c}_{2} \int \mathrm{dx}$

y = 1/4e^x(sin(x)-cos(x))-1/4e^x(sin(x)+cos(x) + c_1e^x+ c_2x+ c_3

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

Jun 19, 2017

$y \left(x\right) = A x + B + C {e}^{x} - \frac{1}{2} {e}^{x} \cos x$

Explanation:

We have:

$y ' ' ' - y ' ' = {e}^{x} \cos x$ ..... [A]

This is a Third order linear non-Homogeneous Differentiation Equation with constant coefficients. The standard approach is to find a solution, ${y}_{c}$ of the homogeneous equation by looking at the Auxiliary Equation, which is the polynomial equation with the coefficients of the derivatives, and then finding an independent particular solution, ${y}_{p}$ of the non-homogeneous equation.

Complimentary Function

The homogeneous equation associated with [A] is

$y ' ' ' - y ' ' = 0$

And it's associated Auxiliary equation is:

${m}^{3} - {m}^{2} = 0$
${m}^{2} \left(m - 1\right) = 0$

Which has repeated solutions $m = 0$, and a real distinct solution $m = 1$

Thus the solution of the homogeneous equation is:

${y}_{c} = \left(A x + B\right) {e}^{0 x} + C {e}^{1 x}$
$\setminus \setminus \setminus = A x + B + C {e}^{x}$

Note this solution has $3$ constants of integration and is therefore the complete solution for the homogeneous equation.

Particular Solution

In order to find a particular solution of the non-homogeneous equation we would look for a solution of the form:

$y = {e}^{x} \left(a \cos x + b \sin x\right)$

Where the constants $a$ and $b$ are to be determined by direct substitution and comparison:

Differentiating wrt $x$ (using the product rule) we get:

$y ' = {e}^{x} \left(- a \sin x + b \cos x\right) + {e}^{x} \left(a \cos x + b \sin x\right)$
$\setminus \setminus \setminus = {e}^{x} \left(a \cos x - a \sin x + b \cos x + b \sin x\right)$

Differentiating again wrt $x$ (using the product rule) we get:

$y ' ' = {e}^{x} \left(- a \sin x - a \cos x - b \sin x + b \cos x\right) + {e}^{x} \left(a \cos x - a \sin x + b \cos x + b \sin x\right)$
$\setminus \setminus \setminus \setminus = {e}^{x} \left(- 2 a \sin x + 2 b \cos x\right)$

Differentiating again wrt $x$ (using the product rule) we get:

$y ' ' ' = {e}^{x} \left(- 2 a \cos x - 2 b \sin x\right) + {e}^{x} \left(- 2 a \sin x + 2 b \cos x\right)$
$\setminus \setminus \setminus \setminus = {e}^{x} \left(- 2 a \cos x - 2 b \sin x - 2 a \sin x + 2 b \cos x\right)$
$\setminus \setminus \setminus \setminus = {e}^{x} \left(- 2 a \cos x - 2 a \sin x - 2 b \sin x + 2 b \cos x\right)$

Substituting into the DE [A] we get:

$y ' ' ' - y ' ' = {e}^{x} \cos x$

$\therefore {e}^{x} \left(- 2 a \cos x - 2 a \sin x - 2 b \sin x + 2 b \cos x\right) - {e}^{x} \left(- 2 a \sin x + 2 b \cos x\right) = {e}^{x} \cos x$

$\therefore - 2 a \cos x - 2 a \sin x - 2 b \sin x + 2 b \cos x - + 2 a \sin x - 2 b \cos x = \cos x$

Equating coefficients of $\cos x$ and $\sin x$ we get

$\cos : \setminus \setminus - 2 a + 2 b - 2 b = 1 \implies - 2 a = 1 \implies a = - \frac{1}{2}$
$\sin : \setminus \setminus - 2 a - 2 b + 2 a = 0 \implies - 2 b = 0 \implies b = 0$

And so we form the Particular solution:

${y}_{p} = {e}^{x} \left(- \frac{1}{2} \cos x + 0\right)$
$\setminus \setminus \setminus = - \frac{1}{2} {e}^{x} \cos x$

Which then leads to the GS of [A}

$y \left(x\right) = {y}_{c} + {y}_{p}$
$\setminus \setminus \setminus \setminus \setminus \setminus \setminus = A x + B + C {e}^{x} - \frac{1}{2} {e}^{x} \cos x$