Chapter 46. Solutions to Part Echo

§46.1 Solution to Exercise 13.1 (five level curve drawings)

Exercise 13.1. Draw 2D level curves for some values for the following functions:

In what follows, 𝑐 always denotes the value we’re drawing the level curve for.

For 𝑓(𝑥,𝑦)=32𝑥+𝑦

The level curves of 32𝑥+𝑦 will be straight lines with slope −32 whose 𝑦-intercept is the point (0,𝑐). See Figure 102.

For 𝑓(𝑥,𝑦)=𝑥𝑦

When 𝑐≠0, the shape of 𝑥𝑦=𝑐 is a hyperbola 𝑦=𝑐𝑥. For the exceptional value 𝑐=0, the shape 𝑥𝑦=0 is the union of the axes. See Figure 103.

For 𝑓(𝑥,𝑦)=sin(𝑥2+𝑦2)

The level curve is only nonempty when −1≤𝑐≤1. For these 𝑐, we obtain a bunch of concentric circles whose radii 𝑟 satisfy sin(𝑟2)=𝑐. For example, when 𝑐=0, we get circles of radius 0, 𝜋, 2𝜋, and so on. See Figure 104.

For 𝑓(𝑥,𝑦)=𝑒𝑦−𝑥2

The level curve is only nonempty when 𝑐>0. The level curve is the parabola 𝑦=𝑥2+log(𝑐). See Figure 105.

For 𝑓(𝑥,𝑦)=max(𝑥,𝑦)

The curve consists of what look like rotated L-shapes, as shown in the figure. See Figure 106.

Figure 102: Level curves of 𝑓(𝑥,𝑦)=32𝑥+𝑦

Figure 103: Level curves of 𝑓(𝑥,𝑦)=𝑥𝑦

Figure 104: Level curves of 𝑓(𝑥,𝑦)=sin(𝑥2+𝑦2)

Figure 105: Level curves of 𝑓(𝑥,𝑦)=𝑒𝑦−𝑥2

Figure 106: Level curves of 𝑓(𝑥,𝑦)=max(𝑥,𝑦)

§46.2 Solution to Exercise 13.2 (level curve with seven points)

Exercise 13.2 (*). Give an example of a polynomial function 𝑓(𝑥,𝑦) for which the level curve for the value 100 consists of exactly seven points.

This is quite tricky. The following function should work:

𝑓(𝑥,𝑦)=100+(𝑥2+(𝑦−1)2)(𝑥2+(𝑦−2)2)…(𝑥2+(𝑦−7)2).

Then 𝑓=100 if and only if the product of the seven quadratics we gave was zero, i.e. we have 𝑥2+(𝑦−𝑘)2=0 for some 𝑘=1,…,7. But that can only happen when (𝑥,𝑦)=(0,𝑘).

In other words, this level curve for 100 consists of only seven points: (0,1), (0,2), (0,3), (0,4), (0,5), (0,6), and (0,7).

§46.3 Solution to Exercise 14.1 (partial derivative practice)

Exercise 14.1. Compute all the partial derivatives of the following functions, defined for 𝑥,𝑦,𝑧>0:

This is direct calculation and doesn’t require any trick.

§46.4 Solution to Exercise 15.1 (tangent to sphere)

Exercise 15.1. Compute the equation of the tangent plane to the sphere 𝑥2+𝑦2+𝑧2=14 at the point (1,2,3).

The equation of the given sphere is:

𝑥2+𝑦2+𝑧2=14.

To find the equation of the tangent plane at the point (1,2,3), we first compute the gradient of the function

𝐹(𝑥,𝑦,𝑧)=𝑥2+𝑦2+𝑧2−14.

The gradient is:

∇𝐹=⟨2𝑥,2𝑦,2𝑧⟩.

Evaluating at (1,2,3):

∇𝐹(1,2,3)=⟨2,4,6⟩.

Hence the tangent plane should be given by

2𝑥+4𝑦+6𝑧=𝑐

for some number 𝑐. In order for this to pass through (1,2,3), we take

𝑐=2⋅1+4⋅2+6⋅3=28.

Hence the answer is

2𝑥+4𝑦+6𝑧=28.

Or one could write this as 𝑥+2𝑦+3𝑧=14 if you don’t like the unneeded factor of 2.

§46.5 Solution to Exercise 15.2 (given level curve is a circle)

Exercise 15.2. The level curve of a certain differentiable function 𝑓(𝑥,𝑦) for the value −7 turns out to be a circle of radius 2 centered at (0,0).

Examples of functions

For an example, one natural choice for 𝑓(𝑥,𝑦) is:

𝑓(𝑥,𝑦)=𝑥2+𝑦2−11.

This satisfies:

𝑓(𝑥,𝑦)=−7if and only if𝑥2+𝑦2=4,

which defines a circle of radius 2 centered at the origin. There are other examples, such as

𝑓(𝑥,𝑦)=100(𝑥2+𝑦2)−407

or

𝑓(𝑥,𝑦)=𝑒𝑥2+𝑦2−(𝑒4+7)

and so on.

Possible gradients

For the second part, let 𝑃 denote the point (1.2,−1.6). Then 𝑃 lies on this circle. However, from high school geometry (no calculus involved), the tangent to the circle at 𝑃 is the line 3(𝑥−1.2)−4(𝑦+1.6)=0. (See Figure 107.) The gradient needs to be some perpendicular to this line, so it must be some vector in the direction of (1.2,−1.6). That is, ∇𝑓(1.2,−1.6) could be27 any multiple of (3,−4).

Figure 107: The gradient should be perpendicular to the tangent line (green) to the red circle at 𝑃.

Linear approximation

For the linear approximation step, we have

𝑓(1.208,−1.594)≈𝑓(1.2,−1.6)+(0.008,0.006)⋅∇𝑓(1.2,−1.6).

But the vectors (0.008,0.006) and ∇𝑓(1.2,−1.6) are perpendicular. So the dot product vanishes, and the answer is 𝑓(1.2,−1.6)=−7.

§46.6 Solution to Exercise 15.3 (preview of anti-gradients)

Exercise 15.3. For each part, either give an example of 𝑓:ℝ2→ℝ or show that none exist.

For the first three exercises, one just takes the following:

𝑓1(𝑥,𝑦)=𝑥22+𝑦22𝑓2(𝑥,𝑦)=50𝑥2+𝑦22𝑓3(𝑥,𝑦)=𝑥𝑦.

The fourth task is impossible: no such function could exist. One will see this more clearly in later chapters, but even directly now, one might be able to realize that from 𝑓𝑥=100𝑦 one should have

𝑓(𝑥,𝑦)=100𝑥𝑦+(stuff with only𝑦in it)

and there’s no way one can differentiate that with respect to 𝑦 and get just 𝑥. Again, read Chapter 16 for more details.

§46.7 Solution to Exercise 15.4 (level curve through (0,𝑑))

Exercise 15.4 (*). Let 𝑎, 𝑏, 𝑐, 𝑑 be nonzero real numbers and let

𝑓(𝑥,𝑦)=𝑎𝑒𝑥+𝑦+𝑏𝑒𝑥−𝑦.

Suppose the level curve of 𝑓 for the value 𝑐 is tangent to the line 𝑦=5𝑥 at the origin, and also passes through (0,𝑑). Compute 𝑑.

The gradient of 𝑓 is given by

∇𝑓=(𝑎𝑒𝑥+𝑦+𝑏𝑒𝑥−𝑦𝑎𝑒𝑥+𝑦−𝑏𝑒𝑥−𝑦).

At the origin (𝑥,𝑦)=(0,0) we get

∇𝑓(0,0)=(𝑎+𝑏𝑎−𝑏).

The condition that the level curve is tangent to the line 𝑦=5𝑥 at the origin means the gradient vector ∇𝑓(0,0) must be a multiple of the normal vector to −5𝑥+𝑦=0, which is (−51). In other words, we should have

𝑎+𝑏𝑎−𝑏=−5⟹3𝑎=2𝑏⟹𝑏=32𝑎.

We also know that 𝑐=𝑓(0,0)=𝑓(0,𝑑). We compute

𝑓(0,0)=𝑎𝑒0+0+𝑏𝑒0−0=𝑎+𝑏=𝑎+32𝑎=52𝑎𝑓(0,𝑑)=𝑎𝑒𝑑+𝑏𝑒−𝑑=(𝑒𝑑+32𝑒−𝑑)𝑎.

As 𝑎≠0, we conclude

𝑒𝑑+32𝑒−𝑑=52⟺(𝑒𝑑−1)(𝑒𝑑−32)=0

and so 𝑑=log(32).

§46.8 Solution to Exercise 16.1 (anti-gradient practice)

Exercise 16.1. Suppose 𝑓(𝑥,𝑦) is a differentiable function and that

∇𝑓(𝑥,𝑦)=(𝑥2+𝑎𝑥𝑦+2𝑦2+𝑦+1𝑥2+𝑥+𝑏𝑥𝑦+𝑦2+2)

for some constants 𝑎 and 𝑏. Compute the constants 𝑎 and 𝑏, and determine 𝑓.

We are given the gradient of a function 𝑓(𝑥,𝑦):

∇𝑓(𝑥,𝑦)=(𝑥2+𝑎𝑥𝑦+2𝑦2+𝑦+1𝑥2+𝑥+𝑏𝑥𝑦+𝑦2+2).

To compute 𝑎 and 𝑏, we compute

𝜕𝜕𝑦(𝑥2+𝑎𝑥𝑦+2𝑦2+𝑦+1)=𝑎𝑥+4𝑦+1𝜕𝜕𝑥(𝑥2+𝑥+𝑏𝑥𝑦+𝑦2+2)=2𝑥+1+𝑏𝑦.

These need to be equal for all (𝑥,𝑦) so we require (𝑎,𝑏)=(2,4).

To recover 𝑓, we write

𝑓(𝑥,𝑦)=∫𝜕𝑓𝜕𝑥d𝑥=∫(𝑥2+2𝑥𝑦+2𝑦2+𝑦+1)d𝑥=𝑥33+𝑥2𝑦+2𝑥𝑦2+𝑥𝑦+𝑥+𝐶1(𝑦).𝑓(𝑥,𝑦)=∫𝜕𝑓𝜕𝑦d𝑦=∫(𝑥2+𝑥+4𝑥𝑦+𝑦2+2)d𝑦=𝑥2𝑦+𝑥𝑦+2𝑥𝑦2+𝑦33+2𝑦+𝐶2(𝑥).

Stitching these together to get the final expression for 𝑓(𝑥,𝑦) as:

𝑓(𝑥,𝑦)=𝑥33+𝑥2𝑦+2𝑥𝑦2+𝑦33+𝑥𝑦+𝑥+2𝑦+𝐶

for any constant 𝐶.

  1. 27 Technically, one ought to show that every vector could occur for some function, but for 18.02 I won’t dwell on that. Anyone who knows what I’m talking about should be able to fill in this step for me :P