Answer
(a) $f$ is constant along the segment $\overline {PR} $, that is, $\frac{{\partial f}}{{\partial x}}{|_{y = b}} = 0$.
$f$ is constant along the segment $\overline {RQ} $, that is, $\frac{{\partial f}}{{\partial y}}{|_{x = c}} = 0$.
(b) Since $P$ and $Q$ are arbitrary, we conclude that $f\left( P \right) = f\left( Q \right)$ for any two points $P,Q \in {\cal D}$. This implies that $f$ is constant in ${\cal D}$.
Work Step by Step
We have the points $P = \left( {a,b} \right)$, $Q = \left( {c,d} \right)$, and $R = \left( {c,b} \right)$ as is shown in Figure 18.
Suppose that $\nabla f\left( {x,y} \right) = {\bf{0}}$. Then, we have
$\nabla f\left( {x,y} \right) = \left( {\frac{{\partial f}}{{\partial x}},\frac{{\partial f}}{{\partial y}}} \right) = \left( {0,0} \right)$
So, $\frac{{\partial f}}{{\partial x}} = 0$ and $\frac{{\partial f}}{{\partial y}} = 0$.
(a) Since $\frac{{\partial f}}{{\partial x}} = 0$, this implies that $f$ is constant along the segment $\overline {PR} $, that is, $\frac{{df}}{{dx}}{|_{y = b}} = 0$.
Similarly, since $\frac{{\partial f}}{{\partial y}} = 0$, this implies that $f$ is constant along the segment $\overline {RQ} $, that is, $\frac{{df}}{{dy}}{|_{x = c}} = 0$.
(b) From the result in part (a), we get $\frac{{df}}{{dx}}{|_{y = b}} = 0$. This implies that $f\left( P \right) = f\left( R \right)$.
Similarly, from part (a), we get $\frac{{df}}{{dy}}{|_{x = c}} = 0$. This implies that $f\left( R \right) = f\left( Q \right)$.
Therefore, $f\left( P \right) = f\left( Q \right)$.
Since $P$ and $Q$ are arbitrary, we conclude that $f\left( P \right) = f\left( Q \right)$ for any two points $P,Q \in {\cal D}$. This implies that $f$ is constant in ${\cal D}$.
Hence, if $\nabla f\left( {x,y} \right) = {\bf{0}}$ for all $\left( {x,y} \right)$ in ${\cal D}$, then $f$ is constant.