We studied differentials in Section 4.3, where Definition 4.3.1 states that if $y=f(x)$ and $f$ is differentiable, then $\mathrm{d}y={f}^{\prime}(x)\mathrm{d}x$. One important use of this differential is in Integration by Substitution. Another important application is approximation. Let $\mathrm{\Delta}x=\mathrm{d}x$ represent a change in $x$. When $\mathrm{d}x$ is small, $\mathrm{d}y\approx \mathrm{\Delta}y$, the change in $y$ resulting from the change in $x$. Fundamental in this understanding is this: as $\mathrm{d}x$ gets small, the difference between $\mathrm{\Delta}y$ and $\mathrm{d}y$ goes to 0. Another way of stating this: as $\mathrm{d}x$ goes to 0, the error in approximating $\mathrm{\Delta}y$ with $\mathrm{d}y$ goes to 0.
We extend this idea to functions of two variables. Let $z=f(x,y)$, and let $\mathrm{\Delta}x=\mathrm{d}x$ and $\mathrm{\Delta}y=\mathrm{d}y$ represent changes in $x$ and $y$, respectively. Let $\mathrm{\Delta}z=f(x+\mathrm{d}x,y+\mathrm{d}y)-f(x,y)$ be the change in $z$ over the change in $x$ and $y$. Recalling that ${f}_{x}$ and ${f}_{y}$ give the instantaneous rates of $z$-change in the $x$- and $y$-directions, respectively, we can approximate $\mathrm{\Delta}z$ with $\mathrm{d}z={f}_{x}\mathrm{d}x+{f}_{y}\mathrm{d}y$; in words, the total change in $z$ is approximately the change caused by changing $x$ plus the change caused by changing $y$. In a moment we give an indication of whether or not this approximation is any good. First we give a name to $\mathrm{d}z$.
Let $z=f(x,y)$ be continuous on an open set $S$. Let $\mathrm{d}x$ and $\mathrm{d}y$ represent changes in $x$ and $y$, respectively. Where the partial derivatives ${f}_{x}$ and ${f}_{y}$ exist, the total differential of $z$ is
$$\mathrm{d}z={f}_{x}(x,y)\mathrm{d}x+{f}_{y}(x,y)\mathrm{d}y.$$ |
Let $z={x}^{4}{e}^{3y}$. Find $\mathrm{d}z$.
SolutionWe compute the partial derivatives: ${f}_{x}=4{x}^{3}{e}^{3y}$ and ${f}_{y}=3{x}^{4}{e}^{3y}$. Following Definition 13.4.1, we have
$$\mathrm{d}z=4{x}^{3}{e}^{3y}\mathrm{d}x+3{x}^{4}{e}^{3y}\mathrm{d}y.$$ |
We can approximate $\mathrm{\Delta}z$ with $\mathrm{d}z$, but as with all approximations, there is error involved. A good approximation is one in which the error is small. At a given point $({x}_{0},{y}_{0})$, let ${E}_{1}$ and ${E}_{2}$ be functions of $\mathrm{d}x$ and $\mathrm{d}y$ such that ${E}_{1}\mathrm{d}x+{E}_{2}\mathrm{d}y$ describes this error. Then
$\mathrm{\Delta}z$ | $=\mathrm{d}z+{E}_{1}\mathrm{d}x+{E}_{2}\mathrm{d}y$ | ||
$={f}_{x}({x}_{0},{y}_{0})\mathrm{d}x+{f}_{y}({x}_{0},{y}_{0})\mathrm{d}y+{E}_{1}\mathrm{d}x+{E}_{2}\mathrm{d}y.$ |
If the approximation of $\mathrm{\Delta}z$ by $\mathrm{d}z$ is good, then as $\mathrm{d}x$ and $\mathrm{d}y$ get small, so does ${E}_{1}\mathrm{d}x+{E}_{2}\mathrm{d}y$. The approximation of $\mathrm{\Delta}z$ by $\mathrm{d}z$ is even better if, as $\mathrm{d}x$ and $\mathrm{d}y$ go to 0, so do ${E}_{1}$ and ${E}_{2}$. This leads us to our definition of differentiability.
Let $z=f(x,y)$ be defined on an open set $S$ containing $({x}_{0},{y}_{0})$ where ${f}_{x}({x}_{0},{y}_{0})$ and ${f}_{y}({x}_{0},{y}_{0})$ exist. Let $\mathrm{d}z$ be the total differential of $z$ at $({x}_{0},{y}_{0})$, let $\mathrm{\Delta}z=f({x}_{0}+\mathrm{d}x,{y}_{0}+\mathrm{d}y)-f({x}_{0},{y}_{0})$, and let ${E}_{1}$ and ${E}_{2}$ be functions of $\mathrm{d}x$ and $\mathrm{d}y$ such that
$$\mathrm{\Delta}z=\mathrm{d}z+{E}_{1}\mathrm{d}x+{E}_{2}\mathrm{d}y.$$ |
$f$ is differentiable at $\mathrm{(}{x}_{\mathrm{0}}\mathrm{,}{y}_{\mathrm{0}}\mathrm{)}$ if
$$\underset{(\mathrm{d}x,\mathrm{d}y)\to (0,0)}{lim}{E}_{1}=0\mathit{\hspace{1em}\hspace{1em}}\text{and}\mathit{\hspace{1em}\hspace{1em}}\underset{(\mathrm{d}x,\mathrm{d}y)\to (0,0)}{lim}{E}_{2}=0.$$ |
$f$ is differentiable on $S$ if $f$ is differentiable at every point in $S$. If $f$ is differentiable on ${\mathbb{R}}^{2}$, we say that $f$ is differentiable everywhere.
Show $f(x,y)=xy+3{y}^{2}$ is differentiable using Definition 13.4.2.
SolutionWe begin by finding $f(x+\mathrm{d}x,y+\mathrm{d}y)$, $\mathrm{\Delta}z$, ${f}_{x}$ and ${f}_{y}$.
$f(x+\mathrm{d}x,y+\mathrm{d}y)$ | $=(x+\mathrm{d}x)(y+\mathrm{d}y)+3{(y+\mathrm{d}y)}^{2}$ | ||
$=xy+x\mathrm{d}y+y\mathrm{d}x+\mathrm{d}x\mathrm{d}y+3{y}^{2}+6y\mathrm{d}y+3\mathrm{d}{y}^{2}.$ |
$\mathrm{\Delta}z=f(x+\mathrm{d}x,y+\mathrm{d}y)-f(x,y)$, so
$$\mathrm{\Delta}z=x\mathrm{d}y+y\mathrm{d}x+\mathrm{d}x\mathrm{d}y+6y\mathrm{d}y+3\mathrm{d}{y}^{2}.$$ |
It is straightforward to compute ${f}_{x}=y$ and ${f}_{y}=x+6y$. Consider once more $\mathrm{\Delta}z$:
$\mathrm{\Delta}z$ | $=x\mathrm{d}y+y\mathrm{d}x+\mathrm{d}x\mathrm{d}y+6y\mathrm{d}y+3\mathrm{d}{y}^{2}\mathit{\hspace{1em}\hspace{1em}}\text{(now reorder)}$ | ||
$=y\mathrm{d}x+x\mathrm{d}y+6y\mathrm{d}y+\mathrm{d}x\mathrm{d}y+3\mathrm{d}{y}^{2}$ | |||
$=\underset{{f}_{x}}{\underset{\u23df}{(y)}}\mathrm{d}x+\underset{{f}_{y}}{\underset{\u23df}{(x+6y)}}\mathrm{d}y+\underset{{E}_{1}}{\underset{\u23df}{(\mathrm{d}y)}}\mathrm{d}x+\underset{{E}_{2}}{\underset{\u23df}{(3\mathrm{d}y)}}\mathrm{d}y$ | |||
$={f}_{x}\mathrm{d}x+{f}_{y}\mathrm{d}y+{E}_{1}\mathrm{d}x+{E}_{2}\mathrm{d}y.$ |
With ${E}_{1}=\mathrm{d}y$ and ${E}_{2}=3\mathrm{d}y$, it is clear that as $\mathrm{d}x$ and $\mathrm{d}y$ go to 0, ${E}_{1}$ and ${E}_{2}$ also go to 0. Since this did not depend on a specific point $({x}_{0},{y}_{0})$, we can say that $f(x,y)$ is differentiable for all pairs $(x,y)$ in ${\mathbb{R}}^{2}$, or, equivalently, that $f$ is differentiable everywhere.
Our intuitive understanding of differentiability of functions $y=f(x)$ of one variable was that the graph of $f$ was “smooth.” A similar intuitive understanding of functions $z=f(x,y)$ of two variables is that the surface defined by $f$ is also “smooth,” not containing cusps, edges, breaks, etc. The following theorem provides a more tangible way of determining whether a great number of functions are differentiable or not.
Let $z=f(x,y)$ be defined on an open set $S$. If ${f}_{x}$ and ${f}_{y}$ are both continuous on $S$, then $f$ is differentiable on $S$.
The theorems assure us that essentially all functions that we see in the course of our studies here are differentiable (and hence continuous) on their natural domains. There is a difference between Definition 13.4.2 and Theorem 13.4.1, though: it is possible for a function $f$ to be differentiable yet ${f}_{x}$ or ${f}_{y}$ is not continuous. Such strange behavior of functions is a source of delight for many mathematicians. When this happens, we need to use other methods to determine whether or not $f$ is differentiable at that point.
By the definition, when $f$ is differentiable $\mathrm{d}z$ is a good approximation for $\mathrm{\Delta}z$ when $\mathrm{d}x$ and $\mathrm{d}y$ are small. We give some simple examples of how this is used here.
Let $f(x,y)=\sqrt{x}\mathrm{sin}y$. Approximate $f(4.1,0.2)$.
SolutionWe can approximate $f(4.1,0.2)$ using $f(4,0)=0$. Without calculus, this is the best approximation we could reasonably come up with. The total differential gives us a way of adjusting this initial approximation to hopefully get a more accurate answer.
We let $\mathrm{\Delta}z=f(4.1,0.2)-f(4,0)$. The total differential $\mathrm{d}z$ is approximately equal to $\mathrm{\Delta}z$, so
$$f(4.1,0.2)-f(4,0)\approx \mathrm{d}z\mathit{\hspace{1em}}\Rightarrow \mathit{\hspace{1em}}f(4.1,0.2)\approx \mathrm{d}z+f(4,0).$$ | (13.4.1) |
To find $\mathrm{d}z$, we need ${f}_{x}$ and ${f}_{y}$.
${f}_{x}(x,y)$ | $={\displaystyle \frac{\mathrm{sin}y}{2\sqrt{x}}}\mathit{\hspace{1em}}\Rightarrow $ | ${f}_{x}(4,0)$ | $={\displaystyle \frac{\mathrm{sin}0}{2\sqrt{4}}}=0$ | ||
${f}_{y}(x,y)$ | $=\sqrt{x}\mathrm{cos}y\mathit{\hspace{1em}}\Rightarrow $ | ${f}_{y}(4,0)$ | $=\sqrt{4}\mathrm{cos}0=2$ |
Approximating $4.1$ with 4 gives $\mathrm{d}x=0.1$; approximating $0.2$ with $0$ gives $\mathrm{d}y=0.2$. Thus
$$\mathrm{d}z(4,0)={f}_{x}(4,0)(0.1)+{f}_{y}(4,0)(0.2)=0(0.1)+2(0.2)=0.4.$$ |
Returning to Equation (13.4.1), we have
$$f(4.1,0.2)\approx 0.4+0=.4.$$ |
We, of course, can compute the actual value of $f(4.1,0.2)$ with a calculator; to 5 places after the decimal, this is $0.40228$. Obviously our approximation is quite good.
The point of the previous example was not to develop an approximation method for known functions. After all, we can very easily compute $f(4.1,0.2)$ using readily available technology. Rather, it serves to illustrate how well this method of approximation works, and to reinforce the following concept:
“New position = old position $+$ amount of change,” so
“New position $\approx $ old position + approximate amount of change.”
In the previous example, we could easily compute $f(4,0)$ and could approximate the amount of $z$-change when computing $f(4.1,0.2)$, letting us approximate the new $z$-value.
It may be surprising to learn that it is not uncommon to know the values of $f$, ${f}_{x}$ and ${f}_{y}$ at a particular point without actually knowing the function $f$. The total differential gives a good method of approximating $f$ at nearby points.
Given that $f(2,-3)=6$, ${f}_{x}(2,-3)=1.3$ and ${f}_{y}(2,-3)=-0.6$, approximate $f(2.1,-3.03)$.
SolutionThe total differential approximates how much $f$ changes from the point $(2,-3)$ to the point $(2.1,-3.03)$. With $\mathrm{d}x=0.1$ and $\mathrm{d}y=-0.03$, we have
$\mathrm{d}z$ | $={f}_{x}(2,-3)\mathrm{d}x+{f}_{y}(2,-3)\mathrm{d}y$ | ||
$=1.3(0.1)+(-0.6)(-0.03)$ | |||
$=0.148.$ |
The change in $z$ is approximately $0.148$, so we approximate $f(2.1,-3.03)\approx 6.148$.
The total differential gives an approximation of the change in $z$ given small changes in $x$ and $y$. We can use this to approximate error propagation; that is, if the input is a little off from what it should be, how far from correct will the output be? We demonstrate this in an example.
A cylindrical steel storage tank is to be built that is 10ft tall and 4ft across in diameter. It is known that the steel will expand/contract with temperature changes; is the overall volume of the tank more sensitive to changes in the diameter or in the height of the tank?
SolutionA cylindrical solid with height $h$ and radius $r$ has volume $V=\pi {r}^{2}h$. We can view $V$ as a function of two variables, $r$ and $h$. We can compute partial derivatives of $V$:
$$\frac{\partial V}{\partial r}={V}_{r}(r,h)=2\pi rh\mathit{\hspace{1em}\hspace{1em}}\text{and}\mathit{\hspace{1em}\hspace{1em}}\frac{\partial V}{\partial h}={V}_{h}(r,h)=\pi {r}^{2}.$$ |
The total differential is $\mathrm{d}V=(2\pi rh)\mathrm{d}r+(\pi {r}^{2})\mathrm{d}h.$ When $h=10$ and $r=2$, we have $\mathrm{d}V=40\pi \mathrm{d}r+4\pi \mathrm{d}h$. Note that the coefficient of $\mathrm{d}r$ is $40\pi $; the coefficient of $\mathrm{d}h$ is a tenth of that. A small change in radius will be multiplied by $40\pi $, whereas a small change in height will be multiplied by $4\pi $. Thus the volume of the tank is more sensitive to changes in radius than in height.
The previous example showed that the volume of a particular tank was more sensitive to changes in radius than in height. Keep in mind that this analysis only applies to a tank of those dimensions. A tank with a height of 1ft and radius of 5ft would be more sensitive to changes in height than in radius.
One could make a chart of small changes in radius and height and find exact changes in volume given specific changes. While this provides exact numbers, it does not give as much insight as the error analysis using the total differential.
The definition of differentiability for functions of three variables is very similar to that of functions of two variables. We again start with the total differential.
Let $w=f(x,y,z)$ be continuous on an open set $S$. Let $\mathrm{d}x$, $\mathrm{d}y$ and $\mathrm{d}z$ represent changes in $x$, $y$ and $z$, respectively. Where the partial derivatives ${f}_{x}$, ${f}_{y}$ and ${f}_{z}$ exist, the total differential of $w$ is
$$\mathrm{d}w={f}_{x}(x,y,z)\mathrm{d}x+{f}_{y}(x,y,z)\mathrm{d}y+{f}_{z}(x,y,z)\mathrm{d}z.$$ |
This differential can be a good approximation of the change in $w$ when $w=f(x,y,z)$ is differentiable.
Let $w=f(x,y,z)$ be defined on an open set $S$ containing $({x}_{0},{y}_{0},{z}_{0})$ where ${f}_{x}({x}_{0},{y}_{0},{z}_{0})$, ${f}_{y}({x}_{0},{y}_{0},{z}_{0})$ and ${f}_{z}({x}_{0},{y}_{0},{z}_{0})$ exist. Let $\mathrm{d}w$ be the total differential of $w$ at $({x}_{0},{y}_{0},{z}_{0})$, let $\mathrm{\Delta}w=f({x}_{0}+\mathrm{d}x,{y}_{0}+\mathrm{d}y,{z}_{0}+\mathrm{d}z)-f({x}_{0},{y}_{0},{z}_{0})$, and let ${E}_{1}$, ${E}_{2}$ and ${E}_{3}$ be functions of $\mathrm{d}x$, $\mathrm{d}y$ and $\mathrm{d}z$ such that
$$\mathrm{\Delta}w=\mathrm{d}w+{E}_{1}\mathrm{d}x+{E}_{2}\mathrm{d}y+{E}_{3}\mathrm{d}z.$$ |
$f$ is differentiable at $\mathrm{(}{x}_{\mathrm{0}}\mathrm{,}{y}_{\mathrm{0}}\mathrm{,}{z}_{\mathrm{0}}\mathrm{)}$ if
$\underset{(\mathrm{d}x,\mathrm{d}y,\mathrm{d}z)\to (0,0,0)}{lim}{E}_{1}$ | $=0,$ | ||
$\underset{(\mathrm{d}x,\mathrm{d}y,\mathrm{d}z)\to (0,0,0)}{lim}{E}_{2}$ | $=0,\text{and}$ | ||
$\underset{(\mathrm{d}x,\mathrm{d}y,\mathrm{d}z)\to (0,0,0)}{lim}{E}_{3}$ | $=0.$ |
$f$ is differentiable on $S$ if $f$ is differentiable at every point in $S$. If $f$ is differentiable on ${\mathbb{R}}^{3}$, we say that $f$ is differentiable everywhere.
Just as before, this definition gives a rigorous statement about what it means to be differentiable that is not very intuitive. We follow it with a theorem similar to Theorem 13.4.1.
Let $w=f(x,y,z)$ be defined on an open set $S$ containing $({x}_{0},{y}_{0},{z}_{0})$. If ${f}_{x}$, ${f}_{y}$, and ${f}_{z}$ are continuous on $S$, then $f$ is differentiable on $B$.
This set of definition and theorem extends to functions of any number of variables. The theorem again gives us a simple way of verifying that most functions that we encounter are differentiable on their natural domains.
This section has given us a formal definition of what it means for a functions to be “differentiable,” along with a theorem that gives a more accessible understanding. The following sections return to notions prompted by our study of partial derivatives that make use of the fact that most functions we encounter are differentiable.
T/F: If $f(x,y)$ is differentiable on $S$, the $f$ is continuous on $S$.
T/F: If ${f}_{x}$ and ${f}_{y}$ are continuous on $S$, then $f$ is differentiable on $S$.
T/F: If $z=f(x,y)$ is differentiable, then the change in $z$ over small changes $\mathrm{d}x$ and $\mathrm{d}y$ in $x$ and $y$ is approximately $\mathrm{d}z$.
Finish the sentence: “The new $z$-value is approximately the old $z$-value plus the approximate .”
In Exercises 5–8., find the total differential $\mathrm{d}z$.
$z=x\mathrm{sin}y+{x}^{2}$
$z={\left(2{x}^{2}+3y\right)}^{2}$
$z=5x-7y$
$z=x{e}^{x+y}$
In Exercises 9–12., a function $z=f(x,y)$ is given. Give the indicated approximation using the total differential.
$f(x,y)=\sqrt{{x}^{2}+y}$. Approximate $f(2.95,7.1)$ knowing $f(3,7)=4$.
$f(x,y)=\mathrm{sin}x\mathrm{cos}y$. Approximate $f(0.1,-0.1)$ knowing $f(0,0)=0$.
$f(x,y)={x}^{2}y-x{y}^{2}$. Approximate $f(2.04,3.06)$ knowing $f(2,3)=-6$.
$f(x,y)=\mathrm{ln}\left(x-y\right)$. Approximate $f(5.1,3.98)$ knowing $f(5,4)=0$.
Exercises 13–16. ask a variety of questions dealing with approximating error and sensitivity analysis.
A cylindrical storage tank is to be 2ft tall with a radius of 1ft. Is the volume of the tank more sensitive to changes in the radius or the height?
Projectile Motion: The $x$-value of an object moving under the principles of projectile motion is $x(\theta ,{v}_{0},t)=\left({v}_{0}\mathrm{cos}\theta \right)t$. A particular projectile is fired with an initial velocity of ${v}_{0}=250$ft/s and an angle of elevation of $\theta ={60}^{\circ}$. It travels a distance of $375$ft in 3 seconds.
Is the projectile more sensitive to errors in initial speed or angle of elevation?
The length $\mathrm{\ell}$ of a long wall is to be approximated. The angle $\theta $, as shown in the diagram (not to scale), is measured to be ${85}^{\circ}$, and the distance $x$ is measured to be 30’. Assume that the triangle formed is a right triangle.
Is the measurement of the length of $\mathrm{\ell}$ more sensitive to errors in the measurement of $x$ or in $\theta $?
It is “common sense” that it is far better to measure a long distance with a long measuring tape rather than a short one. A measured distance $D$ can be viewed as the product of the length $\mathrm{\ell}$ of a measuring tape times the number $n$ of times it was used. For instance, using a 3’ tape 10 times gives a length of 30’. To measure the same distance with a 12’ tape, we would use the tape 2.5 times. (I.e., $30=12\times 2.5$.) Thus $D=n\mathrm{\ell}$.
Suppose each time a measurement is taken with the tape, the recorded distance is within 1/16” of the actual distance. (I.e., $d\mathrm{\ell}=1/{16}^{\prime \prime}\approx 0.005$ft). Using differentials, show why common sense proves correct in that it is better to use a long tape to measure long distances.
In Exercises 17–18., find the total differential $\mathrm{d}w$.
$w={x}^{2}y{z}^{3}$
$w={e}^{x}\mathrm{sin}y\mathrm{ln}z$
In Exercises 19–22., use the information provided and the total differential to make the given approximation.
$f(3,1)=7$, ${f}_{x}(3,1)=9$, ${f}_{y}(3,1)=-2$. Approximate $f(3.05,0.9)$.
$f(-4,2)=13$, ${f}_{x}(-4,2)=2.6$, ${f}_{y}(-4,2)=5.1$. Approximate $f(-4.12,2.07)$.
$f(2,4,5)=-1$, ${f}_{x}(2,4,5)=2$, ${f}_{y}(2,4,5)=-3$, ${f}_{z}(2,4,5)=3.7$. Approximate $f(2.5,4.1,4.8)$.
$f(3,3,3)=5$, ${f}_{x}(3,3,3)=2$, ${f}_{y}(3,3,3)=0$, ${f}_{z}(3,3,3)=-2$. Approximate $f(3.1,3.1,3.1)$.
Find where the function $z=\sqrt{{x}^{2}+{y}^{2}}$ is differentiable.