# Linear, second-order differential equation?

1. Sep 27, 2011

### Raen

One of my homework problems this week was:

Verify that y = sin(4t) + 2cos(4t) is a solution to the following initial value problem.

2y'' + 32y=0; y(0)=2, y'(0)=4

Find the maximum of |y(t)| for -infinity< t < infinity.

Verifying that the given y equation is a solution is easy, all there is to do is derive twice, plug in the new equations, and show that 0 = 0. I have no trouble with that. My question is with the second part, about finding the maximum positive value of y(t).

I would think that no matter how large t gets, sin and cos will always oscillate between -1 and 1. When cos is 1, obviously sin is 0. Putting in sin(4t) = 0 and cos(4t) = 1 gives me a maximum value of 2 for any y(t) as t approaches infinity. I graphed the function on a calculator to confirm this, just in case, and the graph appears to agree with me.

My confusion is that 2 isn't the correct answer. According to the website we do our homework on, the answer should be sqrt(5). There are no questions like this worked out in the book and I can't find anything online. Can anybody explain to me why y(t) has a maximum value of sqrt(5) as t approaches infinity?

Thank you!

2. Sep 27, 2011

### LCKurtz

Generally, when you have something like acos(θ) + bsin(θ) you can write it as a single trig function. You multiply and divide by the square root of the sum of the squares of the coefficients:

$$a\cos\theta + b\sin\theta = \sqrt{a^2+b^2} \left(\frac a {\sqrt{a^2+b^2}}\cos\theta + \frac b {\sqrt{a^2+b^2}}\sin\theta\right)$$

Now, since the sum of the squares of the new coefficients of the sine and cosine add up to one, they can be used as the sin(β) and cos(β) of some angle β. You then have an addition formula for a sine or cosine function with amplitude $\sqrt{a^2+b^2}$. In your example that gives amplitude $\sqrt 5$.

3. Sep 28, 2011

### HallsofIvy

Staff Emeritus
LCKurtz's response is, as always, excellent.

Raen, you seem to be assuming that a maximum of f+ g must occur where either f or g has a maximum (since you looked immediately at cos(x)= 1) and that is not correct.

Another way to find a maximum or minimum for a function is (as I am sure you know) is to look where the derivative is 0. If f(x)= sin(4x)+ 2cos(4x), then f'(x)= 4cos(4x)- 8sin(4x)= 0 when 4 cos(4x)= 8 sin(4x) or cos(4x)= 2sin(4x). Rather than solve for x directly, note that $cos^2(4x)= 4 sin^2(4x)$ so $sin^2(4x)+ cos^2(4x)= 5 sin^2(4x)= 1$ so that $sin^2(4x)= 1/5$ and $sin(4x)= 1/\sqrt{5}= \sqrt{5}/5$. And, of course, $cos^2(4x)= 1- sin^2(x)= 4/5$ so $cos(4x)= 2/\sqrt{5}= 2\sqrt{5}/5$.

Putting those back into the original formula, $sin(4x)+ 2cos(4x)= \sqrt{5}/5+ 4\sqrt{5}/5= 5/\sqrt{5}= \sqrt{5}$

Last edited: Sep 28, 2011
4. Sep 28, 2011

### Raen

Oh, I think I understand now. Thank you both for your detailed explanations!