\documentclass[12pt]{amsart}
\setlength{\textheight}{9in}
\setlength{\textwidth}{6.5in}
\setlength{\oddsidemargin}{0in}
\setlength{\evensidemargin}{0in}

\setlength{\topmargin}{-0.5in}
\usepackage{amssymb,amsmath,amsfonts,graphicx,psfrag}

%\pagestyle{empty}
\newcommand{\dis}{\displaystyle}
\newcommand{\bd}{\partial}
\begin{document}
{\Large

\begin{center}
{\bf Homogeneous Second Order Differential Equations with Constant Coefficients: Continued}
\end{center}


{\bf Complex roots.}

The final case is what to do when the roots of the characteristic polynomial are complex. Recall that this means
they will be of the form $p\pm qi$ for real numbers $p$ and $q$ where $i^2 = -1$. (This assumes that the coefficients
$a$, $b$ and $c$ are real.) We will need to ``review'' some facts about complex functions that where censored from your
calculus textbook.  

But  first, let's look at a simple example, $y'' + y = 0$. We can rewrite this as $y'' = -y$. So, we are seeking functions whose second derivatives 
are their own negatives. Two might come to mind, $\sin x$ and $\cos x$. In fact $y=C_1 \sin x + C_2 \cos x$ gives all
possible solutions, as we will show later. 

The roots of the characteristic polynomial, $r^2 + 1 = 0$, are $\pm i$. Notice that
\[
(e^{ix} )'' = (ie^{ix})' = i^2 e^{ix} = -e^{ix}.
\]
But, what does it mean to raise $e$ to a complex power? And, what does it mean to take a derivative of such a function? And,
how are these functions connected to $\sin x$ and $\cos x$?

Way back in Calculus II you studied Taylor series and you learned that
\[
e^x = 1 + x + \frac{x^2}{2} + \frac{x^3}{3!} + \frac{x^4}{4!} + \cdots .
\]
Suppose $z=a+ib$ is a complex number. Then we define
\[
e^z = 1 + z + \frac{z^2}{2} + \frac{z^3}{3!} + \frac{z^4}{4!} + \cdots .
\]
In courses on Complex Analysis (MATH 455 here) it is shown that this sequence converges for all complex
numbers $z$. The derivative can be defined via term-by-term differentiation. 
The following facts can also be proven:
\[
e^{a+ib} = e^a e^{ib}
\]
\[
\frac{de^{\alpha ix}}{dx} = \alpha i e^{\alpha ix},
\]
for any real (or complex) number $\alpha$. Now watch.
\[
e^{ix} =  1 + ix + \frac{(ix)^2}{2} + \frac{(ix)^3}{3!} + \frac{(ix)^4}{4!} + \frac{(ix)^5}{5!} 
+  \frac{(ix)^6}{6!} + \frac{(ix)^7}{7!} +  \frac{(ix)^8}{8!} + \cdots 
\]
\[
= 1 + ix - \frac{x^2}{2} -i \frac{x^3}{3!} + \frac{x^4}{4!} + i \frac{x^5}{5!} 
- \frac{x^6}{6!} -i \frac{x^7}{7!} +  \frac{x^8}{8!} + \cdots 
\]
\[
 = \left(1 - \frac{x^2}{2} + \frac{x^4}{4!} - \frac{x^6}{6!} +  \frac{x^8}{8!} + \cdots \right) +
 i \left(x  - \frac{x^3}{3!} +  \frac{x^5}{5!}  - \frac{x^7}{7!} +  \cdots\right)
\]
\[
=  \cos x + i \sin x.
\]

Now let's get back to differential equations. Suppose we have $ay'' + by' + cy =0$
and the roots of $ar^2 + br + c$ are $\alpha \pm i\beta$. Then the general solution
is \[
y = C_1 e^{(\alpha + i \beta)x} + C_2 e^{(\alpha - i \beta)x} = (C_1 e^{i\beta x} + C_2 e^{-i\beta x}) e^{\alpha x}
\]
\[
= (C_1(\cos (\beta x) + i \sin (\beta x)) + C_2(\cos (\beta x) - i \sin (\beta x)))e^{\alpha x}
\]
\[
= \left( (C_1+C_2)\cos (\beta x) + i(C_1-C_2) \sin (\beta x )\right) e^{\alpha x}.
\]
We can rewrite this as
\[
A e^{\alpha x} \cos \beta x  + B e^{\alpha x} \sin \beta x. 
\]

{\bf Theorem 3.} The general solution to $ay'' + by' + cy =0$ when the roots 
of the characteristic polynomial are $\alpha \pm i \beta$ is
\[
y = A  e^{\alpha x} \cos \beta x  + B e^{\alpha x} \sin \beta x.
\]
If $y(x_0) = p$ and $y'(x_0) = q$ then there is a unique solution for $A$ and $B$.

\begin{proof}
We have already derived the solution, but you can check it by directly substituting it in 
to the differential equation. Next, $y(x_0) = p$ implies 
\[
 A \cos \beta x_0  + B  \sin \beta x_0  = p e^{-\alpha x_0}.
\]
And $y'(x_0) = q$ implies
\[
 A\alpha e^{\alpha x_0} \cos \beta x_0 -A\beta e^{\alpha x_0} \sin \beta x_0 + B \alpha e^{\alpha x_0} \sin \beta x_0 + B \beta e^{\alpha x_0} \cos \beta x_0  = q,
\]
or
\[
A(\alpha \cos \beta x_0 - \beta \sin \beta x_0) + B(\beta \cos \beta x_0 +  \alpha \sin \beta x_0) = qe^{-\alpha x_0}.
\]
So, again we have two equations and two unknowns and these can readily by solved for $A$ and $B$.
\end{proof}


{\bf Example.} Find the general solution to $y'' - y' + 2y = 0$. Then find the solution for the initial values
$y(0) = p$, $y'(0) = q$.

\begin{proof}[Solution]
The characteristic polynomial $r^2 - r + 2$ has complex roots $r= \frac{1}{2} \pm i\frac{\sqrt{7}}{2}$. Thus, the general solution is
\[
y(x) = A e^{\frac{1}{2}x} \cos \frac{\sqrt{7}}{2} x + B e^{\frac{1}{2}x} \sin \frac{\sqrt{7}}{2} x .
\]

Now, $y(0)=p$ implies $A = p$ and $y'(0) = q$ gives $p/2  + B\sqrt{7}/2 = q$. Thus, $B = \frac{2q-p}{\sqrt{7}}$ and we have
\[
y(x) = p e^{\frac{1}{2}x} \cos \frac{\sqrt{7}}{2} x  + \frac{2q-p}{\sqrt{7}}e^{\frac{1}{2}x} \sin \frac{\sqrt{7}}{2} x .
\]
\end{proof}


\begin{center}{\bf Summary}\end{center}

Given $ay''(x) + by'(x) + cy(x) = 0$ we have three cases. These 
depend on the roots of the characteristic polynomial 
$ar^2 + br + c=0$.

\begin{itemize}

\item[{\bf Case 1.}] The roots of the characteristic polynomial, 
$r_1$ and $r_2$, are real and distinct, that is $r_1 \neq r_2$. Then 
the general solution is 
\[
y(x) = C_1 e^{r_1x} + C_2 e^{r_2x}.
\]

\item[{\bf Case 2.}] The characteristic polynomial has a single 
real root, $r$.  Then the general solution is 
\[
y(x) = C_1 e^{rx} + C_2 xe^{rx}.
\]

\item[{\bf Case 3.}] The roots of the characteristic polynomial are 
complex conjugates, $\alpha \pm \beta$.  Then 
the general solution is 
\[
y(x) = C_1 e^{\alpha x} \cos \beta x + C_2 e^{\alpha x} \sin \beta x.
\]
\end{itemize}

In each case we can find unique values of $C_1$ and $C_2$ for 
any given pair of initial conditions of the form
\[
y(x_0) = y_0 \:\:\:\&\:\:\: y'(x_0) = v_0.
\]



}
\end{document}


