How to Solve this Differential Equation? dy/dx = xy/2; y(0) = 2

koreamaniac101

New member
Joined
Dec 20, 2016
Messages
7
For this following equation:

. . . . .\(\displaystyle \dfrac{dy}{dx}\, =\, \dfrac{xy}{2};\, y(0)\, =\, 2\)

I was instructed to use Euler's Method to solve it. However, after doing two iterations of Euler's Method, I was asked to definitively solve the equation for x=0.5. This is the solution they gave:

. . . . .\(\displaystyle \dfrac{dy}{dx}\, =\, \dfrac{xy}{2};\, y(0)\, =\, 2\)

. . . . .\(\displaystyle \dfrac{dy}{y}\, =\, \dfrac{x\, dx}{2}\)

. . . . .\(\displaystyle \displaystyle \int\, \dfrac{dy}{y}\, =\, \int\, \dfrac{x\, dx}{2}\)

. . . . .\(\displaystyle \ln|y|\, =\, \dfrac{x^2}{4}\, +\, C\)

. . . . .\(\displaystyle \ln(2)\, =\, 0\, +\, C\)

. . . . .\(\displaystyle y\, =\, 2\, e^{x^2 / 4}\)

. . . . .\(\displaystyle y(0.5)\, =\, 2\, e^{0.25 / 4}\, \approx\, 2.1290\)

My question is: when they plugged in the (0,2) initial coordinate into the equation, didn't they solve for C. If so, why isnt C part of the exponent for the e on the right side? When they solved for the natural log of y, shouldn't the e on the other side include the c value?
 

Attachments

  • Capture.PNG
    Capture.PNG
    1.9 KB · Views: 20
  • Capture.jpg
    Capture.jpg
    10 KB · Views: 4
Last edited by a moderator:
It does. You know, I hope, that \(\displaystyle e^{a+ b}= e^ae^b\). You have \(\displaystyle ln|y|= x^2+ C\) and found that C= ln(2). So you have \(\displaystyle ln|y|= x^2+ ln(2)\) and, taking the exponential on each side, \(\displaystyle |y|= e^{x^2+ ln(2)}= e^{x^2}e^{ln(2)}= 2e^{x^2}\). Also, note that you do not need the absolute value signs since \(\displaystyle 2e^{x^2}\) is positive for all x.
 
Last edited:
Top