Answer
We use Eq. (8) to compute $||\nabla u|{|^2}$ and then compute directly in rectangular coordinates. The two results agree.
Work Step by Step
In polar coordinates we have $u\left( {r,\theta } \right) = {r^2}{\cos ^2}\theta $. So, the partial derivatives are
${u_r} = 2r{\cos ^2}\theta $ ${\ \ }$ and ${\ \ }$ ${u_\theta } = - 2{r^2}\cos \theta \sin \theta $
Recall Eq. (8) from Exercise 21:
(8) ${\ \ \ }$ $||\nabla u|{|^2} = {u_r}^2 + \frac{1}{{{r^2}}}{u_\theta }^2$
1. Use Eq. (8) to compute $||\nabla u|{|^2}$
$||\nabla u|{|^2} = {\left( {2r{{\cos }^2}\theta } \right)^2} + \frac{1}{{{r^2}}}{\left( { - 2{r^2}\cos \theta \sin \theta } \right)^2}$
$ = 4{r^2}{\cos ^4}\theta + 4{r^2}{\cos ^2}\theta {\sin ^2}\theta $
$ = 4{r^2}{\cos ^2}\theta \left( {{{\cos }^2}\theta + {{\sin }^2}\theta } \right)$
Since ${\cos ^2}\theta + {\sin ^2}\theta = 1$, so
$||\nabla u|{|^2} = 4{r^2}{\cos ^2}\theta $
2. In rectangular coordinates we have $u\left( {x,y} \right) = {x^2}$.
So, the gradient of $u$ is $\nabla u = \left( {{u_x},{u_y}} \right) = \left( {2x,0} \right)$. And
$||\nabla u|{|^2} = \left( {2x,0} \right)\cdot\left( {2x,0} \right) = 4{x^2}$
Since $x = r\cos \theta $, so $||\nabla u|{|^2} = 4{r^2}{\cos ^2}\theta $.
Thus, the result agrees with the answer in part (1).