I have the following question. Suppose $f$ is a function which satisfies for some $x$: 1. $f'$ exists in $(x-\epsilon,x+\epsilon)$ and 2. $f''(x)$ exists.
Show that $f''(x) = lim_{h \to 0} (\frac{f(x+h)-2f(x)+f(x-h)}{h^2})$.
I used L'hopital rule, and that means the limit is: $lim_{h \to 0} (\frac{f'(x+h)-f'(x-h)}{2h})=lim_{h \to 0}(\frac{f'(x+h)-f'(x)}{2h})+lim_{h \to 0} (\frac{f'(x)-f'(x-h)}{2h})=f''(x)/2 + f''(x)/2=f''(x)$
I am a little bit confused, because while taking the derivative of the numerator, I treated $x$ as a constant. My first intuition was to write $-2f'(x)$, and then I realized x is like a constant, and thus so is $f(x)$, so we need to write $(f(x))'=0$. That is why I'm a bit confused. Is this correct? Thanks!
To elaborate on a comment:
The premise of the theorem is that you are given a value of $x$ such that $f'$ exists in $(x - \varepsilon, x + \varepsilon)$ and $f''(x)$ exists for that value of $x$.
It is not given that $f$ has these properties for any other value of $x.$ Only for that one given value.
So if you started the proof with something like, "Let $x$ be a real number such that (various given facts about $f$)," from that point until the end of the proof $x$ can be assumed to have one fixed value that satisfies the conditions.
Furthermore, when you write out the formal definition of $f''(x)$ in terms of a limit of an expression involving $f',$ as you did, then while you are evaluating $f''(x)$ at any value of $x$ it is necessarily true that $x$ is the same value throughout the evaluation of $f''(x)$--namely, it's the point in the domain at which you're trying to find the derivative of $f'$. That's generally true when you attempt take the derivative of any function (in this case $f'$) at any point in its domain using this definition of the derivative. Even if you had not already fixed a value of $x,$ this would fix its value while you took a limit as $h\to 0$.
Hence it is correct to treat $x$ as a constant while taking your limit.
It's a good thing that you're thinking about things like this, however, because sometimes people assume something is constant during some step of a proof when it actually isn't constant in that context, and then they get wrong results.