Define $f\left(x\right) = \frac{x}{x + \frac{x}{x + \frac{x}{x + \frac{x}{x + \vdots}}}}$. What is $f'\left(x\right)$, the derivative? Since $f\left(x\right)$ is indeed an infinitely deep continued fraction, I have seen that $f\left(x\right) = \frac{x}{x + f\left(x\right)}$, but taking the derivative of both sides from there has not worked. I have tried to roughly figure out what $f\left(x\right)$ is in terms of $x$, and the work is down here (except I have also run into a dead end with this one once I then took the derivative in the end).
$f\left(x\right) = \frac{x}{x + f\left(x\right)}$
$f\left(x\right)\left(x + f\left(x\right)\right) = x$
$x \cdot f\left(x\right) + {\left(f\left(x\right)\right)}^{2} = x$
${\left(f\left(x\right)\right)}^{2} = x - x \cdot f\left(x\right)$
${\left(f\left(x\right)\right)}^{2} = x\left(1-f\left(x\right)\right)$
$\frac{\left(f\left(x\right)\right)^{2}}{1-f\left(x\right)} = x$
I don't know what to do from there. Maybe I'm just complicating things more than they should be. :]
 A: We have $f^2(x) + xf(x) - x = 0$ equation, there are two functions satisfying this equation:
$$f_+(x) = \frac{-x+\sqrt{x^2+4x}}{2}$$ and
$$f_-(x) = \frac{-x - \sqrt{x^2+4x}}{2}$$
both functions are undefined for $ -4 < x < 0$. There are also the following properties for these functions:
$$x > 0 \implies f_+(x) > 0, f_-(x) < 0$$
and
$$x<-4 \implies f_+(x) > 2, f_-(x) < 2$$
Also
$$f(x) = \lim_{n \to \infty}f_n(x), f_0(x) = 1, f_{n+1}(x) = \frac{x}{x+f_n(x)}$$
There following is true:
$$x < -4,f_n(x) < 2 \implies f_{n+1}(x) < 2$$
and
$$ x > 0, f_n(x) > 0 \implies f_{n+1}(x) > 0$$
Since $0 < f_0(x) < 2 $, $x < -4 \implies f(x) \le 2$ and $x > 0 \implies f(x) \ge 0$.
This means that
$f(x) = f_-(x)$ for $x < -4$
and
$f(x) = f_+(x)$
for $x > 0$.
So,
$$f_-'(x) = \frac{-\frac{x+2}{\sqrt{x^2+4x}}-1}{2}$$
and
$$f_+'(x) = \frac{\frac{x+2}{\sqrt{x^2+4x}}-1}{2}$$
and $f'(x)$ is not defined for $-4 \le x \le 0$.
Bonus: let $g(x) = f'(x)$.
$$ \forall x, x < -4 \lor x>0: (g(x)-f'_-(x))(g(x)-f'_+(x)) = 0$$
$$ g^2(x) -(f'_-(x)+f'_+(x))g(x) + f'_-(x)f'_+(x) = 0$$
$$ g^2(x) + g(x) + \frac{1-\frac{(x+2)^2}{x^2+4x}}{4} = 0$$
$$ g^2(x) + g(x) - \frac{1}{x^2+4x} = 0$$
$$ g(x)(g(x)+1) = \frac{1}{x^2+4x}$$
Let $d(x) = x^2+4x$.
$$g(x) = \frac{1}{d(x)+d(x) g(x)}$$
$$g(x) = \frac{1}{d(x)+d(x) \frac{1}{d(x) + d(x)\frac{1}{d(x)  +...}}}$$
Notice also that $f'(x) > 0$, while second solution of quadratic equation for $g(x)$ takes negative values. Since $d(x) > 0$ for those $x$ for which $f'(x)$ is defined, recurring fraction for $g(x)$ takes positive values. Therefore:
$$f'(x) = \frac{1}{d(x)+d(x) \frac{1}{d(x) + d(x)\frac{1}{d(x)  +...}}}$$
$$f'(x) = \frac{1}{d(x) + \frac{1}{1+\frac{1}{d(x)+\frac{1}{1+...}}}}$$
