Solving First Order ODE with Integrating Factor

  • Thread starter Thread starter bobred
  • Start date Start date
  • Tags Tags
    First order Ode
bobred
Messages
170
Reaction score
0

Homework Statement


Solve first order ODE

Homework Equations



\frac{dy}{dx}=x^2+1+\frac{2}{x}y
Rearranged
\frac{dy}{dx}-\frac{2}{x}y=x^2+1

The Attempt at a Solution


Integrating factor
p=\exp(-\int \frac{2}{x})=\exp(-2\ln x)=x^{-2}

Multiplying through by the integrating factor
\frac{d}{dy}(x^{-2}y)=x^{-2}

Integrating both sides
x^{-2}y=-x^{-1}+C

Dividing through by x^{-2}
y=Cx^2-x

The problem comes when I use say, Maple to check the answer, it gives

y=x^3+Cx^2-x

Any ideas? Thanks
 
Physics news on Phys.org
bobred said:

Homework Statement


Solve first order ODE


Homework Equations



\frac{dy}{dx}=x^2+1+\frac{2}{x}y
Rearranged
\frac{dy}{dx}-\frac{2}{x}y=x^2+1

The Attempt at a Solution


Integrating factor
p=\exp(-\int \frac{2}{x})=\exp(-2\ln x)=x^{-2}

Multiplying through by the integrating factor
\frac{d}{dy}(x^{-2}y)=x^{-2}
No, the right hand side of your original equation was x^2+ 1. Multiplying that by x^{-2} gives 1+ x^{-2}. You've dropped the "1".

Integrating both sides
x^{-2}y=-x^{-1}+C

Dividing through by x^{-2}
y=Cx^2-x

The problem comes when I use say, Maple to check the answer, it gives

y=x^3+Cx^2-x

Any ideas? Thanks
 
Thanks
 
There are two things I don't understand about this problem. First, when finding the nth root of a number, there should in theory be n solutions. However, the formula produces n+1 roots. Here is how. The first root is simply ##\left(r\right)^{\left(\frac{1}{n}\right)}##. Then you multiply this first root by n additional expressions given by the formula, as you go through k=0,1,...n-1. So you end up with n+1 roots, which cannot be correct. Let me illustrate what I mean. For this...
Back
Top