# Solutions intervals of a differential equation

I cannot understand the difference between these two ODEs in terms of the intervals in which solutions are defined

$y' y=(x+1)$

$y'=\frac{x+1}{y}$

The equation is actually the same but in the first case for $y=0$ I get $x=-1$ and I don't see what is the problem in that point, while in the second one it is necessary to impose $y\neq 0$ of course.

What does that mean? Are the solutions different for the two equations? If yes, in what do they differ?

Thanks a lot for your help

• The solutions of these two equations are same. From the first one you can solve it by integration while by the second one you have an existence-uniqueness theorem for your equation with an initial condition. – Albert Dec 29 '15 at 18:26
• i got $y(x)= \pm \sqrt{x^2+2x+C}$ for both equations – Dr. Sonnhard Graubner Dec 29 '15 at 18:28
• Thanks for the answers, I got the same solutions but I wonder what happens for $y=0$, can any solution cross the x axis? And if no I don't get why, I mean from the first equation it looks like all the solution should pass through the point $(-1,0)$, is this a problem? – Gianolepo Dec 29 '15 at 18:37

SHORT ANSWER: In your first equation, $x=-1,\ y=0$ seems to be a solution. It would be, if $y'$ were also defined. However, if $y=0$ for any $x$ then $y'$ will be undefined there, so that is not actually a solution. The only restrictions on your second equation are $y=0$ and both $y$ and $y'$ are defined, so the solutions for your equations are indeed the same.

SOME DETAILS: You already know that separation of variables give us the solution for the first equation:

$$y=\pm\sqrt{x^2+2x+C}$$

for some real constant $C$. The derivative of this is

$$y'=\pm\frac{x+1}{\sqrt{x^2+2x+C}}=\pm\frac{x+1}y$$

So we see that for any $x$, if $y=0$ then $y'$ is undefined. Depending on the values of $x$ and $C$ the value of $y$ itself may not be defined, and we see the same conditions for both $y$ and $y'$ to exist are also conditions for your second equation to make sense. Therefore the solutions to those equations are exactly the same.

Here is another way to look at it. It seems that $x=-1,\ y=0$ should be a solution to your first equation. However, as soon as $x$ moves away from $-1$ then $y$ can no longer be zero. As we look at how quickly $y$ must move away from zero, we see that the demands on the rate of change of $y$ are too contradictory to satisfy your first equation. So our apparent solution $x=-1,\ y=0$ was not actually a solution.

Let's look more at $y'$. If we substitute $x=-1,\ y=0$ into our solution $y=\pm\sqrt{x^2+2x+C}$ we get $C=1$. So the function(s) is/are actually

$$y=\pm\sqrt{x^2+2x+1}=\pm\sqrt{(x+1)^2}=\pm|x+1|$$

I'm sure you know that the absolute value function has no derivative at zero, since the left-hand and right-hand derivatives there are not equal. As I said, the demands on the rate of change of $y$ where $y=0$ are inconsistent, so $y'$ does not exist there.

$$yy' = x+1$$ $$y^2 = (x+1)^2+C.$$ $$y = \pm\sqrt{(x+1)^2+C},\quad(x+1)^2 + C \geq 0.$$ Or: $$y = \pm\sqrt{(x+1)^2+C},$$ $$x\in \begin{cases} (-\infty, +\infty),\text{ if }C \geq -1\\[3pt] \left(-\infty. -\sqrt{-C}-1\right)\, \cup (\sqrt{-C}-1, +\infty),\text{ if }C <-1. \end{cases}$$