1. Subspace Minimization

Let $f(x)$ be a $\mathcal{C}^1$ function and let $M$ be a subspace of $\mathbb{R}^n$. Suppose $x^\ast \in M$ minimizes $f(x)$ on $M$. Show $\nabla f(x^\ast) \in M^\perp$.

My only idea is to take any $x \in M$ and try to show something with the function $\varphi(t) = f(x^\ast + tx)$, but I haven't been able to get anywhere with that. Any help is greatly appreciated!

2. Originally Posted by syme.gabriel
Let $f(x)$ be a $\mathcal{C}^1$ function and let $M$ be a subspace of $\mathbb{R}^n$. Suppose $x^\ast \in M$ minimizes $f(x)$ on $M$. Show $\nabla f(x^\ast) \in M^\perp$.

My only idea is to take any $x \in M$ and try to show something with the function $\varphi(t) = f(x^\ast + tx)$, but I haven't been able to get anywhere with that. Any help is greatly appreciated!
Suppose the gradient did not belong to the orthogonal complement of $M$.

Then the gradient at $\bold{x}^*$ has a component $\bold{u}$ in $M$, so moving form $\bold{x}^*$ to $\bold{x}^*+\delta \bold{\hat{u}}$
changes the value of the function to:

$f(\bold{x}^*)+ \delta [\nabla f(\bold{x}^*).\bold{\hat{u}}]=f(\bold{x}^*)+ \delta |\bold{u}|$,

so $\bold{x}^*$ will not be a mininmum in $M$.

RonL