# extension of smooth function

Assume we have a Riemannian manifold $M$ embedded isometrically in $\mathbb{R}^n$ (It may not be closed or open). Let $V(i)$ be a smooth orthonormal vector field on $M$ (which can be extended to a basis in $T(\mathbb{R}^n)$ at every point). Given that a smooth function $f$ on $M$ can be extended to $\mathbb{R}^n$ smoothly (say, the extended function is $g$), can it be extended in a way such that gradient of $g$ lies in $TM$ for all points in $M$?

-
Why do you need to know? Which examples of M do you have in mind? – Yemon Choi Jun 27 '13 at 7:02
For M, I am taking the space of positive definite matrices. I have the Laplacian(Laplace beltrami operator) on it but it cant be extended to all of R^k(k=n^2). I want to know if it can be extended atleast for functions on M which can be extended to R^k. – user35911 Jun 27 '13 at 7:13
A tubular neighborhood of $M$ in $\mathbb{R}^n$ can be identified with its normal bundle. Extend to the normal bundle by making $f$ constant on the fibres. Take a smooth cut-off some distance away from $M$. – Willie Wong Jun 27 '13 at 8:07
@willie wong I dont think this should work since by this argument, any smooth function can be extended to R^n. It will work only for nicer manifolds. – user35911 Jun 27 '13 at 8:35
What do you mean by "embedded"? As long as $M\subset \mathbb{R}^N$ is a closed set, by Whitney extension theorem any smooth $f$ on $M$ extends to a smooth $\tilde{f}$ on $\mathbb{R}^n$. The manifold structure is not even necessary. – Willie Wong Jun 27 '13 at 14:57

No: Take a spiral in $\mathbb R^2$ like $\mathbb R_{>0}\ni t\mapsto t.e^{it}$ with the induced metric, $g(x,y)=x$. You cannot change $g$ such that its gradient is tangent to the spiral: You have problems at 0.