Directional Derivatives Examples 3

Directional Derivatives Examples 3

Recall from the Directional Derivatives page that for a two variable real-valued function $z = f(x, y)$, the directional derivative of $f$ at a point $(x, y) \in D(f)$ in the direction of the unit vector $\vec{u} = (a, b)$ is given by the formula:

(1)
\begin{align} \quad D_{\vec{u}} \: f(x, y) = \frac{\partial z}{\partial x} a + \frac{\partial z}{\partial y} b \end{align}

For a three variable real-valued function $w = f(x, y, z)$, the directional derivative of $f$ at a point $(x, y, z) \in D(f)$ in the direction of the unit vector $\vec{u} = (a, b, c)$ is given by the formula:

(2)
\begin{align} \quad D_{\vec{u}} \: f(x, y, z) = \frac{\partial w}{\partial x} a + \frac{\partial w}{\partial y} b + \frac{\partial w}{\partial z} c \end{align}

We will now look at some examples of calculating directional derivatives. More examples can be found on the Directional Derivatives Examples 1 and Directional Derivatives Examples 2 pages.

Example 1

Find the directional derivative of $w = f(x, y, z) = \sqrt{x + yz}$ at $(1, 3, 1)$ in the direction of $\vec{v} = (2, 3, 6)$.

We first note that $\vec{v}$ is not a unit vector, so $\| \vec{v} \| = \sqrt{2^2 + 3^2 + 6^2} = \sqrt{49} = 7$ and $\vec{u} = \left ( \frac{2}{7}, \frac{3}{7}, \frac{6}{7} \right )$ is a unit vector in the direction of $\vec{v}$.

We now want to compute the partial derivatives of $f$. We note that $\frac{\partial w}{\partial x} = \frac{1}{2\sqrt{x + yz}}$, $\frac{\partial w}{\partial y} = \frac{z}{2 \sqrt{x + yz}}$, and $\frac{\partial w}{\partial z} = \frac{y}{2\sqrt{x + yz}}$. Therefore we have that:

(3)
\begin{align} \quad \quad D_{\vec{u}} \: f(x, y, z) = \left ( \frac{1}{2\sqrt{x + yz}} \right ) \left ( \frac{2}{7} \right ) + \left ( \frac{z}{2 \sqrt{x + yz}} \right ) \left ( \frac{3}{7} \right ) + \left ( \frac{y}{2\sqrt{x + yz}} \right ) \left ( \frac{6}{7} \right ) \\ \quad \quad D_{\vec{u}} \: f(1, 3, 1) = \frac{2}{28} + \frac{3}{28} + \frac{18}{28} = \frac{23}{28} \end{align}

Example 2

Find the directional derivative of $w = f(x, y, z) = x \cos y \sin z$ at $\left (1, \pi, \frac{\pi}{4} \right )$ in the direction of $\vec{v} = (2, -1, 4)$.

Once again, $\vec{v}$ is not a unit vector, so $\| \vec{v} \| =\sqrt{(2)^2 + (-1)^2 + (4)^2} = \sqrt{21}$ and $\vec{u} = \left ( \frac{2}{\sqrt{21}}, \frac{-1}{\sqrt{21}}, \frac{4}{\sqrt{21}} \right )$ is a unit vector in the direction of $\vec{v}$.

We now want to compute the partial derivatives of $f$. We note that $\frac{\partial w}{\partial x} = \cos y \sin z$, $\frac{\partial w}{\partial y} = -x \sin y \sin z$, and $\frac{\partial w}{\partial z} = x \cos y \cos z$. Therefore:

(4)
\begin{align} \quad \quad D_{\vec{u}} \: f(x, y, z) = (\cos y \sin z) \left ( \frac{2}{\sqrt{21}} \right ) + (-x \sin y \sin z) \left ( \frac{-1}{\sqrt{21}} \right ) + (x \cos y \cos z) \left ( \frac{4}{\sqrt{21}} \right ) \\ \quad \quad D_{\vec{u}} \: f \left (1, \pi, \frac{\pi}{4} \right ) = -\frac{\sqrt{2}}{\sqrt{21}} + 0 - \frac{2\sqrt{2}}{\sqrt{21}} = \frac{-3\sqrt{2}}{\sqrt{21}} \end{align}

Example 3

Find the directional derivative of $w = f(x, y, z) = \ln(1 + x^2 + y^2 + z^2)$ at $(1, -1, 1)$ in the direction of $\vec{v} = (2, -2, -3)$.

We note that $\vec{v}$ is not a unit vector, so $\| \vec{v} \| = \sqrt{(2)^2 + (-2)^2 + (-3)^2} = \sqrt{17}$ and $\vec{u} \left ( \frac{2}{\sqrt{17}}, \frac{-2}{\sqrt{17}}, \frac{-3}{\sqrt{17}} \right )$ is a unit vector in the direction of $\vec{v}$.

We now want to compute the partial derivatives of $f$. We note that $\frac{\partial w}{\partial x} = \frac{2x}{1 + x^2 + y^2 + z^2}$, $\frac{\partial w}{\partial y} = \frac{2y}{1 + x^2 + y^2 + z^2}$, and $\frac{\partial w}{\partial z} = \frac{2z}{1 + x^2 + y^2 + z^2}$. Therefore:

(5)
\begin{align} \quad \quad D_{\vec{u}} \: f(x, y, z) = \left ( \frac{2x}{1 + x^2 + y^2 + z^2} \right ) \left ( \frac{2}{\sqrt{21}} \right) + \left ( \frac{2y}{1 + x^2 + y^2 + z^2} \right ) \left ( \frac{-2}{\sqrt{21}} \right ) + \left ( \frac{2z}{1 + x^2 + y^2 + z^2} \right ) \left ( \frac{-3}{\sqrt{21}} \right ) \\ \quad \quad D_{\vec{u}} \: f(1, -1, 1) = \frac{1}{\sqrt{21}} + \frac{1}{\sqrt{21}} + \frac{-3/2}{\sqrt{21}} = \frac{1}{2\sqrt{21}} \end{align}
Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License