1
$\begingroup$

I'm given a problem with the ODE

y'[x]=y[x]*Sqrt[4-2y[x]]

I've tried

DSolve[{w'[x] == w[x]*Sqrt[4 - 2*w[x]]}, w[x], x]

which gives me

{{w[x] -> -2 (-1 + Tanh[1/2 (-2 x - Sqrt[2] C[1])]^2)}}
but that doesn't seem correct for some reason.

Can someone please point me in the direction of how to do this problem correctly? I don't really understand Mathematica at all.

  • 0
    Do you have boundary conditions by any chance that you could use to plot the solution? `{{w[x] -> -2 (-1 + Tanh[1/2 (-2 x - Sqrt[2] C[1])]^2)}}` is what I got on Mathematica as well. What were you expecting?2012-10-25

1 Answers 1

1

here is a soultion by Maple

$ x+\frac{1}{2}\,\ln \left( \sqrt {4-2\,y \left( x \right) }+2 \right)- \frac{1}{2}\, \ln \left( -2+\sqrt {4-2\,y \left( x \right) } \right) +{\it \_C1}=0\,.$

solving the above equation for $y$, gives

$ y(x) = -{\frac {{{8\rm e}^{2\,x+2\,{\it C1}}}}{ \left( {{\rm e}^{2\,x+2\, {\it C1}}}-1 \right) ^{2}}} \,.$

The differential equation can be solved by the method of separation of variables

$ \frac{dy}{dx}=y \sqrt{4-2y}\implies \int \frac{dy}{y \sqrt{4-2y}}=\int dx + C \,.$

You need to work out the above integrals and then solve the resulting equation for y to get y as a function of $x$.

  • 0
    I think I'm close. Clear[eq1, eq2, x, y, func]; eq1 = Integrate[1/(w*Sqrt[4 - 2*w]), w]; eq2 = Integrate[1, x]; func = eq1 == eq2; Solve[func]; gives me {{x -> 1/2 Log[2 - Sqrt[4 - 2 w]] - 1/2 Log[2 + Sqrt[4 - 2 w]]}}2012-10-25