]> 9.3 Visualizing Functions of Two Variables

9.3 Visualizing Functions of Two Variables

A function of two real variables defines a surface in three dimensions, the dimensions being the original two and the function itself.

We can produce a three dimensional image today, but for many years that was quite impractical, and mathematicians had to satisfy themselves with two dimensional images of these surfaces in three dimensions. There are two fundamental and complementary ways to do this.

The first is to plot equi-value contour lines in the x y plane. This method is used to show equal pressure lines (called isobars) in weather maps, or to show height of land surfaces in topographical maps.

When such contours are reasonably smooth, the tangent to a contour line represents a direction that is in the intersection of a horizontal plane and the tangent plane to the surface at that point.

The normal to a contour line in the x y plane points in the direction of the gradient vector (plus or minus it) and can also be used to describe the surface.

With a little practice you can get a pretty good idea what the function surface looks like from such contour lines. Thus the function rises relatively steeply where such contour lines for different values of the function are close to one another, and rises relatively gently when they are far apart.

A second way to describe a function of two variables is by drawing little arrows in the direction of the gradient vector at lots of points, and connecting these into "lines of increase" (not a common term).

These lines will be perpendicular to the equal-value contour lines, and will go from "local minimum points of the function to local maximum points", (or to or from the boundary of the region in which you are examining the function).

You can get a pretty good idea of the nature of the function from a picture of this kind.

When the function under investigation represents potential energy in some physical setting, or potential in electrostatics, then the lines here described are "lines of force" which show the direction that the force on an object or tiny charged particle point.

For physical applications we really want to be able to visualize functions of three variables, which are unusually difficult to describe on one flat surface. We will try to find ways to do this some day.

In the applet that follows, you can enter your favorite standard function of two variables, and a domain, and see what contour lines for it look like. With the first slider you can look at the gradient at a grid of points in the plane (the number of grid points is adjustable).

At the last grid point accessed, you can look at directional derivatives using the second slider. For the angle shown by the arrow, the magnitude of the directional derivative is represented by the length of the arrow. The sign of the directional derivative is positive when the dot product of the direction with the gradient is positive.

You can look at the actual surface defined by the function in the Directional Derivative applet to hone your intuition.