Example: Parameterizing a Line

Example: Parameterize the line through $P=(1,0)$ and $Q=(3,2)$ so that $P$ and $Q$ correspond to $t=1$ and $t=3$, respectively.

Solution 1: This is more-or-less the approach that we took in class. We look at the vector formed by going from point $P$ to point $Q$, which is $\vec{PQ}=2\vec{i}+2\vec{j}$. We create a line parallel to this emanating from $P$ and we get something that looks like

$\vec{r}(t)=P+t\vec{PQ}=\langle 1,0\rangle+t\langle 2,2\rangle$

The only problem with this is that it doesn’t satisfy the condition that $P$ occurs when $t=1$ and $Q$ occurs when $t=3$. We have component functions of the form

$x=1+2t\quad\text{and}\quad y=0+2t=2t.$

We can perform our standard algebraic manipulations here, multiplying $t$ by a scalar and adding some scalar to $t$. We know that increasing $t$ by 1 means that both $x$ and $t$ should increase by 1, and so we replace $t$ by $\frac{1}{2}t$ in the above component functions. (Notice that this just makes us traverse along the path from $P$ to $Q$ more slowly.) We now have component functions of the form

$x=1+t\quad\text{and}\quad y=t$

If we replace $t$ now by $t-1$, we get something that actually works. (What we’re doing here is just picking the line up and moving it along itself.) We now have

$x=1+(t-1)=t\quad\text{and}\quad y=t-1.$

Solution 2: Another way of doing this is to start with the displacement vector $\vec{OP}$ (from the origin to $P$), which we find to be $1\vec{i}+0\vec{j}$, and again consider the displacement vector $\vec{PQ}$ as being added on. We want $t=1$ to be the point along the line where we are at $P$, and so we know that we’ll have something along the lines of

$\vec{r}(t)=\vec{OP}+\frac{t-1}{a}\vec{PQ}$

since $t=1$ causes this to simply output the vector corresponding to $P$. Now, we need to know how to scale the right side of the equation (i.e., to traverse the line from $P$ to $Q$ at the appropriate pace). If $a=1$, then plugging in $t=3$ gives $\vec{OP}+2\vec{PQ}$, which overshoots $Q$. We find that $a=2$ works. So, we have

$\vec{r}(t)=\vec{OP}+\frac{t-1}{2}\vec{PQ}=\langle 1,0\rangle+\frac{t-1}{2}\langle 2,2\rangle=t\vec{i}+(t-1)\vec{j},$

which is exactly what we expected.

The Jacobian

The following image is Image 16.57 from your text, but I’ve modified it slightly. The idea is that we’re starting off in the situation on the left, with a function given in terms of $x$ and $y$ and a region $R$ awkwardly written (in this case a parallelogram) in the Cartesian plane. When we perform our change of variables, we are now integrating over a region $T$ in the variables $s$ and $t$. The key thing to notice is that $T$ is a rectangle, and we like integrating over rectangles.

For instance, this is the situation when we take a double integral in the Cartesian plane with $x$ and $y$ and convert it to a double integral in polar coordinates. Notice that an integral such as
$\int_{0}^{2\pi}\int_0^1 r\,dr\,d\theta$
calculates the area of a circle, by integrating over the rectangle where $0\le r\le 1$ and $0\le\theta\le 2\pi$. The extra $r$ in the integrand tells us that area increases linearly as $r$ increases from left to right inside this rectangle. So, looking at $T$ in the figure above, a small rectangle at the left side of $T$ is worth less in terms of area than the same sized rectangle at the right side of $T$.

In a general situation, we’d like to calculate our integral in the variables $s$ and $t$ given by the region $T$. But, we need to know how area in $x$ and $y$ relates to area in $s$ and $t$. In polar coordinates, the area in $R$ is given by taking the area in $T$ and multiplying it by $r$ (and so the area becomes more valuable as we move from left to right in $T$). In the general situation, we must calculate this translation factor, which is known as a Jacobian.

We view $x$ as a function $x=x(s,t)$ of $s$ and $t$. For instance, if $s=r$ and $t=\theta$, then $x=r\cos\theta$. Likewise, we view $y$ as a function $y(s,t)$. Given the diagram above, we have

\begin{align*} \vec{a} &= \left(x(s+\Delta s,t)-x(s,t)\right)\vec{i}+\left(y(s+\Delta s,t)-y(s,t)\right)\vec{j}\\ \vec{b} &= \left(x(s,t+\Delta t)-x(s,t)\right)\vec{i}+\left(y(s,t+\Delta t)-y(s,t)\right)\vec{j}.\\ \end{align*}

Notice that each component of $\vec{a}$ and $\vec{b}$ almost looks like a derivative. In fact, if we placed a $\Delta s$ or $\Delta t$ in the denominator, we’d have a difference quotient. So, we’ll multiply $\vec{a}$ by $\Delta s/\Delta s$ and multiply $\vec{b}$ by $\Delta t/\Delta t$, giving

$\vec{a}=\frac{\partial x}{\partial s}\Delta s\vec{i}+\frac{\partial y}{\partial s}\Delta s\vec{j} \qquad\text{and}\qquad \vec{b}=\frac{\partial x}{\partial t}\Delta t\vec{i}+\frac{\partial y}{\partial t}\Delta t\vec{j}.$

The whole reason why we’re doing this is to make the calculation of $\vec{a}\times\vec{b}$ easier to compute, since the cross product represents the area of the parallelogram between the two vectors. (We know the area in $T$ with respect to $s$ and $t$, and we want to know the corresponding area in $R$ with respect to $x$ and $y$.) We now compute the cross product. Actually, there are some technicalities here.

1. We only compute the magnitude of the cross product, which represents the area of the parallelogram. Recall that the cross product (which is only defined for 3-dimensional vectors) is a 3-dimensional vector. We’re only interested in the magnitude of the cross product, not its direction.

2. We could use the geometric interpretation $|\vec{a}\times\vec{b}|=|\vec{a}|\cdot|\vec{b}|\sin\theta$, if we knew the angle $\theta$ between $\vec{a}$ and $\vec{b}$. Usually, we don’t know $\theta$. So, we use the algebraic interpretation of the cross product:

$\vec{a}\times\vec{b}=\left| \begin{array}{ccc} \vec{i} & \vec{j} & \vec{k}\\ a_1 & a_2 & a_3\\ b_1 & b_2 & b_3 \end{array} \right|$

where we’re taking the determinant of the matrix and $a_3=b_3=0$ (since $\vec{a}$ and $\vec{b}$) are vectors in the $xy$-plane with no $z$-component).

OK, now we calculate the magnitude of the cross product.

\begin{align*} |\vec{a}\times\vec{b}| &= \left|\left| \begin{array}{ccc} \vec{i} & \vec{j} & \vec{k}\\ & & \\ \displaystyle\frac{\partial x}{\partial s}\Delta s &\displaystyle \frac{\partial y}{\partial s}\Delta s & 0\\ & & \\ \displaystyle\frac{\partial x}{\partial t}\Delta t & \displaystyle\frac{\partial y}{\partial t}\Delta t & 0 \end{array} \right|\right|\\ &= \left|\frac{\partial x}{\partial s}\Delta s\frac{\partial y}{\partial t}\Delta t-\frac{\partial x}{\partial t}\Delta t\frac{\partial y}{\partial s}\Delta s\right|\\ &=\Delta s\Delta t\left|\frac{\partial x}{\partial s}\frac{\partial y}{\partial t}-\frac{\partial x}{\partial t}\frac{\partial y}{\partial s}\right| \end{align*}

The idea here is that $\Delta s\Delta t$ represents area in a rectangle in variables $s$ and $t$, while the partials computation that follows represents the translation factor for area in $x$ and $y$. Unfortunately, this formula is hard to memorize. With that in mind, we note that

$|\vec{a}\times\vec{b}| = \left|\left| \begin{array}{ccc} \vec{i} & \vec{j} & \vec{k}\\ & & \\ \displaystyle\frac{\partial x}{\partial s}\Delta s &\displaystyle \frac{\partial y}{\partial s}\Delta s & 0\\ & & \\ \displaystyle\frac{\partial x}{\partial t}\Delta t & \displaystyle\frac{\partial y}{\partial t}\Delta t & 0 \end{array}\right|\right| = \left|\left| \begin{array}{ccc} \vec{i} & \vec{j} & \vec{k}\\ & & \\ \displaystyle\frac{\partial x}{\partial s}\Delta s & \displaystyle\frac{\partial x}{\partial t}\Delta t & 0\\ & & \\ \displaystyle \frac{\partial y}{\partial s}\Delta s & \displaystyle\frac{\partial y}{\partial t}\Delta t & 0 \end{array}\right|\right| = \left|\left| \begin{array}{cc} \displaystyle\frac{\partial x}{\partial s} & \displaystyle\frac{\partial x}{\partial t}\\ & \\ \displaystyle \frac{\partial y}{\partial s} & \displaystyle\frac{\partial y}{\partial t} \end{array} \right|\right|\Delta s\Delta t.$

Thus, we define the Jacobian using this slightly easier to remember formula:

$\frac{\partial(x,y)}{\partial(s,t)}=\left|\left|\begin{array}{cc} \displaystyle\frac{\partial x}{\partial s} & \displaystyle\frac{\partial x}{\partial t}\\ & \\ \displaystyle \frac{\partial y}{\partial s} & \displaystyle\frac{\partial y}{\partial t} \end{array} \right|\right|\,ds\,dt$

Algorithm for 2-Dimensional Change of Variables

To change the variables of a double integral $\displaystyle\int\int_R f(x,y)\,dx\,dy$ from the $xy$-plane to the $st$-plane:

1. Write the function $f(x,y)$ as a function in $s$ and $t$.

2. Write the bounds of integration in terms of $s$ and $t$.

3. Calculate the Jacobian and use it to replace $dx\,dy$ as

$dx\,dy = \frac{\partial(x,y)}{\partial(s,t)}= \left|\left|\begin{array}{cc} \displaystyle\frac{\partial x}{\partial s} & \displaystyle\frac{\partial x}{\partial t}\\ & \\ \displaystyle \frac{\partial y}{\partial s} & \displaystyle\frac{\partial y}{\partial t} \end{array} \right|\right|\,ds\,dt$

Polar Coordinates

Problem: Calculate the area of a circle of radius 1 centered at the origin.

Solution: We wish to calculate

$\int_{-1}^1\int_{-\sqrt{1-x^2}}^{\sqrt{1-x^2}}1\,dy\,dx.$

Step (1), changing the function $f(x,y)=1$ to be in terms of $r$ and $\theta$ is trivial. We still have 1 instead the integral. Step (2) is where we change the limits of integration to $0\le \theta\le 2\pi$ and $0\le r\le 1$. Step (3) is where we calculate

$dx\,dy = \frac{\partial(x,y)}{\partial(r,\theta)}= \left|\left|\begin{array}{cc} \cos\theta & -r\sin\theta\\ \sin\theta & r\cos\theta \end{array} \right|\right|\,dr\,d\theta= (r\cos^2\theta +r\sin^2\theta)\,dr\,d\theta= r\,dr\,d\theta$

Putting this together, we have

$\int_0^{2\pi}\int_0^1 1r\,dr\,d\theta=\pi.$

Area of an Ellipse

This is an example taken from our text, with some more details added. Find the area of the ellipse

$\frac{x^2}{a^2}+\frac{y^2}{b^2}\le 1.$

Solution: I would approach this a different way than your text does. First, I’m only interested in finding the area in one quadrant, since the area of the entire ellipse is four times that. Solving for $y$ and looking at the first quadrant gives us

$4\int_0^a\int_0^{\sqrt{b^2-\frac{b^2x^2}{a^2}}} 1\,dy\,dx.$

That integral doesn’t look fun. Let’s use a change of variables to squash the ellipse into a circle. We’ll use the variables $s$ and $t$ and write our original variables $x$ and $y$ in terms

$x=as\qquad\text{and}\qquad y=bt.$

Then, we are looking at finding the area of

$s^2+t^2\le 1$

in the $st$-plane. The function we’re integrating is 1, and so step (1) of the algorithm is already complete for us. Step (2) involves changing the limits of integration. Again, we’re only going to consider one quadrant, and multiply the result by 2. The Jacobian turns out to be $ab\,ds\,dt$. All of this together gives us

$4\int_0^1\int_0^{\sqrt{1-t^2}}ab\,ds\,dt=4ab\int_0^1\int_0^{\sqrt{1-t^2}}1\,ds\,dt.$

Converting this again to polar coordinates (and going through all 3 steps) gives us

$4ab\int_0^1\int_0^{\sqrt{1-t^2}}1\,ds\,dt=4ab\int_0^{\pi/2}\int_0^1r\,dr\,d\theta.$

Calculating this yields

$4ab\int_0^{\pi/2}\int_0^1r\,dr\,d\theta=4ab\int_0^{\pi/2}\,d\theta\int_0^1r\,dr=4ab\frac{\pi}{2}\frac{1}{2}=\pi ab.$

Integration by Parts Notes

This is designed to be a fairly complete review of integration by parts using some examples. For the basics, see your text. These examples are more designed to show you how integration by parts is actually done.

A printable version is here: spring2012math2400_examples_7.2 (pdf)

Classic Examples

Example 1. $\displaystyle \int xe^x\,dx$

Solution: We select $u$ and $v’$ and then $u’$ and $v$ follow.
\begin{align*} u &= x & v'&=e^x\\ u'&= 1 & v &=e^x \end{align*}

\begin{align*} \int xe^x\,dx&=xe^x-\int e^x\,dx\\ &=xe^x-e^x+C \end{align*}

Example 2. $\displaystyle \int x\sin x\,dx$

Solutions:
\begin{align*} u &= x & v'&= \sin x\\ u' &= 1 & v &= -\cos x \end{align*}

\begin{align*} \int x\sin x\,dx &= -x\cos x+\int \cos x\,dx\\ &= -x\cos x+\sin x+ C \end{align*}

Integration By Parts Multiple Times

Example 3. $\displaystyle \int x^2\sin x\,dx$

Solution: What happens here is that the first application of integration by parts results in another integral that is best approached by using integration by parts.
\begin{align*} u_1&=x^2 & v_1'&=\sin x\\ u_1'&=2x & v_1&=-\cos x \end{align*}
\begin{align*} \int x^2\sin x\,dx &= x^2\cos x+\int 2x\cos x\,dx\\ &=x^2\cos x+2\int x\cos x\,dx \end{align*}
\begin{align*} u_2&=x & v_2'&=\cos x\\ u_2'&=1 & v_2&=\sin x \end{align*}
\begin{align*} &=x^2\cos x+2\left(x\sin x-\int \sin x\,dx\right)\\ &=x^2\cos x+2x\sin x+2\cos x+C \end{align*}

Example 4. $\displaystyle \int x^2 e^x\,dx$

Solution: Again, we use integration by parts twice. The subscripts on the variables below tell us during which application of integration by parts those variables were used.
\begin{align*} u_1&=x^2 & v_1'&=e^x\\ u_1'&=2x & v_1&=e^x\\ u_2&=2x & v_2'&=e^x\\ u_2'&=2 & v_2&=e^x \end{align*}
\begin{align*} \int x^2e^x\,dx &= x^2e^x-\int 2xe^x\,dx\\ &=x^2e^x-\left(2xe^x-\int 2e^x\,dx\right)\\ &= x^2e^x-2xe^x-2e^x+C. \end{align*}

Definite Integral Examples

Example 5. $\displaystyle \int_1^5\ln x\,dx$

This is also a good example of how you can sometimes use integration by parts with one of the functions being trivial (i.e., $v’=1$).

Solution: When we use integration by parts, we simply keep in mind that we’re evaluating the original integral from 1 to 5. That means that we must evaluate BOTH terms (the $x\ln x$ and the integral) given by integration by parts. Also, it helps to remember here that $\ln 1=0$.
\begin{align*} u&= \ln x & v'&=1\\ u'&=\frac{1}{x} & v&=x \end{align*}
\begin{align*} \int_1^5\ln x\,dx &= x\ln x\Big\vert_1^5-\int_1^5\,dx\\ &=5\ln 5-\ln 1-4\\ &=5\ln 5-4 \end{align*}

More Complicated Examples

Example 6. $\displaystyle \int \cos^2(3\alpha+1)\,d\alpha$

Solutions: We need to use integration by parts, plus a trig identity, plus substitution in order to compute this integral.
\begin{align*} u&=\cos(3\alpha+1) & v'&=\cos(3\alpha+1)\\ u'&=-3\sin(3\alpha+1) & v&=\frac{1}{3}\sin(3\alpha+1) \end{align*}
\begin{align*} &\int\cos^2(3\alpha+1)\,d\alpha =\int\cos(3\alpha+1)\cos(3\alpha+1)\,d\alpha\\ &=\frac{1}{3}\cos(3\alpha+1)\sin(3\alpha+1)+\int\sin^2(3\alpha+1)\,d\alpha \end{align*}
By using the trig identity $\cos 2\alpha = 1-2\sin^2\alpha$ and solving for $\sin^2\alpha$ we can write the above as
{\small\begin{align*} &=\frac{1}{3}\cos(3\alpha+1)\sin(3\alpha+1)+\int\frac{1}{2}-\frac{1}{2}\cos(6\alpha+2)\,d\alpha \end{align*}}
Using the substitution $w=6\alpha+2$ (and so $dw=6\,d\alpha$) this then becomes
{\small\begin{align*} &=\frac{1}{3}\cos(3\alpha+1)\sin(3\alpha+1)+\frac{1}{4}x^2-\frac{1}{12}\int\cos w\,dw\\ &=\frac{1}{3}\cos(3\alpha+1)\sin(3\alpha+1)+\frac{1}{4}x^2-\frac{1}{12}\sin w+C\\ &=\frac{1}{3}\cos(3\alpha+1)\sin(3\alpha+1)+\frac{1}{4}x^2-\frac{1}{12}\sin(6\alpha+2)+C \end{align*}}

Recursive Examples

Example 7. $\displaystyle \int e^x\sin x\,dx$

Solution: In this case, neither $e^x$ or $\sin x$ will become simpler when differentiated, and so at the start it doesn’t seem like integration by parts can help. But, something interesting happens.
\begin{align*} u_1&=e^x & v_1'&=\sin x\\ u_1'&=e^x & v_1&=-\cos x\\ u_2&=e^x & v_2'&=\cos x\\ u_2'&=e^x & v_2&=\sin x \end{align*}
\begin{align*} \int e^x\sin x\,dx &= -e^x\cos x+\int e^x\cos x\,dx\\ &=-e^x\cos x+e^x\sin x-\int e^x\sin x\,dx \end{align*}
The main thing to notice here is that the integral we are trying to find is on both sides of the equation, and since the right hand side version is negative, we add it to both sides. We get
\begin{align*} 2\int e^x\sin x\,dx &= -e^x\cos x+e^x\sin x \end{align*}
and dividing both sides by 2 gives
$\int e^x\sin x\,dx =\frac{1}{2}\left(-e^x\cos x+e^x\sin x\right)+C.$

Example 8. $\displaystyle \int \cos^2\theta\,d\theta$

Solution: There are two ways to consider this problem. One is to use the identity
$\cos^2\theta=\frac{1+\cos 2\theta}{2}$
and substitution. The other is to use the Pythagorean identity
$\cos^2\theta = 1-\sin^2\theta$
and integration by parts. The latter is done here.
\begin{align*} u&=\cos\theta & v'&=\cos\theta\\ u'&=-\sin\theta & v&=\sin\theta \end{align*}
\begin{align*} \int\cos^2\theta\,d\theta &= \cos\theta\sin\theta +\int\sin^2\theta\,d\theta\\ &=\cos\theta\sin\theta+\int 1-\cos^2\theta\,d\theta\\ &=\cos\theta\sin\theta+\int 1\,d\theta-\int\cos^2\theta\,d\theta \end{align*}
Adding the integral of $\cos^2\theta$ to both sides gives
\begin{align*} 2\int\cos^2\theta\,d\theta &=\cos\theta\sin\theta+\int 1\,d\theta\\ 2\int\cos^2\theta\,d\theta &=\cos\theta\sin\theta+\theta+C\\ \int\cos^2\theta\,d\theta &=\frac{1}{2}\left(\cos\theta\sin\theta+\theta\right)+C. \end{align*}

Reduction Formula Example

Example 9. Prove the formula
$\int\sin^n\,dx=-\frac{1}{n}\cos x\sin^{n-1}x+\frac{n-1}{n}\int \sin^{n-2}x\,dx$

Solution: The main idea is to start with one function as $\sin^{n-1}x$ and the other as $\sin x$. Proceed as follows.
\begin{align*} u&=\sin^{n-1}x & v'&=\sin x\\ u'&= (n-1)\sin^{n-2}x\cos x & v&=-\cos x. \end{align*}
\begin{align*} &\ \ \int\sin^nx\,dx\\ &= -\cos x\sin^{n-1}x +\int(n-1)\sin^{n-2}x\cos x\cos x\,dx\\ &= -\cos x\sin^{n-1}x+\int(n-1)\sin^{n-2}x\cos^2 x\,dx\\ &= -\cos x\sin^{n-1}x+\int(n-1)\sin^{n-2}x(1-\sin^2 x)\,dx\\ &= -\cos x\sin^{n-1}x+(n-1)\int \sin^{n-2}x-\sin^nx\,dx\\ &= -\cos x\sin^{n-1}x+(n-1)\int\sin^{n-2}x\,dx-(n-1)\int\sin^{n}x\,dx \end{align*}
Now move the $(n-1)\int\sin^nx\,dx$ to the left side.
\begin{align*} \int\sin^nx\,dx+(n-1)\int\sin^nx\,dx &=-\cos x\sin^{n-1}x+(n-1)\int\sin^{n-2}x\,dx\\ n\int\sin^nx\,dx &=-\cos x\sin^{n-1}x+(n-1)\int\sin^{n-2}x\,dx\\ \int\sin^nx\,dx &=-\frac{1}{n}\cos x\sin^{n-1}x+\frac{n-1}{n}\int\sin^{n-2}x\,dx \end{align*}

Main Idea

Given a function $f$ in multiple variables, we want to maximize $f$ under a constraint $g=c$. We view $g=c$ as a level surface for the function $g$. For example, we could maximize or minimize the function $f(x,y)=2x+3y$ under the constraint $g(x,y)=x^2+y^2=2$. As I showed in class, we’re looking for points $(x,y)$ such that the contours of $f$ are parallel with the contour of $g(x,y)=x^2+y^2=10$. At these points, $\nabla f=\lambda\nabla g$ for some constant $\lambda$. (You can also insist alternatively on $\nabla f=-\lambda\nabla g$, since $\lambda$ is a constant real number.)

The $\lambda$ constant is called a Lagrange multiplier. We can generalize this situation by creating the Lagrangian function, defined as
$\Lambda(x,y,\lambda)=f+\lambda(g-c)$
where $c$ is the level curve given for $g$. Now, taking the gradient of $\Lambda$ and setting each component to zero allows us to find the points where the contours of $f$ are parallel to the contour $g=c$.

Example 1

Problem: Find the maximum and minimum points of $f(x,y)=x+y$ relative to the constraint $g(x,y)=x^2+y^2=1$. (That is, find the maximum and minimum values of the function $f$ that lie above the unit circle.)

Solution 1: The Lagrangian in this situation (with the minus sign, as in your text) is
$\Lambda(x,y,\lambda)=f(x,y)-\lambda(g(x,y)-c)=x+y-\lambda(x^2+y^2-1).$
The gradient of the Lagrangian is then
$\nabla\Lambda = \left[1-2\lambda x,1-2\lambda y,-x^2-y^2-1 \right].$
Setting the first two components to zero implies $1-2\lambda x=1-2\lambda y=0$. Notice that the function $f(x,y)$ has no critical points (it is a plane), and so we never have to worry about the gradient being zero. Thus, we never have to worry about $\lambda$ being zero. Thus, we know that if $\nabla\Lambda=\vec{0}$ then $x=y$. We know from $x^2+y^2=1$ then that $2x^2=1$ and hence $x=\pm\frac{\sqrt{2}}{2}$. We now know that the points to consider are
$\left(-\frac{\sqrt{2}}{2},-\frac{\sqrt{2}}{2}\right) \qquad\text{and}\qquad\left(\frac{\sqrt{2}}{2},\frac{\sqrt{2}}{2}\right).$
Of course, knowing what the plane $z=f(x,y)=x+y$ looks like, we know that the first of these is the minimum and the latter is the maximum. (If we have more points to check, or if the structure of the surface $f$ isn’t obvious, then we simply plug in all of the points under consideration to $f$, keeping track of which one is a minimum and which is a maximum.)

Solution 2: One can do this without the Lagrangian. If we consider simply the gradient of $f$ and the gradient of $g$, setting the gradients parallel with a Lagrange multiplier as a constant gives
$1=\lambda 2x\qquad\text{and}\qquad 1=\lambda 2y.$
Again, this implies $x=y$ and then we solve the problem as in Solution 1.

Example 2

Problem: Find the maximum and minimum points of $f(x,y)=x^2y+3y^2-y$ under the constraint $g(x,y)=x^2+y^2\le 10$.

Solution: Here’s an example of where the constraint may not actually matter. We’ll consider two problems:

1. Maximize/minimize $f$ with respect to $x^2+y^2< 10$.
2. Maximize/minimize $f$ with respect to $x^2+y^2=10$.

The first of these is a standard optimization problem where we simply verify that each pair of critical points under consideration satisfies $x^2+y^2<10$. The second problem is a Lagrange multiplier problem.

In terms of the first problem, we find the critical points of $f$:
$f_x=2xy=0\qquad f_y=x^2+6y-1=0.$
From the first equation, we get either $x=0$ or $y=0$. If $x=0$, from the second equation we get $6y-1=0$ and so $y=1/6$. If instead we have $y=0$ then the second equation tells us that $x=\pm 1$. We conclude that the critical points are
$(0,1/6),\ (1,0),\ \text{and}\ (-1,0).$
Notice that all of these critical points satisfy the constraint $x^2+y^2\le 10$. We keep these points in mind and start on the second problem.

The Lagrange conditions $\nabla f=\lambda\nabla g$ tell us that
$2xy=\lambda 2x\qquad\text{and}\qquad x^2+6y-1=\lambda 2y.$
From the first equation, when $x\neq 0$, we divide by $x$ and get $\lambda=x$. Substituting into the second equation, we then have
$x^2+6y-1=2y^2.$
Then using $x^2=10-y^2$ from the constraint, we get
$10-y^2+6y-1=2y^2.$
This implies that $3y^2-6y-9=0$. Factoring gives $3(y-3)(y+1)=0$. From the constraint, we get $x=\pm 1$ when $y=3$ and $x\pm 3$ when $y=-1$. If instead we have $x=0$ (where we cannot divide by $x$ in the first Lagrange equation), then from the constraint we know that $y=\pm\sqrt{10}$.

Thus, we collect all of our points that are of interest (those found previously and those found in the Lagrange multiplier version) and we have all of the following points to consider:

$(1,0),\ (-1,0),\ (0,1/6),\ (\pm 1,3),\ (\pm 3,-1),\ (0,\pm\sqrt{10}).$
The maximum value is found to be at $(0,-\sqrt{10})$ and the minimum is at $(3,-1)$ and $(-3,-1)$.

Example 3

Problem: Consider a closed cylindrical container holding 100 cubic centimeters. Provide a relationship between the radius and height which will minimize the surface area for such a container.

Solution: The surface are is given by $S(r,h)=2\pi r^2+2\pi rh$. The constraint on this surface area equation is provided by the volume function and level surface $g(r,h)=\pi r^2h=100$. What is really sort of cool here is that we don’t need to consider the 100 component at all. Taking gradients, we find that
$\nabla S=\langle 4\pi r+2\pi h,2\pi r\rangle=\lambda\nabla g=\lambda\langle 2\pi rh,\pi r^2\rangle.$
Solving for $\lambda$ gives $\lambda=2/r$. This then implies that $4\pi r+2\pi h=4\pi h$, and we find from here that $2r=h$. That is, there is a critical point with respect to our constraint when we make the radius twice the height. How do we know that this is a minimum? You could view that in several ways. It makes sense geometrically from the definition of the surface area function. If you’re not yet convinced, you could use the second derivative test.

Minimizing Distance

There is a problem on WebWork that a few of you are asking about. Problem 18 in the Section 15.1 & 15.2 assignment asks the following: What is the shortest distance from the surface $xy+3x+z^2=12$ to the origin?

Solution: When you’re dealing with a distance problem, you’re tempted to minimize something that looks like

$f(x,y,z)=\sqrt{x^2+y^2+z^2}.$

I’d caution against doing that, since you might as well minimize $f(x,y,z)=x^2+y^2+z^2$ instead (it’s a LOT easier). We’ll set $S=x^2+y^2+z^2$ and we’ll take the given function and solve for $z$ as best as possible, getting $z^2=12-xy-3x$. Putting these two pieces together, we end up with

$S=x^2+y^2+12-xy-3x.$

This is a polynomial function, so we know that the critical points will only occur where the gradient is zero. So, we have

$\nabla S=\langle 2x-y-3,2y-x\rangle =\vec{0}.$

This implies that $x=2y$, and it follows that $(2,1)$ is the only critical point. Now, we use the second derivative test, where

$D=S_{xx}(2,1)S_{yy}(2,1)-(S_{xy}(2,1))^2=3>0$

and so we know that we’re at a local minimum. Moreover, looking at $S$ as $x\to\pm\infty$ and $y\to\pm\infty$, we have $S$ going to positive infinity in all directions. Thus, we know that we have found the global minimum of our distance function.

Chain Rule

1. If $g(s,t)=f(s^2-t^2,t^2-s^2)$ and $f$ is differentiable, show that

$t\frac{\partial g}{\partial s}+s\frac{\partial g}{\partial t}=0.$

Solution: It may be helpful to realize that $\frac{\partial g}{\partial s}=\frac{\partial f}{\partial s}$, and so on. The function tree here looks something like the following.

We find from the chain rule that

$\frac{\partial g}{\partial s}=\frac{\partial f}{\partial s}=\frac{\partial f}{\partial x}\frac{\partial x}{\partial s}+\frac{\partial f}{\partial y}\frac{\partial y}{\partial s}=\frac{\partial f}{\partial x}2s+\frac{\partial f}{\partial y}(-2s).$

Likewise, we have

$\frac{\partial g}{\partial t}=\frac{\partial f}{\partial x}(-2t)+\frac{\partial f}{\partial y}(2t).$

Now, look at the original equation we were trying to show. It should now be clear that the equation is true.

Implicit Differentiation

The example that I usually use to show implicit differentiation is $y=\frac{1}{x}$. Of course, this is a function written explicitly, but we’ll assume that we are incapable of doing division and we’ll instead write this as $xy=1$. Viewing both sides a function of $x$, and especially viewing the left as a product of functions of $x$ (one of them being $x$ and one of them being $y=f(x)$), we can now differentiate both sides with respect to $x$. We get

\begin{align*} yx &= 1\\ f(x)x &= 1\\ \frac{d}{dx}[f(x)x]&=\frac{d}{dx}1\\ f’(x)x+f(x)&= 0\\ f’(x)x&=-f(x)\\ f’(x)&=\frac{-f(x)}{x}\\ f’(x)&=\frac{-y}{x}\\ f’(x)&=\frac{-1/x}{x}\\ f’(x)&=-\frac{1}{x^2}. \end{align*}

We’re really using the chain rule here, since we’re considering the derivative of $f(x)x$ and $f(x)$ is a function of $x$. We can do the same thing in multiple variables. Let’s consider an example.

2. Find $y’$ if $x^3+y^3=6xy$.

Solution: We’ll view this as a function of two variables set at a specific level surface. That is, we write

$F(x,y)=x^3+y^3-6xy=0.$

Now, we have something where we can differentiate both sides, as we did in the $y=1/x$ example above. This is a bit weird, since we have a function tree that looks like

We’re actually trying to find the derivative represented by the bottom-right link in the tree. Differentiating both sides of the equation with respect to $x$ gives us

\begin{align*} \frac{\partial F}{\partial x}+\frac{\partial F}{\partial y}\frac{dy}{dx} &= \frac{d}{dx}[0]\\ F_x + F_y\frac{dy}{dx} &= 0\\ \frac{dy}{dx} &= -\frac{F_x}{F_y}. \end{align*}

OK, that’s a nice equation at the end. What this says is the following: If we want to calculate the derivative of $y$ with respect to $x$, we simply need to take the partial derivative of $F$ with respect to $x$ and the partial derivative of $F$ with respect to $y$, and take their quotient. Neat! So, we can solve this problem quickly now by writing

$y'=-\frac{3x^2-6y}{3y^2-6x}=-\frac{x^2-2y}{y^2-2x}.$

Directional Derivative

There’s really nothing too special going on here. Instead of calculating the rate of change of the function along a single axis (as a partial derivative does), we’re now going in arbitrary directions. The only real technicality is that we need a vector representing the direction we want to travel, and so we use a unit vector in that direction. We use a unit vector because we really want to know “as I travel one unit in the direction of $\vec{u}$, how much does the function change?” If we had anything besides a unit vector, this would be an awkward measurement. It’s like saying that your car gets 28 miles to the gallon compared to saying your car gets 41 miles to the $\sqrt{2}$ gallons.

The definition says that if $\vec{u}=u_1\vec{i}+u_2\vec{j}$ is a unit vector, then the directional derivative $f_{\vec{u}}$ at the point $(a,b)$ is defined as

$f_{\vec{u}}(a,b)=\lim_{h\to 0}\frac{f(a+hu_1,\ b+hu_2)-f(a,b)}{h}.$

This quantity, when the limit exists, tells us how fast the function is changing as we move in the direction of $\vec{u}$. (If you’re not given a unit vector for $\vec{u}$, make it in to a unit vector before trying to use it. Here’s where things get interesting. Notice that if we want to calculate the rate of change of $f$ in a direction given by $\vec{u}$, we could use the components of $\vec{u}$ and consider the partial derivatives. (This really assumes local linearity, and we aren’t too horribly worried about the specifics in this course. I’m presenting the details here because some of you seemed interested.)

The figure shows a plane having a point at the origin and a positive slope in the $x$ and $y$ directions (hence positive partial derivatives). The slope of the green line (the directional derivative) is the slopes of the red line (the $x$-derivative) and blue line (the $y$-derivative) added together. Thus, we really have

\begin{align*} f_{\vec{u}}(a,b) &= \lim_{h\to 0}\frac{f(a+hu_1,b+hu_2)-f(a,b)}{h}\cr &= \lim_{h\to 0}\frac{f(a+hu_1,b)-f(a,b)}{h}+\lim_{h\to 0}\frac{f(a,b+hu_2)-f(a,b)}{h}\cr &= \lim_{h\to 0}u_1\frac{f(a+h,b)-f(a,b)}{h}+\lim_{h\to 0}u_2\frac{f(a,b+h)-f(a,b)}{h}\cr &= u_1\lim_{h\to 0}\frac{f(a+h,b)-f(a,b)}{h}+u_2\lim_{h\to 0}\frac{f(a,b+h)-f(a,b)}{h}\cr &= u_1f_x(a,b)+u_2f_y(a,b)\cr &= f_x(a,b)u_1+f_y(a,b)u_2\cr &= \left\langle f_x,f_y\right\rangle\cdot\left\langle u_1,u_2\right\rangle\cr &= \nabla f\cdot \vec{u}. \end{align*}

The $\nabla f$ is incredibly useful and is called the gradient of $f$. It is simply a vector where the components are the partial derivatives of the given function. More information on the gradient is in your text. What the gradient is, how it is used, its direction and magnitude, these are all very fundamental concepts in this class.

It might seem a bit like magic that we can pull the $u_1$ and $u_2$ out from the quotients. You should realize what the quotients at either side of that process represent. Before pulling out the $u_1$ or $u_2$, we’re looking at the slope of the secant line as we travel $hu_1$ and $hu_2$ along the $x$ and $y$-axes, respectively. That amount of change is simply $u_1$ or $u_2$ times the amount of change for simply going $h$ along those axes. So, we can actually pull those numbers out from the quotients and then out in front of the limits.

Example 1: Find the directional derivative of $x^2+y$ in the direction of $\vec{u}=\vec{i}+\vec{j}$.

Solution: We’re not asked to find the directional derivative at a specific point, and so we’ll do it for arbitrary points $(x,y)$. (Thus, if you want the directional derivative at a specific point, simply plug in the $x$ and $y$ for that point.) A unit vector in the direction of $\vec{u}$ is $\vec{v}=\frac{1}{\sqrt{2}}\vec{i}+\frac{1}{\sqrt{2}}\vec{j}$. Now, from the definition of directional derivative, we find that

\begin{align*} f_{\vec{v}}(x,y) &= \lim_{h\to 0}\frac{f\left(x+h\frac{1}{\sqrt{2}},y+h\frac{1}{\sqrt{2}}\right)-f(x,y)}{h}\cr &= \lim_{h\to 0}\frac{\left(x+h\frac{1}{\sqrt{2}}\right)^2+\left(y+h\frac{1}{\sqrt{2}}\right)-(x^2+y)}{h}\cr &= \lim_{h\to 0}\frac{2xh\frac{1}{\sqrt{2}}+\frac{1}{2}h^2+h\frac{1}{\sqrt{2}}}{h}\cr &= \lim_{h\to 0}2x\frac{1}{\sqrt{2}}+\frac{1}{2}h+\frac{1}{\sqrt{2}}\cr &= \frac{1}{\sqrt{2}}(2x+1) \end{align*}

Of course, we could simply use the equivalences given above and use the fact that $f_{\vec{v}}(x,y)=\langle f_x,f_y\rangle\cdot\langle u_1,u_2\rangle$. We know that $f_x=2x$ and $f_y=1$. This gives the same result much more quickly.

There are a few key points in understanding how the gradient actually gets used. These are illustrated by several examples.

Example 2: This is much like a WebWork problem. Assume you’re climbing a mountain along the steepest route at a rate of $20^\circ$. As you climb, a trail diverges to your left at an angle of $30^\circ$ (according to the map). Assuming the mountain is locally linear, if you take the trail to the left, at what rate will you now be climbing the mountain?

Solution: The gradient represents the maximum rate of change for a function and the direction in which that rate of change occurs. Therefore, while you’re climbing the steepest route up the mountain, you’re following the gradient. Now, what you want to know is the rate of change of the height of the surface that is the mountain as you travel $30^\circ$ from the gradient. That is, you wish to know the directional derivative along the path that we’ll call $\vec{u}$ (a unit vector in the direction of $30^\circ$ counter-clockwise from the gradient). We know that

$f_{\vec{u}}=\nabla f\cdot \vec{u}=||\nabla f||\,||\vec{u}||\cos(30^\circ).$

The problem here comes in realizing that $||\nabla f||=\tan(20^\circ)$ and $||\vec{u}||=1$. Thus, we know that

$f_{\vec{u}}=\tan(20^\circ)\cos(30^\circ).$

Of course, that tells us the rate of change (rise over run), and so we can get the angle by using arctan:
$\tan^{-1}(\tan(20^\circ)\cos(30^\circ))$

Example 3: Find an equation of the tangent plane to the surface $2x+3y^2+\sin(z)=4$ at the point $(1,-1,3\pi/2)$.

Solution: The gradient gives us a normal vector to the surface, as discussed in class. The required normal vector is
$\nabla f(1,-1,3\pi/2)=\langle 2,6y,\cos(z)\rangle|_{(1,-1,3\pi/2)}=\langle 2,-6,0\rangle.$

Thus, the equation of the tangent plane is
$2(x-1)-6(y+1)=0.$

Section 13.3

Print Version: s2012m2400-13-3.pdf

Algebraic definition of the dot product: Given two vectors $\vec{v}$ and $\vec{w}$ of dimension $n$,
$\vec{v}\cdot\vec{w}=v_1w_1+v_2w_2+\cdots+v_nw_n.$

Geometric definition of the dot product: Given two vectors $\vec{v}$ and $\vec{w}$ with the (smallest) angle between them being $\theta$,
$\vec{v}\cdot\vec{w}=||\vec{v}||\,||\vec{w}||\cos\theta.$

Proof of Dot Product Equality

Theorem: The two definitions of the dot product yield the same object.

Proof: To prove that the two definitions of the dot product are in fact the same, consider the following diagram.

In this situation, the law of cosines states that $||\vec{v}-\vec{w}||^2=||\vec{v}||^2+||\vec{w}||^2-2||\vec{v}||\,||\vec{w}||\cos\theta$. If we expand the left side of this equation, we get (from the distance formula)

$||\vec{v}-\vec{w}||^2=\left(\sqrt{(v_1-w_1)^2+\cdots+(v_n-w_n)^2}\right)^2=\sum_{i=1}^n(v_i-w_i)^2=\sum_{i=1}^n(v_i^2-2v_iw_i+w_i^2).$

We can separate the sum and we are left with the left hand side of the given equation equal to

$\sum_{i=1}^n v_i^2-2\sum_{i=1}^nv_iw_i+\sum_{i=1}^n w_i^2$
If we expand parts of the right hand side using the same idea, we have

$||\vec{v}||^2+||\vec{w}||^2-2||\vec{v}||\,||\vec{w}||\cos\theta=\sum_{i=1}^n v_i^2+\sum_{i=1}^n w_i^2-2||\vec{v}||\,||\vec{w}||\cos\theta.$

So, after transforming the left and right sides separately, we now have that

$\sum_{i=1}^n v_i^2-2\sum_{i=1}^nv_iw_i+\sum_{i=1}^n w_i^2=\sum_{i=1}^n v_i^2+\sum_{i=1}^n w_i^2-2||\vec{v}||\,||\vec{w}||\cos\theta.$

Notice that this simplifies to

$\sum_{i=1}^n v_iw_i=||\vec{v}||\,||\vec{w}||\cos\theta,$

and we’re done. (The sum on the left is the algebraic version and the right side is the geometric version.) $\Box$

The Equation of a Plane

We discussed the definitions of “perpendicular” (also: “orthogonal”) in class. This lead to the definition of a normal vector. Those are all very important and you should become familiar with them.

If you are given a point $P_0=(x_0,y_0,z_0)$ on a plane and a normal vector $\vec{n}$ to the plane, you can construct the equation of the plane very quickly as

$n_1(x-x_0)+n_2(y-y_0)+n_3(z-z_0)=0.$

Someone asked in class how this relates to the equation of a plane we already know from Chapter 12:

$z=\frac{\Delta z}{\Delta x}(x-x_0)+\frac{\Delta z}{\Delta y}(y-y_0)+z_0.$

Here’s how. If we solve the top equation for $z$, we have

$z=-\frac{n_1}{n_3}(x-x_0)-\frac{n_2}{n_3}(y-y_0)+z_0.$

The key point is that
$\frac{\Delta z}{\Delta x}=-\frac{n_1}{n_3}\qquad\frac{\Delta z}{\Delta y}=-\frac{n_2}{n_3}.$

To see this, you should notice that the left side of each of these equalities is viewed as being on the plane. The right sides are calculated along the normal vector. The plane and the normal vector are orthogonal. How do you calculate slopes of orthogonal lines? Remember from algebra that perpendicular lines have negative reciprocal slopes. To be more specific, we have
$\frac{\Delta z}{\Delta x}=-\frac{n_1}{n_3}=-\left(\frac{n_3}{n_1}\right)^{-1}$
where you should realize that $n_3$ is simply the change in $z$ along the normal vector and $n_1$ is the change in $x$ along the normal vector. So, these really are the same equations of the plane, just written in two drastically different ways.

Examples

Example 1: Find a normal vector to the plane $z+2(x-2)=8(2-y)$.

Solution: If we can place this equation in the form $n_1(x-x_0)+n_2(y-y_0)+n_3(z-z_0)=0$, and determine what the components $n_i$ must be, we’ll be done. In fact, as showed in class, the given plane can be pushed around algebraically until we get
$2(x-2)+8(y-2)+1(z-0)=0.$

Thus, a normal vector is $\vec{n}=2\vec{i}+8\vec{j}+\vec{k}$.

Example 2: Find a vector parallel to the plane in the previous example.

Solution: Any vector parallel to the plane must also be orthogonal to any normal vector for the plane. So, our goal is simply to create any vector that is orthogonal to the normal vector we found in the previous example. We use the algebraic version of the dot product to do this. (There are infinitely many solutions.) For instance, we know that if $\vec{v}$ is our parallel vector, then
$v_1n_1+v_2n_2+v_3n_3=2v_1+8v_2+v_3=0$
by the definition of orthogonality. We could use $v_1=-8$, $v_2=2$, and $v_3=0$.

Example 3: Find the angle between $\vec{v}=\vec{i}+2\vec{j}+\vec{k}$ and $\vec{w}=-\vec{i}+3\vec{k}$.

Solution: Both versions of the dot product will be used here. Namely, the algebraic version is on the left and the geometric version is on the right. We have
$(1)(-1)+(2)(0)+(1)(3)=||\vec{v}||\,||\vec{w}||\cos\theta.$
Calculating the norm of the vectors and simplifying gives us
$2=\sqrt{60}\cos\theta=2\sqrt{15}\cos\theta.$
Thus, we have $\cos\theta=1/\sqrt{15}$, or $\theta=\cos^{-1}(1/\sqrt{15})$.

Section 12.6

Print Version: 12-6.pdf

You can find the definition of level set, limit, and continuity in your text. I’ll add some understanding to those definitions here. Also, we used a sage worksheet in class to introduce the various shapes that will be important to this course. You can find that worksheet at http://sage.colorado.edu/home/pub/2.

Limit Examples

Example 1: The function $f(x,y)=\displaystyle\frac{x^2y}{x^2+y^2}$ is clearly not continuous at the origin since it is not defined there. But, does the limit
$\lim_{(x,y)\to(0,0)}f(x,y)$
exist?

Solution: By the definition of limit, we want some value $L$ such that $f(x,y)$ is very close to $L$ as $(x,y)$ is substantially close to $(0,0)$. In other words, if we can figure out a way to make $f(x,y)$ approach some value $L$ reliably as we approach $(0,0)$, we will probably be done. Looking at the graph of this function, we see that the value of the function appears to approach 0 as $(x,y)$ approaches $(0,0)$. We saw the graph in class. It looks like this:

Thus, it appears that the value of the function is approaching zero near the origin. So, let’s work under the assumption that maybe $L=0$. How much different is $f(x,y)$ from $L$? Well, if we can bound the difference between them and show that this difference goes to zero the closer we get to the origin, we’ll be done. Here’s a convincing argument that seemingly comes out of nowhere: If $L=0$ then
$|f(x,y)-L|=|f(x,y)|=\left|\frac{x^2y}{x^2+y^2}\right|=\left|\frac{x^2}{x^2+y^2}\right||y|\le|y|\le\sqrt{x^2+y^2}.$
If you have questions on this identity, please ask. It’s not at all immediately obvious. (Half of advanced math is full of identities like this. They look completely awkward until you udnerstand them.) But, it does limit the difference between the value of the function and the value of $L$ as we get closer to the origin. (Specifically, it shows that the difference between $f(x,y)$ and $L$ is always bounded above by the Euclidean distance from $(0,0)$ to $(x,y)$. Thus, the limit exists and is equal to zero.

Example 2: The function $g(x,y)=\displaystyle\frac{x^2}{x^2+y^2}$ is also clearly not continuous at the origin (since it is not defined there). Does the function have a limit that exists at the origin?

Solution: If we approach the point $(0,0)$ along the $x$-axis, where $y=0$, and make sure to consider only $x$ values that are nonzero (the function is not defined at the origin) then we find that the function always has the value
$g(x,0)=\frac{x^2}{x^2+0}=\frac{x^2}{x^2}=1.$
On the other hand, if we approach the origin along the $y$-axis, where $x=0$, and again make sure to only consider points where $y\neq 0$, then we always have
$g(0,y)=\frac{0}{0+y^2}=0.$
This is a problem, since we can approach the origin along two different paths (either axes in this case) and have the function approach a different value along each path. Thus, the limit does not exist at the origin.

Example 3: Does the limit $\displaystyle\lim_{(x,y)\to(0,0)}\frac{x+y}{x-y}$ exist?

Solution: As before, the best way to show that a limit doesn’t exist is generally to approach the point in question along various paths. If one approaches the origin along the $x$-axis, then we always have
$\frac{x+y}{x-y}=\frac{x}{x}=1.$
If however, one decides to approach along the line $y=2x$, then we would always have
$\frac{x+y}{x-y}=\frac{x+2x}{x-2x}=\frac{3x}{-x}=-3.$
Thus, the limit does not exist.

Sections 12.1 – 12.4

Print version: 12-1-through-12-4.pdf

This document is largely a collection of random notes, most of which you should have seen before in some manner. If you have questions on any of this material, do not hesitate to ask.

Equation of a Sphere

A sphere is simply a collection of points equadistant from a given point. Thus, it makes sense that its algebraic definition is given by using the Pythagorean theorem. In 2-space, we have

$(x-a)^2+(y-b)^2=r^2 \qquad\text{or}\qquad \sqrt{(x-a)^2+(y-b)^2}=r,$

where $r$ is the radius of the sphere and the sphere is centered at $(a,b)$ in the $xy$-plane. In 3-space, this becomes

$(x-a)^2+(y-b)^2+(z-c)^2=r^2.$

Increasing/Decreasing Functions

Just as in calc 1, we have the notion of an increasing or decreasing funciton with respect to a given variable. For instance, if I consider the function $PV(n,T)=nRT$, where the function is named “$PV$” with input variables $n$ and $T$, then we see that increases in both $n$ and $T$ will lead to an increase in the function’s value.

If, however, we now consider the fucntion $P(n,T,V)=nRT/V$, then this 3-variable function is increasing in $n$ and $T$, but decreasing in $V$.

Definition of Parallel

You’ve heard of parallel in the context of lines. Parallel simply means “do not touch’” or “do not intersect.” (This definition works well in every geometric system, be it Euclidean or hyperbolic or whatever.) Thus, two planes that are parallel are planes that do not touch. In Euclidean space, being parallel is equivalent to having the same slope with respect to any coordinate axis. (This is equivalent again to the angle sum of a triangle being 180 degrees, and neither of these are true in hyperbolic geometry.) As luck would have it, this course will only use Euclidean space.

Crossing Contour Lines

Contour lines can cross. As an example, consider the function $f(x,y)=\sin x+\cos y$. The contour plot is given below. Notice that when contour lines cross, they must represent the same level set.

The Equation of a Plane

Most of our early problems in finding the equation of a plane boil down to the following sort of problem. I’ll explain afterwards how this basic example can be modified.

Problem: Find the equation of a plane through the three points

$(0,0,1),\ (0,1,2),\ \text{and}\ (1,1,4).$

Solution: A plane is a linear equation, and hence has slopes (potentially in many variables), where the slopes are constant throughout the entire surface in each variable. Thus, what this really amounts to is finding the slopes, finding a point on the plane, and using the point-slope formula to find the equation we desire. (This is exactly what you do when forming the equation of a line from a point and slope. A line is a plane in one variable, afterall.)

Notice that the first two points have the same $x$-coordinate. As we increment $y$ from 0 to 1 on these points, the value of $z$ changes from 1 to 2. So, we have the ratio $\Delta z/\Delta y=1/1=1$. What we are doing here is viewing $z$ as the dependent variable and $x$ and $y$ as the independent variables. (The situation could be changed, but this view of $z$ is fairly standard in 3-space.) Likewise, using the second and third points, we find $\Delta z/\Delta x=2$. Using the point-slope form we then have

$z-z_1=\frac{\Delta z}{\Delta x}(x-x_1)+\frac{\Delta z}{\Delta y}(y-y_1)$

or

$z=\frac{\Delta z}{\Delta x}(x-x_1)+\frac{\Delta z}{\Delta y}(y-y_1)+z_1.$

We may use any of the points given as $(x_1,y_1,z_1)$. They will all yield the same equation for the plane. The easiest one will probably be $(0,0,1)$, and so we find that

$z=2x+1y+1=2x+y+1.$

You can double-check this by verifying that the points in question do indeed satisfy this equation.

\bigbreak The only way to make this more challenging is to ask the question differently. You could, for instance, consider a line and a point not on that line in 3-space. These would also give you a plane. In order to form that plane’s equation, you’d need to come up with two points on the line, and now you’re back to the same situation as in this problem. Most of our early plane equation problems take this form in some way, although it may not be obvious at first how.