# Solving 2nd order differential

1. Nov 12, 2012

### th3chemist

1. The problem statement, all variables and given/known data
I have to determine the 2nd,3rd and 4th derivative at 0. So ψ''(0)

The equation is y'' + sin(x)y' + cos(x)y = 0

A know solution is y = ψ(x).

The intial conditions are y(0) = 0 , y'(0) = 1

2. Relevant equations

3. The attempt at a solution

I know this is a 2nd order differential equation. However I don't know what to do. I can't use characteristic equations in this case. And if I juts take the 1st and 2nd derivative here and plug them I won't attain anything.

2. Nov 13, 2012

### rock.freak667

If you have

y''(x) + sin(x)y'(x) + cos(x)y(x) = 0

and you want y''(0), just put in x=0 into the DE. You are given what y'(0) and y(0) are. So you should be able to get y''(0).

Similarly you can differentiate the entire DE to get what y'''(x) would be and so on.

3. Nov 13, 2012

### th3chemist

Could I not sole for y''(x) = -sin(x)y'(x) - cos(x)y(x)
then sub in x=0 ?

4. Nov 13, 2012

### SammyS

Staff Emeritus
You're not being asked to solve the D.E.

Last edited: Nov 13, 2012
5. Nov 13, 2012

### HallsofIvy

Yes, that is essentially what rock.freak667 suggested. He suggested setting x= 0 first and then solving but it is the same thing.

And once you have that, $y'''(x)= (-sin(x)y'(x)- cos(x)y(x))'= -cos(x)y'(x)- sin(x)y''(x)+ sin(x)y(x)-cos(x)y'(x)$ And now you know y(0), y'(0), and y''(0) and can just substitute those.

This is, in fact, a way of solving such a differential equation as a Maclaurin series- you calculate the derivatives at x= 0 successively. It is, unfortunately not a very efficient method.

6. Nov 13, 2012

### th3chemist

But then how do I get the original function back from that?

7. Nov 13, 2012

### rock.freak667

Why do you want to get the original function?

8. Nov 13, 2012

### th3chemist

Don't I need it to find the other derivatives at 0? And what about the constants that get produced? Arn't initial values used to solve them?

9. Nov 13, 2012

### rock.freak667

Not really, because even if you found y(x), you'd still need to find y'''(x) and y''''(x) which when you reach the second derivative, you'd get the original DE which the question gave to you.

The question is not asking you to solve the DE, it is asking you to get y'''(0) and y''''(0).

You are given y(0) and y'(0), using the original DE, you need to get y''(0). So you can just out x=0 into the DE and rearrange to get y''(0).

Then if you differentiate the left side and right sides wrt x, you will get a term of y''' which is what you want to find.

e.g.

y'' + y = 0

If you know y(0)=1 and you want to get y'''(0)

you can say

y''(0) + 1 = 0 or y''(0) = -1

d/dx (y'' + y') = d/dx(0)

y''' + y'' = 0

so y'''(0) + y''(0) = 0 and then you can solve for y'''(0).

10. Nov 13, 2012

### HallsofIvy

If you want the original function, then you could do as I suggested: keep differentiating to get the Maclaurin series.

However, the problem you originally posted said nothing about getting the "original function", just getting the "second, third, and fourth derivatives at x= 0". You can do that without finding the function itself.

11. Nov 13, 2012

### th3chemist

Alright. So I would take this equation, determine the 3rd derivative and the 4th and then sub in x=0? sounds simple enough :p.

Does the solution they give not matter?

12. Nov 13, 2012

### SammyS

Staff Emeritus
What solution is given ?

13. Nov 13, 2012

### th3chemist

There's a known solution is y = ψ(x).

14. Nov 14, 2012

### HallsofIvy

What, exactly, is the statement of the problem you are trying to solve? You originally said only "I have to determine the 2nd,3rd and 4th derivative at 0". You are given that
y(0) = 0 , y'(0) = 1, and y'' + sin(x)y' + cos(x)y = 0.

You do NOT need to know y in order to answer that.