This question is provoked by an (in fact standard) solution to one of Baby Rudin’s exercises.
Suppose $f$ is defined in a neighborhood of $x$, and suppose $f^{\prime\prime}(x)$ >exists. Show that $$ \lim_{h \to 0} \frac{ f(x+h)+f(x-h)-2f(x)}{h^2} = >f^{\prime\prime}(x).$$ Hint: Use Theorem 5.13. [i.e. L'Hospital's rule]
What confuses me is the first step, using L'Hospital's rule:
\begin{align} \lim_{h \to 0} \frac{f(x+h) + f(x-h) -2f(x) }{h^2} &= \lim_{h \to 0} \frac{f^\prime(x+h) - f^\prime(x-h)}{2h} \\ & \ \ \ \mbox{ [ using L'Hospital's rule, } \\ & \ \ \ \ \ \ \mbox{ because $f(x+h)+f(x-h)-2f(x) \to 0$ and $h \to 0$ } \\ & \ \ \ \ \ \ \ \ \ \mbox{ as $h \to 0$ ]} \\ &= \lim_{h \to 0} \frac{ f^\prime(x+h) - f^\prime(x) + f^\prime(x) - f^\prime(x-h) }{2h} \end{align}
etc. But I believe the rule is about equating $\tfrac{f(x)}{g(x)}$ and $\tfrac{f^\prime(x)}{g^\prime(x)}$, i.e. ratio of functions resp. derivatives w.r.t the same variable, but were $g(x)=h^2$, we would have $g^\prime(x)=0$ for all $x \in \rm{Dom} \it f$, thus destroying the ratio. So are we permitted to differentiate w.r.t $x$ in the numerator and w.r.t $h$ in the denominator?
Any help is appreciated.