I have a continously differentiable function $f:\mathbb{R}^{n}\rightarrow\mathbb{R}$ which I am trying to prove is globally convex. Computing the Hessian directly is very difficult as it is a somewhat complicated function of a matrix, other methods of proving global convexity have proved inconclusive. So far I am only able to show that it is 'locally convex' in the following sense:
For any $x\in\mathbb{R}^{n}$ there exists an $\varepsilon_{x}>0$ such that for $y\in\mathbb{R}^{n}$ where $\| y-x\|\leq\varepsilon_x$ it holds that $$f(y)\geq f(x)+\nabla f(x)^{T}(y-x). $$
My question is a rather basic one, can we establish that local convexity of this kind implies global convexity? Are any extra conditions needed?
My intuition suggests that a continuously differentiable function on a convex set which is locally convex everywhere should be globally convex, but I have trouble constructing the argument. Any help is greatly appreciated!