14.1: Functions of Several Variables #

Problem 13: Find and sketch the domain of the function,

$$ f(x,y) = \sqrt{x - 2} + \sqrt{y - 1} $$

Each sqrt root cannot go negative, so $x - 2 \geq 0$ and $y - 1 \geq 0$, so the domain in set-builder notation is,

$$ \{ (x, y) \in \R^2 : x \geq 2 \ \text{and,} \ y \geq 1 \} $$

You can think of this as the intersection of 2 half planes in the real plane.

Problem 17: Find and sketch the domain of the function,

$$ f(x, y) = \frac{x - y}{x + y} $$

The denominator cannot be zero, i.e. $x + y \neq 0$, which is everything other than the line of slope $-1$ which intersects $0$.

14.2: Limits and Continuity #

Problem 5: Find the limit, if it exists, or show that the limit does not exist.

$$ \lim_{(x, y) \to (3, 2)} (x^2y^3 - 4y^2) $$

Because polynomials are continuous, the limit of a function at a point is equal to the function evaluated at a point,

$$ \lim_{(x, y) \to (3, 2)} (x^2y^3 - 4y^2) = 3^22^3 - 4(2^2) = 72 - 16 = 56 $$

Problem 9: Find the limit, if it exists, or show that the limit does not exist.

$$ \lim_{(x, y) \to (0, 0)} \frac{x^4 - 4y^2}{x^2 + 2y^2} $$

Lets see if the function agrees on the two axis, to do this we set one variable to $0$ and evaluate the limit for the other variable. For the $x$-axis, we set $y = 0$,

$$ \lim_{x \to 0} \frac{x^4 - 4(0^2)}{x^2 + 2(0^2)} = \lim_{x \to 0} x^2 = 0 $$

For the $y$-axis we set $x = 0$,

$$ \lim_{y \to 0} \frac{(0^4) - 4y^2}{0^2 + 2y^2} = \lim_{y \to 0} -2 = -2 $$

Since these two values disagree the function cannot be continuous at $0$.

A more technical reason is that for all small areas around $0$, the function will always have values very near to $0$, and it will always have values near $-2$, no matter how small we shrink our area around $0$. Try graphing this function and look at its behavior around zero!

Problem 13: Find the limit, if it exists, or show that the limit does not exist.

$$ \lim_{(x, y) \to (0, 0)} \frac{xy}{\sqrt{x^2 + y^2}} $$

Trying the parametrized lines $(x,y) = (t, t)$ and $(x,y) = (t, -t)$ will give us different answers for the limit, meaning that the limit does not exist. First we evaluate these two functions on the lines given,

$$ \frac{xy}{x^2 + y^2} = \frac{t^2}{2t^2} $$

and,

$$ \frac{xy}{x^2 + y^2} = \frac{-t^2}{2t^2} $$

So sending $t \to 0$ for these lines gives us,

$$ \lim_{t \to 0} \frac{t^2}{2t^2} = \lim_{t \to 0} \frac{1}{2} = \frac{1}{2} $$

and,

$$ \lim_{t \to 0} \frac{-t^2}{2t^2} = \lim_{t \to 0} -\frac{1}{2} = -\frac{1}{2} $$

Thus the limit does not exist.

Problem 31: Determine the set of points where the following functions are continuous,

$$ (x, y) = \frac{1 + x^2 + y^2}{1 - x^2 - y^2} $$

We may convert this to polar coordinates, as the function is circular, in other words when we do the conversion the function is independent of the angle. Lets show this, let $(x, y) = (r\cos(\theta), r\sin(\theta))$, then,

$$ \frac{1 + x^2 + y^2}{1 - x^2 - y^2} = \frac{1 + (r\cos(\theta))^2 + (r\sin(\theta))^2}{1 - (r\cos(\theta))^2 - (r\sin(\theta))^2} = \frac{1 + r^2(\cos^2(\theta) + \sin^2(\theta))}{1 - r^2(\cos^2(\theta) + \sin^2(\theta))} = \frac{1 + r^2}{1 - r^2} $$

This limit blows up when the radius is 1, so it is not continuous at the circle of radius one centered at 0. Otherwise since at all other points the function is the ratio of 2 polynomials, which are continuous everywhere, we are done.

14.3: Partial Derivatives #

Problem 19: Find the first partial derivatives of the following function,

$$ z = \ln(x + t^2) $$

The first partial derivative of $z$ with respect to $x$ is,

$$ \frac{\partial}{\partial x} \ln(x + t^2) = \frac{1}{x + t^2} \frac{\partial}{\partial x}(x + t^2) = \frac{1}{x + t^2} $$

Similarly for $t$, we have,

$$ \frac{\partial}{\partial t} \ln(x + t^2) = \frac{1}{x + t^2} \frac{\partial}{\partial t}(x + t^2) = \frac{2t}{x + t^2} $$

Problem 59: Verify that the conclusion of Clairaut’s Theorem holds, that is, $u_{xy} = u_{yx}$, for

$$ u = x^4y^3 - y^4 $$

Lets do both mix partial derivatives,

$$ u_{xy} = \frac{\partial}{\partial y} \frac{\partial}{\partial x} x^4y^3 - y^4 = \frac{\partial}{\partial y} 4x^3y^3 = 12x^3y^2 $$

and,

$$ u_{yx} = \frac{\partial}{\partial x} \frac{\partial}{\partial y} x^4y^3 - y^4 = \frac{\partial}{\partial x} 3x^4y^2 - 4y^3 = 12x^3y^2 $$

This follows from Clairaut’s Theorem because both $12x^3y^2$ and $12x^3y^2$ are both continuous.

14.4: Tangent Planes and Linear Approximations #

Problem 1: Find an equation of the tangent plane to the given surface at the given point,

$$ f(x, y) = 2x^2 + y^2 - 5y, \ (1, 2, -4) $$

Finding the partial derivatives give us the slope of the tangent plane on their respective axes, i.e. the partial derivative on the $x$-axis, gives us the slope of the line of the plane when restricted to the $x$-axis. The corresponding tangent lines are,

$$ z - z_0 = f_x(x_0, y_0)(x - x_0) $$

and,

$$ z - z_0 = f_y(x_0, y_0)(y - y_0) $$

so the associated plane to the lines is,

$$ z - z_0 = f_x(x_0, y_0)(x - x_0) + f_y(x_0, y_0)(y - y_0) $$

So for our problem, we have the following tangent plane.

$$ z + 4 = f_x(1, 2)(x - 1) + f_y(1, 2)(y - 2) = 4(x - 1) - (y - 2) - 4 $$

Note that this also shows that the normal vector for the tangent plane of a differentiable function is $(f_x(x_0, y_0), f_y(x_0, y_0), -1)$, note later how similar this is to gradient later. Here is a Desmos graph to demonstrate this problem.

Problem 11: Explain why the function is differentiable at the given point. Then find the linearization $L(x, y)$ of the function at that point.

$$ f(x, y) = 1 + x \ln(xy - 5), \ (2, 3) $$

It is differentiable as $xy - 5$ at $(2, 3)$ is greater than $0$. The linearization is a plug and play formula, first we calculate $f_x$ and $f_y$,

$$ f_x = \ln(xy - 5) + \frac{y}{xy - 5} $$

and,

$$ f_y = x\frac{x}{xy - 5} $$

Thus,

$$ L(x, y) = f_x(2, 3)(x - 2) + f_y(2, 3)(y - 3) + f(2, 3) = 3(x - 2) + 4(y - 3) + 1 $$

14.5: The Chain Rule #

Problem 1: Use the Chain Rule to find $dz/dt$,

$$ z = xy^3 - x^2y, \ x = t^2 + 1, \ y = t^2 - 1 $$

We will do this first with brute force, and then we will show that the chain rule gives the same result,

$$ \frac{dz}{dt} = \frac{d}{dt}(xy^3 - x^2y) = \frac{d}{dt}(xy^3) - \frac{d}{dt}(x^2y) = \frac{dx}{dt}y^3 + xy^2\frac{dy}{dt} - \left(2x\frac{dx}{dt}y + x^2\frac{dy}{dt}\right) \newline = \frac{dx}{dt}(y^3 - 2xy) + \frac{dy}{dt}(xy^2 - x^2) $$

The chain rule allows us to skip much of this computation, as,

$$ \frac{dz}{dt} = \frac{\partial z}{\partial x}\frac{dx}{dt} + \frac{\partial z}{\partial y}\frac{dy}{dt} $$

so for us,

$$ \frac{dz}{dt} = (y^3 - 2xy)\frac{dx}{dt} + (xy^2 - x^2)\frac{dy}{dt} $$

To finalize both computations, we need to find $dx/dt$ and $dy/dt$ which are:

$$ \frac{dx}{dt} = \frac{d}{dt}(t^2 + 1) = 2t $$

and,

$$ \frac{dy}{dt} = \frac{d}{dt}(t^2 - 1) = 2t $$

Problem 13: Let $p(t) = f(g(t), h(t))$, where $f$ is differentiable, $g(2) = 4$, $g^\prime(2) = -3$, $h(2) = 5$, $h^\prime(2) = 6$, $f_x(4, 5) = 2$, $f_y(4, 5) = 8$. Find $p^\prime(2)$.

Using the chain rule we know that,

$$ p^\prime(t) = \frac{\partial f(g(t), h(t))}{\partial g(t)} g^\prime(t) + \frac{\partial f(g(t), h(t))}{\partial h(t)}h^\prime(t) $$

$$ = f_x(g(t), h(t))g^\prime(t) + f_y(g(t), h(t))h^\prime(t) $$

thus,

$$ p^\prime(2) = f_x(g(2), h(2))g^\prime(2) + f_y(g(2), h(2))h^\prime(2) = f_x(4, 5)(-3) + f_y(4, 5)6 $$

$$ = 2(-3) + 8 \cdot 6 = 42 $$

Problem 27: Use following equation

$$ \frac{dy}{dx} = -\frac{F_x}{F_y} $$

to find $dy/dx$, by rearranging $y \cos(x) = x^2 + y^2$ into the form $F(x, y) = 0$.

First we rearrange our equation to the form we want, $y \cos(x) - x^2 - y^2 = 0$, then we can find the partials of the equation,

$$ F_x(x, y) = -y \sin(x) - 2x $$

and,

$$ F_y(x, y) = \cos(x) - 2y $$

Thus,

$$ \frac{dy}{dx} = -\frac{-y \sin(x) - 2x}{\cos(x) - 2y} $$

14.6: Directional Derivatives and the Gradient Vector #

Problem 7: Find the gradient of $f$, and evaluate the gradient at the given point, $P$. Additionally, find the rate of change at $f$ at $P$ in the direction of the vector $u$.

$(a) \ f(x, y) = x/y, \ P = (2, 1), \ u = 3/5 i + 4/5 j$

$(b) \ f(x, y, z) = x^2yz - xyz^3, \ P = (2, -1, 1), \ u = (0, 4/5, -3/5)$

Both of these problems are very computational, it amounts to finding the partial derivatives for each term, so for $(a)$,

$$ \nabla f(x, y) = (f_x(x, y), f_y(x, y)) = (1 / y, -x/y^2) $$

for $(b)$ we have,

$$ \nabla f(x, y, z) = (f_x(x, y, z), f_y(x, y, z), f_z(x, y, z)) = (2xyz - yz^3, x^2z - xz^3, x^2y - 3xyz^2) $$

The rate of change at a point of a direction is the directional derivative. For such a point $P$ and direction $u$ we have, $D_u(f)(P) = (\nabla f(P)) \cdot u$ which relates the gradient and the directional derivative. So for $(a)$ we have,

$$ D_{3/5 i + 4/5 j}(f)(2, 1) = (\nabla f(2, 1)) \cdot (3/5 i + 4/5 j) = (1, -2) \cdot (3/5 i + 4/5 j) = -1 $$

for $(b)$ we have,

$$ D_{(0, 4/5, -3/5)}(f)(2, -1, 1) = (\nabla f(2, -1, 1)) \cdot (0, 4/5, -3/5) $$

$$ = (-3, 2, 2) \cdot (0, 4/5, -3/5) = 2/5 $$

Problem 11: Find the directional derivative of $f(x, y) = e^x \sin(y)$ at the point $(0, \pi/3)$ in the direction of the vector $(-6, 8)$.

Again we compute the gradient,

$$ \nabla f(x, y) = (e^x \sin(y), e^x \cos(y)) $$

first we must make the direction vector a unit, which is $(-6, 8)/\sqrt{100} = (-3/5, 4/5)$ then we have,

$$ D_{(-3/5, 4/5)}(f)(0, \pi/3) = (\nabla f(0, \pi/3)) \cdot (-3/5, 4/5) $$

$$ = (\sqrt{2}/2, 1/2) \cdot (-3/5, 4/5) = -\frac{3\sqrt{2}}{10} + \frac{4}{10} $$

Problem 41: Using the gradient, find equations of the tangent plane and the normal line to the given surface $2(x - 2)^2 + (y - 1)^2 + (z - 3)^2 = 10$ at the specified point $(3, 3, 5)$.

The gradient is the normal vector of the level surface that corresponds to that point, so if we interpret

$$ F(x, y, z) = 2(x - 2)^2 + (y - 1)^2 + (z - 3)^2 $$

as a function, we then look at the level surface $F(x, y, z) = 10$, thus we may look at the gradient at $P$, to get the normal vector we are interested in,

$$ \nabla F(x, y, z) = (4x - 8, 2y - 2, 2z - 6) $$

Thus $\nabla F(P) = (4, 4, 4)$, and our tangent plane centered at $P$ is,

$$ 0 = 4(x - 3) + 4(y - 3) + 4(z - 5) $$

and our normal line is,

$$ \ell(t) = t(4, 4, 4) + (3, 3, 5) = (4t + 3, 4t + 3, 4t + 5) $$

Problem 49: If $f(x, y) = xy$, find the gradient vector $\nabla f(3, 2)$ and use it to find the tangent line to the level curve $f(x, y) = 6$ at the point $(3, 2)$. Sketch the level curve, the tangent line, and the gradient vector.

Look at this Desmos graph for this problem. Note how as the level curves get closer, the steeper the drop is, and note how the gradient grows in size the steeper it gets.

14.7: Maximum and Minimum Values #

Problem 5: Find the local maximum and minimum values and saddle point(s) of the function $f(x, y) = x^2 + xy + y^2 + y$.

We find critical points where both partial derivatives are $0$, so we set $f_x(x, y) = 2x + y$ and $f_y(x, y) = x + 2y + 1$ to zero and we get the equations $y = -2x$ and $y = -1/2x - 1/2$. By substituting $y$ we get $-2x = -1/2x - 1/2$ and subsequently we get $x = 1/3$, thus $y = -2/3$ and our only critical point is $(1/3, -2/3)$. Via the second derivative test since both second partial derivatives are positive, we have a minima.

Problem 21: Show that $f(x, y) = x^2 + 4y^2 - 4xy + 2$ has an infinite number of critical points and that $D = 0$ at each one. Then show that $f$ has a local (and absolute) minimum at each critical point.

Lets look at both partial derivatives,

$$ f_x(x, y) = 2x - 4y $$

and,

$$ f_x(x, y) = 2y - 4x $$

Note that if we used linear algebra to solve this we would find that this has infinite solutions as $f_x(x, y) = -2f_y(x, y)$, thus all points on the line $(2t, t)$ are critical points. The second derivative test tells us that they are all minima.

Problem 47: Find the maximum volume of a rectangular box that is inscribed in a sphere of radius $r$ centered at zero.

Note that since rotation does not affect the volume of a solid, we may assume that the box is aligned with the axes, and thus choosing one point on the sphere forces the rest of the volume to be defined as we reflect across each octant, so the volume of a rectangular box that is inscribed in a sphere at a point $(x, y, z)$ is $|8xyz|$ as each side is twice as long as the specified point because of reflection. Changing this to spherical coordinates,

$$ (x, y, z) = (r\sin(\theta)\cos(\varphi), r\sin(\theta)\sin(\varphi), r\cos(\theta)) $$

we get

$$ \text{Vol}(\theta, \varphi) = |8r^3\sin(\theta)\cos(\varphi)\sin(\theta)\sin(\varphi)\cos(\theta)| $$

$$ = |8r^3||\sin^2(\theta)\cos(\theta)\cos(\varphi)\sin(\varphi)| $$

Noting that $|8r^3|$ stays constant we may ignore it, we may also remove the absolute values because we can consider one octant. Taking the partials gives us,

$$ \text{Vol}_\varphi(\theta, \varphi) = \sin^2(\theta)\cos(\theta) \frac{\partial}{\partial \varphi}(\cos(\varphi)\sin(\varphi)) $$

$$ = \sin^2(\theta)\cos(\theta) (\cos^2(\varphi) - \sin^2(\varphi)) $$

Setting $\cos^2(\varphi) = \sin^2(\varphi)$ gives us $\varphi = \pi/4$. The other partial gives us,

$$ \text{Vol}_\theta(\theta, \varphi) = \cos(\varphi)\sin(\varphi) \frac{\partial}{\partial \theta}(\sin^2(\theta)\cos(\theta)) $$

$$ = \cos(\varphi)\sin(\varphi) (2\sin(\theta)\cos^2(\theta) - \sin^3(\theta)) $$

Setting $2\sin(\theta)\cos^2(\theta) = \sin^3(\theta)$ turns into

$$ 2\cos^2(\theta) = \sin^2(\theta) = 1 - \cos^2(\theta) $$

and

$$ 2 - 2sin^2(\theta) = 2\cos^2(\theta) = \sin^2(\theta) $$

then we have

$$ \cos^2(\theta) = \frac{1}{3} $$

and

$$ \sin^2(\theta) = \frac{2}{3} $$

thus $\cos(\theta) = \sqrt{3}/3$ and $\sin(\theta) = \sqrt{6}/3$ are our solution. Plugging this back in gives us our final coordinates,

$$ (x, y, z) = r\left(\frac{\sqrt3}{3}, \frac{\sqrt3}{3}, \frac{\sqrt3}{3}\right) $$

which is the inscribed cube!

14.8: Lagrange Multipliers #

Problem 3: Use Lagrange multipliers to find the extreme values of the function $f(x, y) = x^2 - y^2$ subject to the given constraint $x^2 + y^2 = 1$.

We need to find solutions $x, y,$ and $\lambda$ such that $\nabla f(x, y) = \lambda \nabla g(x, y)$ and where the constraint still holds. So we first find solutions for the equations $2x = \lambda 2x$, $-2y = \lambda 2y$, which gives us the equations $x(2 - 2\lambda) = 0$ and $y(2 + 2\lambda) = 0$. Note that no one $\lambda$ can solve both equations, and that both $x$ and $y$ cannot be zero as it would fail the constraint. So we first set $x = 0$, then since $y$ must be non-zero, $2 + 2\lambda = 0$, thus $\lambda = -1$. Then $y$ must be $\pm 1$ as $0^2 + y^2 = 1$. For similar reasons when we set $y = 0$ we get that $\lambda = 1$ and that $x = \pm 1$.

Now when we test these values we get, $f(\pm 1, 0) = 1$ and $f(0, \pm 1) = -1$, thus $(\pm 1, 0)$ are the maxima, and $(0, \pm 1)$ are the minima.