CHAPTER 12 - Multivariable Functions and Partial Derivatives

Section 12.1, page 914

Problem 5

The domain of the function xy is all pairs of real numbers, so we'll just draw the level curves.

>   with(plots,contourplot):

>   contourplot(x*y,x=-4..4,y=-4..4,contours=[-10,-8,-6,-4,-2,0,2,4,6,8,10],color=blue,thickness=2);

[Maple Plot]

Here's the actual surface, with the contours on it:

>   plot3d(x*y,x=-4..4,y=-4..4,style=patchcontour);

[Maple Plot]

(see the Math 104 solved problems for more from this section)

Section 12.2, page 921

Problem 16

We'll do what it says -- simplify first, then take the limit:

>   simplify((y+4)/(x^2*y-x*y+4*x^2-4*x));

1/((x-1)*x)

Clearly this expression is ok as x approaches 2 and y approaches -4:

>   subs(x=2,y=-4,%);

1/2

This is the limit.

Problem 35

We'll show that taking the limit in x first then y is different from y first then x:

>   f:=-x/sqrt(x^2+y^2);

f := -x/(x^2+y^2)^(1/2)

>   limit(limit(f,x=0),y=0);

0

>   limit(limit(f,y=0),x=0);

undefined

>   limit(limit(f,y=0),x=0,right);

-1

(see the Math 104 solved problems for more from this section)

Section 12.3, page 931

Problem 57

If we're going to find diff(z,x) then we must be thinking of z as a function of x and y:

>   eqn:=x*y+z(x,y)^3*x-2*y*z(x,y)=0;

eqn := x*y+z(x,y)^3*x-2*y*z(x,y) = 0

>   solve(diff(eqn,x),diff(z(x,y),x));

-(y+z(x,y)^3)/(3*z(x,y)^2*x-2*y)

and at (1,1,1):

>   subs(x=1,y=1,z(1,1)=1,%);

-2

>   restart;

Problem 65

>   f:=exp(-2*y)*cos(2*x);

f := exp(-2*y)*cos(2*x)

>   simplify(diff(f,x$2)+diff(f,y$2)+diff(f,z$2));

0

(see the Math 104 solved problems for more from this section)

Section 12.4, page 942

Problem 20

We'll be thinking of R as a function of R1 and R2:

>   eqn:=1/R(R1,R2)=1/R1+1/R2;

eqn := 1/R(R1,R2) = 1/R1+1/R2

>   Rx:=solve(diff(eqn,R1),diff(R(R1,R2),R1));

Rx := R(R1,R2)^2/R1^2

>   Ry:=solve(diff(eqn,R2),diff(R(R1,R2),R2));

Ry := R(R1,R2)^2/R2^2

>   dR:=Rx*dR1+Ry*dR2;

dR := R(R1,R2)^2/R1^2*dR1+R(R1,R2)^2/R2^2*dR2

This is part (a). For part (b), we have numbers:

>   solve(subs(R1=100,R2=400,eqn),R(100,400));

80

>   subs(R1=100,R2=400,R(100,400)=80,dR);

16/25*dR1+1/25*dR2

So the resistance R is more sensitive to variations in R1, because the derivative of R with respect to R1 is bigger.

Section 12.5, page 950

Problem 40

We'll write expressions for volume, surface area and diagonal in terms of a(t), b(t) and c(t):

>   vol:=a(t)*b(t)*c(t); surf:=2*a(t)*b(t)+2*a(t)*c(t)+2*b(t)*c(t); diag:=sqrt(a(t)^2+b(t)^2+c(t)^2);

vol := a(t)*b(t)*c(t)

surf := 2*a(t)*b(t)+2*a(t)*c(t)+2*b(t)*c(t)

diag := (a(t)^2+b(t)^2+c(t)^2)^(1/2)

>   subs(diff(a(t),t)=1,diff(b(t),t)=1,diff(c(t),t)=-3,a(t)=1,b(t)=2,c(t)=3,diff(vol,t));

3

Volume is increasing at 3 cubic meters per second

>   subs(diff(a(t),t)=1,diff(b(t),t)=1,diff(c(t),t)=-3,a(t)=1,b(t)=2,c(t)=3,diff(surf,t));

0

Surface area isn't changing at that particular moment.

>   subs(diff(a(t),t)=1,diff(b(t),t)=1,diff(c(t),t)=-3,a(t)=1,b(t)=2,c(t)=3,diff(diag,t));

-3/7*14^(1/2)

So the diagonals are getting smaller.

Section 12.7, page 967

Problem 18

>   f:=x^2*y+exp(x*y)*sin(y);

f := x^2*y+exp(x*y)*sin(y)

>   simplify(subs(x=1,y=0,[diff(f,x),diff(f,y)]));

[0, 2]

OK - so the direction of fastest increase at this point is just in the y-direction. And the (directional) derivative in this direction is just the partial with respect to y:

>   simplify(subs(x=1,y=0,diff(f,y)));

2

Problem 31

>   eqn:=cos(Pi*x)-x^2*y+exp(x*z)+y*z=4;

eqn := cos(Pi*x)-x^2*y+exp(x*z)+y*z = 4

The normal vector is just the gradient of the left side:

>   nvec:=simplify(subs(x=0,y=1,z=2,[diff(lhs(eqn),x),diff(lhs(eqn),y),diff(lhs(eqn),z)]));

nvec := [2, 2, 1]

So the equation of the tangent plane is:

>   2*x+2*y+z=subs(x=0,y=1,z=2,2*x+2*y+z);

2*x+2*y+z = 4

And parametric equations for the normal line are:

>   x=0+2*t, y=1+2*t, z=2+t;

x = 2*t, y = 1+2*t, z = 2+t

Section 12.8, page 975

Problem 36

First we look for interior critical points:

>   T:=48*x*y-32*x^3-24*y^2;

T := 48*x*y-32*x^3-24*y^2

>   crits:=solve({diff(T,x)=0,diff(T,y)=0},{x,y});

crits := {x = 0, y = 0}, {x = 1/2, y = 1/2}

Only the second one is in the interior, so we only remember that one for later.

Now for the four edges. First, the y=0 edge:

>   crits1:=solve(diff(subs(y=0,T),x)=0,x);

crits1 := 0, 0

The origin is not in the interior of the edge, so we move on to the x=1 edge:

>   crits2:=solve(diff(subs(x=1,T),y)=0,y);

crits2 := 1

The point (1,1) is not in the interior of the edge (it's on a corner), so we move on to the y=1 edge:

>   crits3:=solve(diff(subs(y=1,T),x)=0,x);

crits3 := -1/2*2^(1/2), 1/2*2^(1/2)

The second of these will have to be checked (i.e., the point [sqrt(2)/2, 1]). Finally:

>   crits4:=solve(diff(subs(x=0,T),y)=0,y);

crits4 := 0

OK - we only have one interior point, one edge point and the four corners to check:

>   subs(crits[2],T);

2

>   subs(x=crits3[2],y=1,T);

16*2^(1/2)-24

>   evalf(%);

-1.37258301

>   subs(x=0,y=0,T);

0

>   subs(x=0,y=1,T);

-24

>   subs(x=1,y=1,T);

-8

>   subs(x=1,y=0,T);

-32

We conclude that the absolute max occurs at the interior critical point [1/2,1/2], and the absolute min occurs at the corner [1,0]. We plot to make sure:

>   plot3d(T,x=0..1,y=0..1,style=patchcontour);

[Maple Plot]

Looks like we got it right.

Problem 42

>   f:=x*y+2*x-ln(x^2*y);

f := x*y+2*x-ln(x^2*y)

>   crits:=solve({diff(f,x)=0,diff(f,y)=0},{x,y});

crits := {x = 1/2, y = 2}

>   H:=diff(f,x$2)*diff(f,y$2)-diff(f,x,y)^2;

H := 2/x^2/y^2-1

>   subs(crits,H);

1

>   subs(crits,diff(x$2));

1

Since the discriminant is positive and the second derivative with respect to x is positive, the function has a local minimum at (1/2,2). Also note that when x and y approach zero, the log of x^2*y goes to -infinity, so the function f goes to +infinity. And as x and y grow the function also gets big. So our point must be the global min.

Section 12.9, page 987

Problem 46

>   f:=x*y*z; g1:=x^2+y^2-1; g2:=x-z;

f := x*y*z

g1 := x^2+y^2-1

g2 := x-z

>   F:=f-lambda*g1-mu*g2;

F := x*y*z-lambda*(x^2+y^2-1)-mu*(x-z)

>   crits:=solve({diff(F,x)=0,diff(F,y)=0,diff(F,z)=0,diff(F,lambda)=0,diff(F,mu)=0},{x,y,z,mu,lambda});

crits := {x = 0, y = 1, lambda = 0, mu = 0, z = 0}, {x = 0, lambda = 0, y = -1, mu = 0, z = 0}, {y = RootOf(3*_Z^2-1), x = RootOf(3*_Z^2-2), lambda = RootOf(3*_Z^2-1), mu = -RootOf(3*_Z^2-2)*RootOf(3*_...
crits := {x = 0, y = 1, lambda = 0, mu = 0, z = 0}, {x = 0, lambda = 0, y = -1, mu = 0, z = 0}, {y = RootOf(3*_Z^2-1), x = RootOf(3*_Z^2-2), lambda = RootOf(3*_Z^2-1), mu = -RootOf(3*_Z^2-2)*RootOf(3*_...
crits := {x = 0, y = 1, lambda = 0, mu = 0, z = 0}, {x = 0, lambda = 0, y = -1, mu = 0, z = 0}, {y = RootOf(3*_Z^2-1), x = RootOf(3*_Z^2-2), lambda = RootOf(3*_Z^2-1), mu = -RootOf(3*_Z^2-2)*RootOf(3*_...

>   subs(crits[1],f);

0

>   subs(crits[2],f);

0

>   c3:=allvalues(crits[3]);

c3 := {x = 1/3*6^(1/2), z = 1/3*6^(1/2), y = 1/3*3^(1/2), lambda = 1/3*3^(1/2), mu = -1/9*6^(1/2)*3^(1/2)}, {mu = 1/9*6^(1/2)*3^(1/2), x = 1/3*6^(1/2), z = 1/3*6^(1/2), y = -1/3*3^(1/2), lambda = -1/3*...
c3 := {x = 1/3*6^(1/2), z = 1/3*6^(1/2), y = 1/3*3^(1/2), lambda = 1/3*3^(1/2), mu = -1/9*6^(1/2)*3^(1/2)}, {mu = 1/9*6^(1/2)*3^(1/2), x = 1/3*6^(1/2), z = 1/3*6^(1/2), y = -1/3*3^(1/2), lambda = -1/3*...
c3 := {x = 1/3*6^(1/2), z = 1/3*6^(1/2), y = 1/3*3^(1/2), lambda = 1/3*3^(1/2), mu = -1/9*6^(1/2)*3^(1/2)}, {mu = 1/9*6^(1/2)*3^(1/2), x = 1/3*6^(1/2), z = 1/3*6^(1/2), y = -1/3*3^(1/2), lambda = -1/3*...
c3 := {x = 1/3*6^(1/2), z = 1/3*6^(1/2), y = 1/3*3^(1/2), lambda = 1/3*3^(1/2), mu = -1/9*6^(1/2)*3^(1/2)}, {mu = 1/9*6^(1/2)*3^(1/2), x = 1/3*6^(1/2), z = 1/3*6^(1/2), y = -1/3*3^(1/2), lambda = -1/3*...

>   subs(c3[1],[f,g1,g2]);

[2/9*3^(1/2), 0, 0]

>   subs(c3[2],[f,g1,g2]);

[-2/9*3^(1/2), 0, 0]

>   subs(c3[3],[f,g1,g2]);

[2/9*3^(1/2), 0, 0]

>   subs(c3[4],[f,g1,g2]);

[-2/9*3^(1/2), 0, 0]

So the max and min of our function are + and - 2*sqrt(3)/9, and these occur at [sqrt(6)/3,sqrt(3)/3,sqrt(6)/3] and points obtained by negating y or both x and z (independently, so there are 4 choices).