# homogenous second-order differential equations

#### Trenters4325

##### Junior Member
The solutions of the equation y'' + ay' + by = 0 can involve trigonometric functions when the solutions to the characteristic equation are complex. How do you transform the equation with complex numbers in the exponent to the equation with trigonometric functions. I am aware of Euler's formula, but that involves the imaginary component as a coefficient of the trigonometric function, which is not present in the solutions to that diffy q.

#### galactus

##### Super Moderator
Staff member
Here's an example:

Let's try $$\displaystyle y''+y'+y=0$$

The characteristic equation is:

$$\displaystyle \L\\m^{2}+m+1=0$$

It's roots are:

$$\displaystyle \L\\\frac{-1}{2}+\frac{\sqrt{3}}{2}i$$ and $$\displaystyle \L\\\frac{-1}{2}-\frac{\sqrt{3}}{2}i$$

The -1/2 is $$\displaystyle {\alpha}$$and the$$\displaystyle \pm\frac{\sqrt{3}}{2}$$is $$\displaystyle {\beta}$$ in $$\displaystyle {\alpha}+{\beta}i$$

So, you'd have:

$$\displaystyle \L\\y=e^{\frac{-1}{2}x}(C_{1}cos(\frac{\sqrt{3}}{2})x+C_{2}sin(\frac{\sqrt{3}}{2})x)$$

Also,

$$\displaystyle \L\\y=C_{1}e^{(\frac{-1}{2}+\frac{\sqrt{3}}{2}i)x}+C_{2}e^{(\frac{-1}{2}-\frac{\sqrt{3}}{2}i)x}$$

#### Trenters4325

##### Junior Member
First of all, in the last equation, I think your missing an i in the exponent.

I can't figure out how the last two equations that you wrote are equivalent. Can you show some of the intermediary steps?

#### galactus

##### Super Moderator
Staff member
It's the Euler thing you mentioned.

We know are solutions are in the form:

$$\displaystyle \L\\y=C_{1}e^{({\alpha}+i{\beta})x}+C_{2}e^{({\alpha}-i{\beta})x}$$

But, mostly, we would rather have real functions instead of complex

exponentials, so we use Euler's formula:

$$\displaystyle \L\\e^{i{\theta}}=cos{\theta}+isin{\theta}$$

Therefore,

$$\displaystyle \L\\e^{i{\beta}x}=cos{\beta}x+isin{\beta}x\ and\ e^{-i{\beta}x}=cos{\beta}x-isin{\beta}x$$

we have used $$\displaystyle cos({-\beta}x)=cos({\beta}x)\ and\ sin({-\beta}x)={- sin({\beta}x)$$

By adding and then subtracting the equations in , we get:

$$\displaystyle \L\\e^{i{\beta}x}+e^{-i{\beta}x}=2cos{\beta}x$$ and

$$\displaystyle \L\\e^{i{\beta}x}-e^{-i{\beta}x}=2isin{\beta}x$$

Since $$\displaystyle \L\\y=C_{1}e^{({\alpha}+i{\beta})x}+C_{2}e^{({\alpha}-i{\beta})x}$$ is a solution of $$\displaystyle \L\\ay''+by'+cy=0$$

for any $$\displaystyle C_{1}\ and\ C_{2}$$, we can choose $$\displaystyle C_{1}=C_{2}=1\ and\ C_{1}=1,\ C_{2}=-1$$ give two solutions:

$$\displaystyle y_{1}=e^{({\alpha}+i{\beta})x}+e^{({\alpha}-i{\beta})x}$$ and

$$\displaystyle y_{2}=e^{({\alpha}+i{\beta})x}-e^{({\alpha}-i{\beta})x}$$

But, $$\displaystyle \L\\y_{1}=e^{{\alpha}x}(e^{i{\beta}x}+e^{-i{\beta}x}) =2e^{{\alpha}x}cos{\beta}x\ and\ y_{2}=e^{{\alpha}x}(e^{i{\beta} x}-e^{-i{\beta}x})=2ie^{{\alpha}x}sin{\beta}x$$

The superposition principle says that the real functions $$\displaystyle \L\\e^ {{\alpha}x}cos{\beta}x\ and\ e^{{\alpha}x}sin{\beta}x$$ are

solutions of

$$\displaystyle \L\\ay''+by'+cy=0$$

So, the general solution is:

$$\displaystyle \L\\y=C_{1}e^{{\alpha}x}cos{\beta}x+C_{2}e^{{\alpha}x}sin {\beta}x=e^{{\alpha}x}(C_{1}cos{\beta}x+C_{2}sin{\beta}x)$$

I hope this helps. If you need a more thorough explanation, I'd suggest

seeing your professor. I'm LaTexed out :lol:

#### Trenters4325

##### Junior Member
galactus said:
$$\displaystyle =2e^{{\alpha}x}cos{\beta}x\ and\ y_{2}=e^{{\alpha}x}(e^{i{\beta} x}-e^{-i{\beta}x})=2ie^{{\alpha}x}sin{\beta}x$$

The superposition principle says that the real functions $$\displaystyle \L\\e^ {{\alpha}x}cos{\beta}x\ and\ e^{{\alpha}x}sin{\beta}x$$ are

solutions of

$$\displaystyle \L\\ay''+by'+cy=0$$

So, the general solution is:

$$\displaystyle \L\\y=C_{1}e^{{\alpha}x}cos{\beta}x+C_{2}e^{{\alpha}x}sin$$
How did you get rid of the imaginary component in the coefficient of that sine function?

#### galactus

##### Super Moderator
Staff member
Because a constant multiple of a solution of a HLDE is also a solution

#### Trenters4325

##### Junior Member
So, you multiplied it by 1/2i?