Gradient in a rotated reference frame I'm sure this is an embarrassingly simple question, but what is the gradient in a different reference frame whose axes are at an angle $\theta$ to the original frame? i.e. what is
$\nabla=\left(\partial_x \hat{x} + \partial_y \hat{y} \right)$
in a reference frame rotated by $\theta$, expressed in terms of the original $\partial_x$ and $\partial_y$? I can't seem to find anything on the web about it.
 A: Let $(x,y)$ be the coordinates in the original frame and let $(\hat{x},\hat{y})$ be the coordinates in the new (rotated by an angle $\theta$) frame. The rotation $\boldsymbol{R}(\theta)$ is given by
$$
\boldsymbol{R}(\theta) = \left(\begin{array}{cc}
\cos\,\theta & -\sin\,\theta\\
\sin\,\theta & \cos\,\theta
\end{array}\right),
$$
so that 
$$
\left(\begin{array}{c}
x\\
y
\end{array}\right) = \left(\begin{array}{cc}
\cos\,\theta & \sin\,\theta\\
-\sin\,\theta & \cos\,\theta
\end{array}\right)\left(\begin{array}{c}
\hat{x}\\
\hat{y}
\end{array}\right) = \left(\begin{array}{c}
\hat{x}\cos\,\theta+\hat{y}\sin\,\theta\\
-\hat{x}\sin\,\theta+\hat{y}\cos\,\theta
\end{array}\right),
$$
where the fact that $(\boldsymbol{R}(\theta))^{-1} = (\boldsymbol{R}(\theta))^{T}$ was used. Therefore for a differentiable function $f$, using the chain rule,
$$
\hat{\nabla}f(\hat{x},\hat{y}) = \left(\begin{array}{c}
\frac{\partial f(\hat{x},\hat{y})}{\partial\hat{x}}\\
\frac{\partial f(\hat{x},\hat{y})}{\partial\hat{y}}
\end{array}\right) = \left(\begin{array}{c}
\frac{\partial f(x,y)}{\partial x}\frac{\partial x}{\partial \hat{x}}+\frac{\partial f(x,y)}{\partial y}\frac{\partial y}{\partial \hat{x}}\\
\frac{\partial f(x,y)}{\partial x}\frac{\partial x}{\partial \hat{y}}+\frac{\partial f(x,y)}{\partial y}\frac{\partial y}{\partial \hat{y}}
\end{array}\right) = \left(\begin{array}{cc}
\cos\,\theta & -\sin\,\theta\\
\sin\,\theta & \cos\,\theta
\end{array}\right)\left(\begin{array}{c}
\frac{\partial f(x,y)}{\partial x}\\
\frac{\partial f(x,y)}{\partial y}
\end{array}\right).
$$
The above shows explicitly that 
$$
\hat{\nabla}f(\hat{x},\hat{y}) = \boldsymbol{R}(\theta)\nabla f(x,y).
$$
