# Question on equation of dimensions of tangent spaces in Proposition 5.38 of Lee's Smooth Manifolds

I am having trouble figuring out an equality on dimensions in the proof below from John Lee's Introduction to Smooth Manifolds.

In the proof, how do we get $$\dim T_p M - \dim T_{\Phi(p)}N=\dim T_p S$$? I can't figure out why this equality holds despite working on it for a long time now. I would greatly appreciate some help.

The intersection $$S\cap U$$ is a regular level set of $$\Phi$$, so the codimension of $$S\cap U$$ equals the dimension of $$N$$, by Corollary 5.13 (Submersion Level Set Theorem). In other words, $$\dim M - \dim S\cap U = \dim N$$. But $$\dim S\cap U = \dim S$$ because $$S\cap U$$ is open in $$S$$ (as $$S$$ is embedded in $$M$$ and $$U$$ is open in $$M$$), and so $$\dim T_pM - \dim T_{\Phi(p)}N = \dim M - \dim N = \dim S\cap U = \dim S = \dim T_pS.$$
• This is precisely what I figured out just now after going back to the earlier theorems. One question though, why is $\dim S \cap U = \dim S$ when $S\cap U$ is open in $S$? I got the equality using the equivalence of tangent spaces. Commented Nov 29, 2023 at 19:16
• It is a general fact: if $M$ is any manifold and $V\subseteq M$ is open, then $V$ is a manifold on its own right and $\dim V= \dim M$. Restricting the domains of charts for $M$, we get charts for $V$. Commented Nov 29, 2023 at 19:29