Ordinary Differential Equations – Solving $y’=2xy$, $y(0)=2$

ordinary differential equations

When solving the differential equation $y'=2xy$, $y(0)=2$, we say:
$$\int\dfrac{dy}{y}=\int2xdx+C$$
$$ln|y|=x^2+C$$

But how could we divide by y, What if it is equal to zero at some point?

Best Answer

Whenever you solve a separable ODE, you should begin by identifying any stationary solutions to the equation. Provided you have uniqueness, any other solutions will never cross the stationary solutions, so that all solutions are either completely stationary or can be found by separation of variables. Without uniqueness, problems can arise; you might consider the problem $y'=y^{2/3},y(0)=0$ for an example.

In your particular problem, the possible solutions to the original DE are the one you found using separation of variables, as well as $y=0$. Your equation has unique solutions, so with your initial condition, you will not hit zero, and so the division is legitimate.

Related Question