# Second order ODE

1. Mar 10, 2009

### sara_87

1. The problem statement, all variables and given/known data

find the general solution to the ODE:
y''+(1/x)y'=0

2. Relevant equations

3. The attempt at a solution

I put this in the following form: y''=-(1/x)y'
integrated both sides: y'=-ln(x)y +C
I think i made a stupid mistake but i cant figure out what it is.
Any help would be appreciated. Thank you.

2. Mar 10, 2009

### phreak

You can't integrate like that. You can only integrate when you have an ODE of the form y' = f(x), where anything y isn't on the right side.

There is a general solution to ODEs of the form y'' + a(x)y' = 0, and it's probably in your textbook. Hint: multiply both sides by $$e^{\int^x_{x_0} a(t)dt}$$, and contract by the product rule for differentiation.

3. Mar 10, 2009

### sara_87

why do i have to multiply both sides by that integral?

4. Mar 10, 2009

### phreak

Because it gives you something you can integrate. You're trying to find y, right? Well, if you multiply both sides by the given function, and note that the derivative of $$e^{\int^x_{x_0} a(t)dt}$$ is $$a(x)e^{\int^x_{x_0} a(t)dt}$$, you can use the product rule to write the equation in the form (X y')' = 0, where X is something you need to find yourself (I've given you all the clues you need). You can then conclude that X y' = c, for some constant c, by integrating both sides. You now have an equation that is easily solvable if you know the very basics of differential equations.

5. Mar 12, 2009

### sara_87

ok, so i did this and my working out is:
so the 'a' is 1/x, and integrating this gives lnx so e^ln(x)=x so multiplying the ODE vy x gives:
xY''+Y'=0
so (xY')'=0
integrating both sides gives:
xY'=C (where C is a constant)
integrating again gives:
Y=Cln(x)+D (where D is a constant)
Is this correct?