14.5.5.
Calculate the gradient of \(f(x,y) = \cos\lp x^2 + y \rp\text{.}\)
Solution.
To find the gradient \(\nabla f(x,y)\text{,}\) we compute the partial derivatives with respect to \(x\) and \(y\) using the Chain Rule.
Partial derivative with respect to \(x\text{:}\)
\begin{equation*}
f_x(x,y) = \frac{\partial}{\partial x} \cos(x^2 + y) = -\sin(x^2 + y) \cdot \frac{\partial}{\partial x}(x^2 + y) = -2x\sin(x^2 + y)
\end{equation*}
Partial derivative with respect to \(y\text{:}\)
\begin{equation*}
f_y(x,y) = \frac{\partial}{\partial y} \cos(x^2 + y) = -\sin(x^2 + y) \cdot \frac{\partial}{\partial y}(x^2 + y) = -\sin(x^2 + y)
\end{equation*}
Thus, the gradient vector is:
\begin{equation*}
\nabla f(x,y) = \la -2x\sin(x^2 + y), -\sin(x^2 + y) \ra
\end{equation*}
