Munkres' Question on Manifolds In Munkres' 'Analysis on Manifolds' on pg. 208 there's a question which reads:
QUESTION: Let $f:\mathbb R^{n+k}\to \mathbb R^n$ be of class $\mathscr C^r$.
Let $M$ be the set of all the points $\mathbf x$ such that $f(\mathbf x)=\mathbf 0$ and $N$ be the set of all the points $\mathbf x$ such that $$f_1(\mathbf x)=\cdots=f_{n-1}(\mathbf x)=0\text{ and } f_n(\mathbf x)\geq 0$$
Assume $M$ is non-empty.
1) Assume $\text{rank} ~ Df(\mathbf x)=n$ for all $\mathbf x\in M$ and show that $M$ is a $k$-manifold without boundary in $\mathbb R^{n+k}$.
2) Assume that the matrix $\displaystyle\frac{\partial(f_1,\ldots,f_{n-1})}{\partial \mathbf x}$ has rank $n-1$ for all $\mathbf x\in N$ and show that $N$ is a $(k+1)$-manifold with boundary in $\mathbb R^{n+k}$.

I am trying to show $(2)$ and I am not sure if the hypothesis of $(1)$ is required to do that.
I have approached this question using the constant rank theorem which dictates:
Constant Rank Theorem: Let $U$ be open in $\mathbb R^n$ and $\mathbf a$ be any point in $U$. Let $f:U\to \mathbb R^m$ be a function of class $\mathscr C^p$ such that $\text{rank } Df(\mathbf z) =r$ for all $\mathbf z\in U$. Then there exist open sets $U_1,U_2\subseteq U$ and $V\subseteq \mathbb R^m$ such that $\mathbf a\in U_1$ and $f(\mathbf a)\in V$, and $\mathscr C^p$-diffeomorphisms $\phi:U_1\to U_2$ and $\psi:V\to V$ such that $$(\psi\circ f\circ \phi^{-1})(\mathbf z)=(z_1,\ldots,z_r,0,\ldots,0)$$
for all $\mathbf z\in U_2$.

My approach to solve $(2)$ shall be clear by my solution of $(1)$:
Let $\mathbf a\in M$.
   We know that there exists $U$ open in $\mathbb R^{n+k}$ such that $\mathbf a\in U$ and $\text{rank }Df(\mathbf x)=n$ for all $\mathbf x\in U$.
   By the Constant Rank Theorem there exists open sets $U_1$ and $U_2$ in $\mathbb R^{n+k}$ and $V$ in $\mathbb R^n$ such that $\mathbf a\in U_1\subseteq U_1$ and $f(\mathbf a)=\mathbf \in V$, along with diffeomorphisms $\phi:U_1\to U_2$ and $\psi:V\to V$ satisfying
   $$(\psi\circ f\circ \phi^{-1})(\mathbf x) =(x_1,\ldots,x_n)$$
   for all $\mathbf x\in U_2$.
   Say $\psi(\mathbf 0)=(t_1,\ldots,t_n)$ and define $S=\{(t_1,\ldots,t_n,z_1,\ldots,z_k):z_i\in \mathbb R\}\cap U_2$.
Claim 1: $\phi^{-1}(S)=M\cap U_1$.
       Proof: Let $\mathbf q=(t_1,\ldots,t_n,z_1,\ldots,z_k)$ be in $S$.
            Then $\phi^{-1}(\mathbf q)$ obviously lies in $U_1$.
           We now show that $\phi^{-1}(\mathbf q)$ lies in $M$.
            Note that $(\psi\circ f\circ \phi^{-1})(\mathbf q)=(t_1,\ldots,t_n)$.
            This gives $(f\circ \phi^{-1})(\mathbf q)=\psi^{-1}(t_1,\ldots,t_n)=\mathbf 0$.
           This means that $f(\phi^{-1}(\mathbf q))=\mathbf 0$ and hence $\phi^{-1}(\mathbf q)$ is in $M$.
           For the reverse containment assume that $\mathbf q\in M\cap U_1$.
           Then $\mathbf q=\phi^{-1}(\mathbf s)$ for some $\mathbf s\in U_2$.
           Also, $f(\mathbf q)=0$ since $\mathbf q\in M$.            Thus $(f\circ\phi^{-1})(\mathbf s)=\mathbf 0$.
            Operating $\psi$ on both the sides we get $(\psi\circ f\circ \phi^{-1})(\mathbf s)=\psi(\mathbf 0)$.
            But the LHS of the last equation is $(s_1,\ldots,s_n)$ and the RHS is $(t_1,\ldots,t_n)$.
            Thus $s_i=t_i$ for $1\leq i\leq n$.
            Therefore $\mathbf s\in S$ and $\mathbf q\in\phi^{-1}(S)$.
            This settles the claim.
Now define $T=\{(z_1,\ldots,z_k)\in\mathbb R^k: (t_1,\ldots,t_n,z_1,\ldots,z_k)\in S\}$.
Claim 2: $T$ is open in $\mathbb R^k$.
        Proof: Define $g:\mathbb R^k\to \mathbb R^{n+k}$ as $$g(z_1,\ldots, z_k)=(t_1,\ldots,t_n,z_1,\ldots,z_k)$$
            Clearly $g$ is injective and continuous.
            We now show that $g^{-1}(U_2)=T$.
            Note that $g^{-1}(U_2)=g^{-1}(S)$.
            Let $\mathbf q\in S$.
            Say $\mathbf q=(t_1,\ldots,t_n,q_1,\ldots,q_k)$ and it is obvious that $g^{-1}(\mathbf q)\in T$.
            Now let $g^{-1}(\mathbf q)\in T$ for some $q\in \mathbb R^{n+k}$.
            We need to show that $\mathbf q\in U_2$.
            Say $g^{-1}(\mathbf q)=(b_1,\ldots,b_k)$.
            Then $\mathbf q=(t_1,\ldots,t_n,b_1,\ldots,b_k)\in S$ and thus $\mathbf q\in U_2$.
So we have shown that $T=g^{-1}(U_2)$.
            Now since $g$ is a continuous function and $U_2$ is open in $\mathbb R^{n+k}$, we infer that $T$ is open in $\mathbb R^k$ and the claim is settled.
    Now define a function $\alpha:T\to M\cap U_1$ as $$\alpha(\mathbf z)=\phi^{-1}\circ g(\mathbf z)$$
    It is a trivial matter to verify that $\alpha$ is a coordinate patch about the point $\mathbf a$ in $M$ and the proof is complete.

To solve $(2)$ what I did was define a function $g:\mathbb R^{n+k}\to \mathbb R^{n-1}$ as $$g(\mathbf x)=(f_1(\mathbf x),\ldots,f_{n-1}(\mathbf x))$$
Then $\text{rank }Dg(\mathbf x)=n-1$ for all $\mathbf x\in N$.
Let $\mathbf z_0\in N$.
I can show that there exists an open set $U\subseteq \mathbb R^{n+k}$ such that $\mathbf z_0\in U$ and $\text{rank }Dg(\mathbf z)=n-1$ for all $\mathbf z\in U$.
Thereby, using the conastant rank theorem I get $U_1, U_2,\psi$ and $\phi$ such that $(\psi\circ g\circ\phi^{-1})(\mathbf x)=(x_1,\ldots,x_{n-1})$
Can somebody guide me what to do from here?
 A: First, let us state the right hypotheses: one must assume that 
(a) the matrix $\frac{\partial(f_1,\dots,f_{n-1})}{\partial\bf x}$ has rank $n-1$ for ${\bf x}\in N$ with $f_n({\bf x})>0$, and
(b) the matrix $\frac{\partial(f_1,\dots,f_n)}{\partial\bf x}$ has rank $n$ for ${\bf x}\in N$ with $f_n({\bf x})=0$.
Then $N$ is a $(k+1)$-manifold with boundary $N\cap\{f_n=0\}$.
That something more that 2) (or (a)) is needed can be seen in the example
$$
f_1(x,y,z)=x,\quad f_2(x,y,z)=y^2-z^2.
$$
Here $n=2, k=1$, $N$ consists of two opposite closed quadrants in the plane $x=0$, cleary not a manifold with boundary, the problem being at the origin. In this example the rank of the jacobian matrix at the trouble point is $1=n-1$, not $2=n$.
For the proof, one starts by noting that $N_0=N\setminus\{f_n=0\}=N\cap\{f_n>0\}$ is an open set in $M=\{f_1=\dots=f_{n-1}=0\}$ ($f_n$ is continuous), and $M$ is a boundaryless manifold of dimension $n+k-(n-1)=k+1$ by (a) (the 1) you have proved). Open sets of manifolds are manifolds, hence we are done for $N_0$. Now we turn to $N_1=N\cap\{f_n=0\}$ to see this is the boundary of $N$. Since the argument is a simple modification  the one given for 1) I only sketch it. Fix a point $\bf p$ in $N_1$. By (b) the rank theorem gives new local coordinates $\bf x$ in an open nbhd $U$ of $\bf p$ in ${\mathbb R}^{n+k}$ whose first $n$ components are $f_1\equiv x_1,\dots,f_n\equiv x_n$ (again you proof of 1)). Then 
$$
N\cap U\equiv\{x_1=\cdots=x_{n-1}=0,x_n\ge0\},\quad 
N_1\cap U\equiv \{x_1=\cdots=x_{n-1}=0,x_n\ge0\}.
$$
In other words, locally at $\bf p$ our $N$ is a semi $(k+1)$-plane (cut by $x_n$ in $x_1=\cdots=x_{n-1}=0$) with boundary $N_1$. This is the local model of a manifold with boundary as wanted. 
