Ordinary Differential Equations – Legitimacy of Solving $\frac{dy}{dx}=\frac{y}{x}$ by Integration

ordinary differential equations

Answers to this question Homogeneous differential equation $\frac{dy}{dx} = \frac{y}{x}$ solution? assert that to find a solution to the differential equation $$\dfrac{dy}{dx} = \dfrac{y}{x}$$ we may rearrange and integrate $$\int \frac{1}{y}\ dy=\int \frac{1}{x}\ dx.$$ If we perform the integration we get $\log y=\log x+c$ or $$y=kx$$ for constants $c,k \in \mathbb{R}$. I've seen others use methods like this before too, but I'm unsure why it works.

Question: Why is it legitimate to solve the differential equation in this way?

Best Answer

To be honest I think it's BS to teach separable variables like this without the Riemann-Stieljes integral.
The way I solve them is by doing what actually is done: integrate with respect to $x$ on both sides.


Remember that $y$ is a function (on the variable $x$). So your differential equation is, for all $x$ in a certain interval, $y'(x)=\dfrac{y(x)}{x}$ or equivalently $\dfrac{y'(x)}{y(x)}=\dfrac {1}{x}$and integrating with respect to $x$ you get the desired result.

In my opinion integrating with respect to $y$ is nothing more than a cheap trick, the same way $\dfrac{dy}{dx}=1\iff dy=dx$ is a cheap trick. It works only because of some higher math.


More generally, if you can rewrite your DE as $g(y(x))y'(x)=f(x)$ for some functions $f$ and $g$ that have antiderivatives, $F$ and $G$, in the given interval, then $g(y(x))y'(x)=f(x)\iff G(y(x))=F(x)+C$, for some $C\in \Bbb R$. (To establish $\Longleftarrow$ just differentiate). And if we're lucky enough for $G$ to be invertible, we get $y(x)=G^{-1}\left(F(x)+C\right)$. If $G$ isn't invertible, then hopefully the implicit function theorem will yield the solutions to the DE implicitly by the equation $G(y(x))=F(x)+C$.

In your example $g$ is the function $t\mapsto \dfrac{1}{t}$ which has $t\to \log (|t|)$ as an antiderivative. (Don't forget the absolute value).

Related Question