ODE Equation not satisfied at one point I was working through the following separable equation
$$\frac{dy}{dx}=\frac{y-1}{x}$$
I noted that if we can find a solution $y(x)$, then it is not differentiable at $x=0$. I found the general solution to be $y(x)=1+Cx$ where $C\in\mathbf{R}$. However, this function is differentiable at $x=0$. So it seems to satisfy the differential equation for all nonzero values of $x$ but not when $x=0$. 
I also noted that $y(x)=1+Cx$ satisfies the differential equation 
$$x\frac{dy}{dx}=y-1$$
for all values of $x$. 
I'm not sure what to conclude from this. It seems like it's not really an issue since the equation is only not satsified at a single point. Is there something incorrect with my reasoning here?
The second part of the exercise included the initial condition $y(0)=1$. Just considering the general solution that obtained $y(x)=1+Cx$, it appears that $y(x)=1+Cx$ also satisfies the initial condition for all values of $C$. However, this is at $x=0$, so something seems off. Can someone help me understand this better? Did I conclude something incorrectly?
 A: You are right that this appears to be a little funky. What's missing from the problem is what kind of function $y$ is. Is the domain $\mathbb R$ or $\mathbb R^+$ or $\mathbb R\setminus\{0\}$ or something else? If the domain contains zero, should we also consider $y$ to be continuous? Differentiable? These sorts of implied things will tell us how we should be handling $y(0)$. In the most general case of a domain of $\mathbb R$, without any specification on the behavior at zero, the solution should actually be given by
$$y(x)=\begin{cases}1+C_1x,&x<0\\C_2,&x=0\\1+C_3x,&x>0\end{cases}$$
for $C_1,C_2,C_3\in\mathbb R$.
In the case that $y$ is continuous, this would mean $C_2=1$.
In the case that $y$ is differentiable, this would also mean $C=C_1=C_3$, and hence $y(x)=1+Cx$, as you found.
A: I think that you are saying that the solution should not be differentiable at x=0 because x is in the denominator. The thing that you should ask yourself is that does the numerator go to zero as x goes to zero? The answer to this question is yes as you can see from the solution of the ODE. If the numerator was non zero, then you could say that the derivative is infinite at x=0. So, the derivative would have the value C at x=0 (easy to check) and it would not be infinite at x=0. Thus, the solution is perfectly differentiable at x=0.
A: As you are treating this as an ODE, the singularity of the right side at $x=0$ means that the line $\{(0,y): y\in\Bbb R\}$ is not part of the domain of the ODE. As it splits the plane into two halves, you have to look at the initial condition to decide in which half-plane the solution exists as curve, or which half of the $x$-axis contains the domain of the solution.
That you can combine solutions in both half-planes to form a piecewise defined function that has a continuous or even differentiable extension to $x=0$ has nothing to do with the study of solutions of the ODE.
