Let there be two functions $f,g:(a,b) \to\mathbb R$ that are differentiable in $(a,b)$ with either
$$\text{Case 1:}\qquad\lim_{x\to b} f(x) = \lim_{x\to b} g(x) = 0$$
or
$$\,\,\,\,\,\,\,\text{Case 2:}\qquad\lim_{x\to b} f(x) = \lim_{x\to b} g(x) = \pm \infty$$
I want to show that $$\lim_{x\to b} \frac{f(x)}{g(x)} = \lim_{x\to b} \frac{f'(x)}{g'(x)}$$ if the right hand side of the equation exists.
My approach:
Since $f,g$ are differentiable, we have $f'(x) \approx \frac{f(x+d)-f(x)}d$, where $d$ is an infinitesimal.
Per algebraic transformations we can therefore deduce:
$$f'(x) \approx \frac{f(x+d)-f(x)}d \\\Leftrightarrow\\
f'(x) +d_f =\frac{f(x+d)-f(x)}d \\\Leftrightarrow\\
f(x+d) = f(x) + df'(x) +dd_f
$$
(Which is a nice identity by itself)
From now on, let every variable of the form $d_x$ be an infinitesimal. We can deduce: $$\lim_{x\to b} \frac{f(x)}{g(x)} \approx\frac{f(b+d+d_2)}{g(b+d+d_2)} =\frac{f(b+d) + d_2f'(b+d) +d_2d_f}{g(b+d) + d_2g'(b+d) +d_2d_g} $$ (I've used $d+d_2$ rather than just $d$ because otherwise $f'(b)$ would be undefined)
Case 1: If the limit tends to $0$, we can simplify: $$\frac{f(b+d) + d_2f'(b+d) +d_2d_f}{g(b+d) + d_2g'(b+d) +d_2d_g} = \frac{d_3 + d_2f'(b+d) +d_2d_f}{d_4 + d_2g'(b+d) +d_2d_g} $$
And here I'm stuck. $d_3$ and $d_4$ make it impossible to cancel out $d_2$.
Is there a way to make my reasoning whole?