Why does this approximation of square roots using derivatives work this way? I came up with this way to estimate square roots by hand, but part of it doesn't seem to make sense.
Consider how $f(n) = \sqrt{n^2+\varepsilon} \approx n$ when $\varepsilon$ is small. Therefore, using the tangent line with slope $f'(n) = \frac{n}{\sqrt{n^2+\varepsilon}}$ to approximate $f$ gives
$f(n) \approx n +\varepsilon\cdot\frac{n}{\sqrt{n^2+\varepsilon}}$
However, if the original approximation is substituted in the denominator, this gives
$f(n) \approx n + \frac{\varepsilon n}{n} = n + \varepsilon$
Which obviously makes no sense. However, if the chain rule is skipped while taking the derivative, the approximation becomes
$f(n) \approx n + \frac{\varepsilon}{2n}$
Which is a good approximation. For example, when $\varepsilon = 1, \sqrt{n^2+1} \approx n+\frac{1}{2n},$ and when $\varepsilon = n, \sqrt{n^2+n} \approx n + \frac{1}{2}$
Why does this work only when the derivative is done incorrectly? I feel like I am missing something obvious, but I can't see why this works the way it does.

This seems like an improper application of the tangent line approximation. The usual approximation is
$$f(x+\varepsilon)\approx f(x)+\varepsilon f'(x)\tag{*}
$$
for $\varepsilon$ small. Your choice of $f$ doesn't match up with $(*)$. But using $f(x)=\sqrt x$ gives
$$
\sqrt{x+\varepsilon}=f(x+\varepsilon)\approx\sqrt x+{\varepsilon\over{2\sqrt x}}$$
and plugging $x=n^2$ yields
$$
\sqrt{n^2+\varepsilon}\approx n+\frac\varepsilon{2n},$$
the approximation you're seeking.
