Consider the function \(f(x,y) = 1 + x^2 + y^2\text{,}\) the point \(P_0(1,1)\text{,}\) and the unit vector \(\mathbf u = \dfrac{1}{\sqrt 2}\mathbf i + \dfrac{1}{\sqrt 2}\mathbf j\text{.}\) Use the definition of directional derivative to compute \(\left(D_{\mathbf u} f\right)_{P_0}\text{.}\)
Solution.
We substitute \(x_0 = y_0 = 1\) and \(u_1 = u_2 = \dfrac{1}{\sqrt 2}\) in the definition:
\begin{align*}
\left(\frac{df}{ds}\right)_{\mathbf u,P_0}
\amp= \lim_{s\to 0}\frac{f(x_0 + su_1,\, y_0 + su_2) - f(x_0,y_0)}{s}\\
\amp= \lim_{s\to 0}
\frac{f\!\left(1 + \tfrac{s}{\sqrt 2},\, 1 + \tfrac{s}{\sqrt 2}\right) - f(1,1)}{s}\\
\amp= \lim_{s\to 0}
\frac{1 + \left(1 + \tfrac{s}{\sqrt 2}\right)^2
+ \left(1 + \tfrac{s}{\sqrt 2}\right)^2 - 3}{s}\\
\amp= \lim_{s\to 0}\frac{\tfrac{4s}{\sqrt 2} + s^2}{s} = \lim_{s\to 0}\left(\tfrac{4}{\sqrt 2} + s\right)\\
\amp= 2\sqrt 2.
\end{align*}
The computation has a useful geometric picture, illustrated in the interactive 3D figure below. Along the ray through \(P_0(1,1)\) in the direction \(\mathbf u\text{,}\) the values of \(f\) are the single-variable function
\begin{align}
g(s) \amp= f\!\left(1 + \tfrac{s}{\sqrt 2},\, 1 + \tfrac{s}{\sqrt 2}\right)\notag\\
\amp= 3 + 2\sqrt 2\, s + s^2,\tag{7.2}
\end{align}
and the difference quotient in the limit above is the slope of the secant line of \(g\) through \(s = 0\) and \(s\text{.}\) As \(s \to 0\) the secant lines approach the tangent line at \(s = 0\text{,}\) whose slope is \(g'(0) = 2\sqrt 2 = \left(D_{\mathbf u} f\right)_{P_0}\text{.}\)
Instructions.
The surface \(z = 1 + x^2 + y^2\) is cut by the vertical plane through \(P_0(1,1)\) in the direction \(\mathbf u\text{.}\) Drag the slider to change \(s\text{:}\) the point \(P\) slides along \(\mathbf u\) in the \(xy\)-plane, and the secant line through the surface points \((1,\,1,\,f(P_0))\) and \((1+su_1,\,1+su_2,\,f(P))\) rotates toward the tangent line. Press βs \(\to\) 0β to animate the limit; the readout shows the secant slope \(2\sqrt 2 + s\) approaching the directional derivative \(2\sqrt 2\text{.}\) Drag the figure to view it from a different angle, or press the βRotateβ button.
