The slope $\frac{dy}{dx}$ is in fact not a ratio (it is the limit of a ratio), but it is true that $\frac{dy}{dx} = \frac{g(x,y)}{f(x,y)}$ whenever $f(x,y) \
eq 0$, for in that case
* from the inverse function theorem $x(t)$ has a local inverse whose derivative is $\frac{dt}{dx}=\frac{1}{\frac{dx}{dt}}=\frac{1}{f(x,y)}$;
* from the chain rule $\frac{dy}{dx}=\frac{dy}{dt} \frac{dt}{dx}=\frac{g(x,y)}{f(x,y)}$.