If $g\in C^2(\mathbb{R}^m)$ such that $g'(b)\in GL(\mathbb{R}^m) \Longrightarrow f(y)=||g(y)-g(b)||^2$ is convex Any idea about this problem:
Let $V\subset \mathbb{R}^m$ (open set) and $g:V \longrightarrow \mathbb{R}^m,g\in C^2(\mathbb{R}^m)$ such that $g'(b)\in GL(\mathbb{R}^m),b\in V$. 
Prove that there is $B(b,r)\subset V$ such that $f:B(b,r) \longrightarrow \mathbb{R}$ defined by $f(y)=||g(y)-g(b)||^2$ is convex.
Any hints would be appreciated. 

Since $g$ is $C^2$, $f$ is also $C^2$, so the Hessian matrix of $f$, denoted by $H(f)$, is well defined and continuous(which means all its entries are continuous functions), where $H(f)=\big(\dfrac{\partial^2f}{\partial y_i\partial y_j}\big)$. A sufficient condition for $f$ being convex on some open set $U$ is that $H(f)$ is always positive definite on $U$. This fact can be easily shown by using the following Talyor expansion of $f$
$$f(y)=f(p)+f'(p)(y-p)+\dfrac{1}{2}(y-p)^tH(f)(p)(y-p)+o(\|y-p\|^2),$$
where $v^t$ denotes the transpose of $v$.
Since $H(f)$ is continuous, it is positive definite at some point implies that it is positive definite in some neighborhood of this point, because a symmetric matrix is positive definite is equivalent to all its leading principal minors are positive. Therefore, it suffices to show that $H(f)$ is positive definite at $b$. Since
$$g(y)=g(b)+g'(b)(y-b)+o(\|y-b\|),$$
$$f(y)=(y-b)^tg'(b)^tg'(b)(y-b)+o(\|y-b\|^2),$$
i.e. $H(f)(b)=2\,g'(b)^tg'(b)$. Because $g'(b)\in\mathrm{GL}(\mathbb{R}^m)$, $H(f)(b)$ is positive definite. 
