I found the following theorem, but I don't understand it and was unable to prove it. Is it true? Is there a proof for it?
Theorem: Let $f : R^d → R$ be such that $f$ is twice-differentiable and has continuous derivatives in an open ball $B$ around the point $x ∈ R^d$. Then for any small enough $∆x ∈ R^d$ such that $x + ∆x$ is also contained in the ball $B$, we have the following:
$$ f(x + \Delta x) = f(x) + \Delta x^T\nabla f|_x + \frac{1}{2}(\Delta x)^T (\nabla^2f|_w)(\Delta x) $$ Where $(\nabla^2f|_w)$ is the Hessian of $f$ evaluated at a point $w ∈ R^d$ that lies on the line connecting $x$ and $x + ∆x$
I understand that this is a second-order Taylor expansion of $f$ about $x$, and I understand why it is in this form.
But, I don't get is why the Hessian can be evaluated at the point $w$ rather than at $x$. If it is a Taylor expansion about $x$, shouldn't all derivatives be evaluated at $x$? Why is this expansion valid?
For reference, this is where I found the theorem: https://www.cs.princeton.edu/courses/archive/fall18/cos597G/lecnotes/lecture3.pdf On page 2.