I see an equation like this:
$$y\frac{\textrm{d}y}{\textrm{d}x} = e^x$$
and solve it by "separating variables" like this:
$$y\textrm{d}y = e^x\textrm{d}x$$ $$\int y\textrm{d}y = \int e^x\textrm{d}x$$ $$y^2/2 = e^x + c$$
What am I doing when I solve an equation this way? Because $\textrm{d}y/\textrm{d}x$ actually means
$$\lim_{\Delta x \to 0} \frac{\Delta y}{\Delta x}$$
they are not really separate entities I can multiply around algebraically.
I can check the solution when I'm done this procedure, and I've never run into problems with it. Nonetheless, what is the justification behind it?
What I thought of to do in this particular case is write
$$\int y \frac{\textrm{d}y}{\textrm{d}x}\textrm{d}x = \int e^x\textrm{d}x$$ $$\int \frac{\textrm{d}}{\textrm{d}x}(y^2/2)\textrm{d}x = e^x + c$$
then by the fundamental theorem of calculus
$$y^2/2 = e^x + c$$
Is this correct? Will such a procedure work every time I can find a way to separate variables?