Skip to main content

Section 4.4 Tangent Planes and Linear Approximations

References.

Topics.

Subsection 4.4.1 Tangent Lines Revisited

Recall that for a differentiable function of one variable \(y=f(x)\text{,}\) the tangent line at point \(x=a\) is
\begin{equation*} L(x) = f(a) + f'(a)(x-a). \end{equation*}
It approximates \(f(x)\) well in that the error is
\begin{equation} E(x) := f(x) - L(x) = \epsilon(x)(x-a) \text{ with } \epsilon(x) \to 0 \text{ as } x \to a,\tag{4.4.1} \end{equation}
so that
\begin{equation} f(x) = f(a) + f'(a)(x-a) + \epsilon(x)(x-a).\tag{4.4.2} \end{equation}
In terms of the increments \(\Delta x = x-a\) and \(\Delta y = f(x)-f(a)\text{,}\)
\begin{equation*} \Delta y = f'(a)\Delta x + \epsilon \Delta x. \end{equation*}

Subsection 4.4.2 Big-O and little-o notation

To discuss the smallness of the errors in such tangent approximations, some notation is useful.
To say that one function \(f(x)\) is not "greatly bigger" than another (positive) quantity \(g(x)\) in the limit \(x \to a\text{,}\) we use the big-O notation

Definition 4.4.1.

\(f(x) = O(g(x))\) near \(a\) if there is an upper bound \(M\) giving \(\ds \frac{|f(x)|}{g(x)} \le M\) for \(|x-a|\) small enough.
The same is said for vector-valued functions quantities (using vector norms), and for \(a=\infty\text{.}\)

Example 4.4.2.

For any quadratic \(q(x)\text{,}\) \(q(x)=O(x^2)\) at \(\infty\text{.}\)
To say that more, that function \(f(x)\) is far smaller than another quantity \(g(x)\) in the limit \(x \to a\text{,}\) we use the little-o notation:

Definition 4.4.3.

\(f(x) = o(g(x))\) as \(x \to a\) if
\begin{equation*} \lim_{x \to a} \frac{|f(x)|}{g(x)} = 0 \end{equation*}
(And again the same for vector-valued functions and for \(a=\infty\text{.}\))

Example 4.4.4.

  • For any quadratic \(q(x)\text{,}\) \(q(x)=o(x^3)\) at \(\infty\)
  • \(\ln x = o(1/x)\) as \(x \to 0^+\text{.}\)
With this notation the accuracy of the linear approximation can be stated as
\begin{equation} f(x) = f(a) + f'(a)(x-a) + o(|x-a|)\tag{4.4.3} \end{equation}
for \(x\) near \(a\text{.}\)
In fact Taylor’s Theorem says a bit more when \(f\) is twice differentiable:
\begin{equation*} f(x) = f(a) + f'(a)(x-a) + \frac{f''(\xi_x)}{2}(x-a)^2 \end{equation*}
for some \(\xi_x\) between \(x\) and \(a\text{;}\) (see Theorem 6.7 in Section 4.4 of OpenStax Calculus Volume 2.
 2 
openstax.org/books/calculus-volume-2/pages/6-3-taylor-and-maclaurin-series
)
Stated using big-O notation,
\begin{equation*} f(x) = f(a) + f'(a)(x-a) + O((x-a)^2) \end{equation*}

Subsection 4.4.3 Tangent Planes

For a function \(z=f(x,y)\) whose partial derivatives \(f_x\) and \(f_y\) exist a point \((a,b)\text{,}\) the best candidate for a function that approximates \(f\) well near \((a,b)\) is
\begin{equation} L(x,y) = f(a,b) + f_x(a,b)(x-a) + f_y(a,b)(y-b),\tag{4.4.4} \end{equation}
which in terms of the increments \(\Delta x = x-a\) and \(\Delta y = y-b\) is
\begin{equation*} L(a+\Delta x,b+\Delta y)= f(a,b) + f_x(a,b)\Delta x + f_y(a,b)\Delta y. \end{equation*}
This defines the tangent plane \(z=L(x,y)\) to \(f\) at \((a,b)\text{.}\)

Subsection 4.4.4 The Tangent Plane as a Linear Approximation to \(f\)

The tangent plane fits as closely as possible to \(f\text{,}\) at least when one look at the traces in the planes \(x=a\) and \(y=b\text{.}\)
The traces of \(L(x,y)\) are \(z=f(a,b)+ f_x(a,b)(x-a)\) in plane \(y=b\) and \(z=f(a,b)+ f_y(a,b)(y-b)\) in plane \(x=a\text{,}\) which are the tangent lines to the traces of \(f\) in those planes. Since these two tangent lines determine a unique plane, the plane given by \(L(x)\) is the only one that fits this well in these two planes.
However, as we shall see, this plane is not always a useful approximation is the sense seen in Equation (4.4.1): extra conditions of "continuity nearby" are needed.

Example 4.4.5. Cautionary Example: The Uncomfortable Saddle.

Consider the function
\begin{equation*} f(x,y) = \left\{ \begin{array}{cll} \ds\frac{xy}{x^2+y^2} \amp , \amp (x,y) \neq (0,0) \\ 0 \amp , \amp x=y=0 \end{array} \right. \end{equation*}
Both partial derivatives exist at the origin \((0,0)\) because \(f(x,0)=0\text{,}\) giving \(f_x(x,0)=0\) and similarly \(f_y(0,y)=0\text{.}\) Thus the tangent plane to \(f\) at \((0,0)\) is \(z=0\text{.}\) However, for nearby points with \(y=x\text{,}\) \(f(x,y)=f(x,x)=1/2\text{,}\) and with \(y=-x\text{,}\) \(f(x,-x)=-1/2\text{.}\) Thus the value of \(L(x,y)\) differs from that of \(f(x,y)\) by up to \(1/2\) for points arbitrarily close to \((0,0)\text{.}\) In fact this shows that \(f\) has no limit at the origin, and so is not continuous.

Notes on the Example.

A novelty here is that both partial derivatives exist, yet the function itself is not continuous. And those partial derivatives exist everywhere, not only at \((0,0)\text{:}\) for \((x,y) \neq (0,0)\text{,}\)
\begin{equation*} f_x(x,y) = \frac{y(x^2-y^2)}{(x^2+y^2)^2}, \quad f_y(x,y) = \frac{x(y^2-x^2)}{(x^2+y^2)^2}. \end{equation*}
The problem is that like \(f\) itself, neither of these is continuous at \((0,0)\text{.}\) For example, \(f_x(0,y) = 1/y\) for \(y \neq 0\text{.}\)

Subsection 4.4.5 Linear Approximations and Differentiable Functions

The approximation behavior that we want from the tangent plane is a 2D version of Equation (4.4.2) or (4.4.3), and this leads to the natural, geometrically based concept of being differentiable:

Definition 4.4.6. Differentiability.

A function \(f\) of two variables is differentiable at \((a,b)\) if
\begin{align*} f(a+\Delta x,b+\Delta y) \amp= f(a,b) + f_x(a,b)\Delta x + f_y(a,b)\Delta y \amp + \epsilon_1 \Delta x + \epsilon_2 \Delta y\\ \amp= L(a+\Delta x,b+\Delta y) \amp + \epsilon_1 \Delta x + \epsilon_2 \Delta y \end{align*}
with the functions \(\epsilon_i = \epsilon_i(\Delta x,\Delta y)\) both small near \((a,b)\) in that \(\epsilon_i(\Delta x,\Delta y) \to 0\) as \((\Delta x,\Delta y) \to (0,0)\text{.}\)
With the little-o notation, this can be phrased in the simpler form
\begin{equation} f(a+\Delta x, b+\Delta y) = f(a,b) + f_x(a,b)\Delta x + f_y(a,b)\Delta y + o \left( \sqrt{(x-a)^2 + (y-b)^2} \right)\tag{4.4.5} \end{equation}
or with vector notation \(\vec{a} = \vector{a,b}\text{,}\) \(\vec{x} = \vector{x,y}\text{,}\) \(\veclong{\Delta x} = \vector{\Delta x,\Delta y}\text{,}\)
\begin{equation} f(\vec{a} + \veclong{\Delta x}) = f(\vec{a}) + \vector{f_x(\vec{a}), f_y(\vec{a})} \cdot \veclong{\Delta x} + o ( \| \veclong{\Delta x} \| ),\tag{4.4.6} \end{equation}
mimicing Equation (4.4.3).
A function \(f\) is differentiable if it is differentiable at each point of its domain.

Subsection 4.4.6 A Criterion for Differentiability

Fortunately, there is a simple criterion for differentiability:
Clearly the continuity requirement excludes the above example.
On the other hand, all polynomial and rational functions are seen to be differentiable on their natural domains, including that example: its natural domain excludes \((0,0)\) due to division by zero in the formula.

Subsection 4.4.7 Differentials

By definition, a function \(z=f(x,y)\) that is differentiable at point \((a,b)\) is accurately approximated nearby by its tangent plane, and it can be convenient to approximate the change in the value of a function using the notation of differentials as in Section 4.2 of OpenStax Calculus, Volume 1
 6 
openstax.org/books/calculus-volume-1/pages/4-2-linear-approximations-and-differentials
or Section 3.11 of Calculus, Early Transcendentals by Stewart.
For the independent variables \(x\) and \(y\) of function \(z=f(x,y)\text{,}\) the differentials \(dx\) and \(dy\) are just any increments in the value of those variables from a starting point \((x,y)\text{.}\)
For the dependent variable \(z\text{,}\) the differential is the change in the value of the linear approximation as the independent variables change from \((x,y)\) to \((x+dx,y+dy)\text{:}\)
\begin{equation*} dz = f_x(x,y)dx + f_y(x,y)dy = \frac{\partial z}{\partial x}dx + \frac{\partial z}{\partial y}dy. \end{equation*}
This differs from the increment in the function value, \(\Delta z = f(x+dx,y+dy)-f(x,y)\text{,}\) by the amount
\begin{equation*} \Delta z - dz = \epsilon_1 dx + \epsilon_2 dy. \end{equation*}
This discrepancy is suitably small when the differentials \(dx\) and \(dy\) are small.

Subsubsection 4.4.7.1 Estimating Error with Differentials

One application of this is when the known values \(x\) and \(y\) of the independent variables represent experimental measurements or other numerical values with some margin of error, so that the exact values are \(x+dx\text{,}\) \(y+dy\) and all we know is upper limits on the magnitudes of \(dx\) and \(dy\text{,}\) say \(|dx| \leq E_x\text{,}\) \(|dy| \leq E_y\text{.}\)
Then we can get an upper limit on the differential \(dz\) and use it to estimate the error \(\Delta x\) in using \(f(x,y)\) as an approximation of \(f(x+dx,y+dy)\text{:}\)
\begin{equation*} |\Delta z| \approx |dz| \leq |f_x(x,y)| |dx| + |f_y(x,y)| |dy| \leq |f_x(x,y)| E_x + |f_y(x,y)| E_y. \end{equation*}

Subsection 4.4.8 Functions of Three Variables

All the ideas of this section extend in unsurprising ways to functions of three or more variables. In a nutshell, the linear approximation of \(w=f(x,y,x)\) is
\begin{equation*} f(x,y,z) \approx f(a,b,c)+f_x(a,b,c)(x-a)+f_y(a,b,c)(y-b)+f_z(a,b,c)(z-c), \end{equation*}
the corresponding differential formula is
\begin{equation*} dw = \frac{\partial w}{\partial x} dx +\frac{\partial w}{\partial y} dy +\frac{\partial w}{\partial z} dz, \end{equation*}
and a function is differentiable if
\begin{align*} f(a+\Delta x,b+\Delta y,c+\Delta z) \amp= \amp \amp f(a,b,c) + f_x(a,b,c)\Delta x + f_y(a,b,c)\Delta y + f_z(a,b,c)\Delta z\\ \amp \amp \amp+ \epsilon_1 \Delta x + \epsilon_2 \Delta y + \epsilon_3 \Delta z\\ \amp= \amp \amp L(a+\Delta x,b+\Delta y,c+\Delta z)\\ \amp \amp \amp+ \epsilon_1 \Delta x + \epsilon_2 \Delta y + \epsilon_3 \Delta z \end{align*}
with \(\epsilon_i(x,y,z) \to 0\) as \((x,y,z) \to 0\text{.}\)

Subsection 4.4.9 Functions of Many Variables

For higher dimensions, vector notation is convenient:

Definition 4.4.8.

For \(\vec{x} = \vec{a} + \Delta\vec{ x} = \vector{a_1,\dots,a_n} + \vector{\Delta x_1,\dots,\Delta x_n}\text{,}\) differentiability at \(\vec{a}\) means
\begin{equation*} f(\vec{x}) = f(\vec{a}) + \vector{f_1(\vec{a}),\dots,f_n(\vec{a})} \cdot \Delta\vec{x} + \vec{\epsilon} \cdot \Delta\vec{x}, \end{equation*}
\(\vec{\epsilon}(\vec{x}) \to 0\) as \(\vec{x} \to \vec{a}\text{.}\)

Study Guide.

Study Section 4.4 of Calculus Volume 3
 8 
openstax.org/books/calculus-volume-3/pages/4-4-tangent-planes-and-linear-approximations
; in particular
  • All the Definitions and Theorems.
  • All the Examples (and the Checkpoints following each).
  • The following exercises (in the case of a range, do at least one from the range): 163–164, 170–181, 191, 192, 196, 197.