next up previous
Next: About this document ... Up: lab_template Previous: lab_template

Subsections


MA 1024 Lab 3: Surfaces

Purpose

The purpose of this lab is to introduce you to some of the Maple commands that can be used to plot surfaces in three dimensions.

Getting Started

To assist you, there is a worksheet associated with this lab that contains examples and even solutions to some of the exercises. You can copy that worksheet to your home directory with the following command, which must be run in a terminal window, not in Maple.

cp ~bfarr/Surf_start.mws ~

You can copy the worksheet now, but you should read through the lab before you load it into Maple. Once you have read to the exercises, start up Maple, load the worksheet Surf_start.mws, and go through it carefully. Then you can start working on the exercises.

Background

The graph of a function of a single real variable is a set of points $(x,f(x))$ in the plane. Typically, the graph of such a function is a curve. For functions of two variables in Cartesian coordinates, the graph is a set of points $(x,y,f(x,y))$ in three-dimensional space. For this reason, visualizing functions of two variables is usually more difficult. For students, it is usually even more difficult if the surface is described in terms of polar or spherical coordinates.

One of the most valuable services provided by computer software such as Maple is that it allows us to produce intricate graphs with a minimum of effort on our part. This becomes especially apparent when it comes to functions of two variables, because there are many more computations required to produce one graph, yet Maple performs all these computations with only a little guidance from the user.

The simplest way of describing a surface in Cartesian coordinates is as the graph of a function $z = f(x,y)$ over a domain, e.g. a set of points in the $xy$ plane. The domain can have any shape, but a rectangular one is the easiest to deal with. Another common, but more difficult way of describing a surface is as the graph of an equation $F(x,y,z) = C$, where $C$ is a constant. In this case, we say the surface is defined implicitly. A third way of representing a surface $z = f(x,y)$ is through the use of level curves. The idea is that a plane $z=c$ intersects the surface in a curve. The projection of this curve on the $xy$ plane is called a level curve. A collection of such curves for different values of $c$ is a representation of the surface called a contour plot.

Some surfaces are difficult to describe in Cartesian coordinates, but easy to describe using either cylindrical or spherical coordinates. The obvious examples are cylinders and spheres, but there are many other situations where these coordinate systems are useful.

Exercises

  1. Generate a surface plot and contour plot for the following function on the given domain.

    \begin{displaymath}f(x,y) = x/(1+x^2+y^2)\end{displaymath}

    for $-3\leq x\leq 3$ and $-3\leq y\leq 3$.
    1. What does the contour plot look like in the regions where the surface plot has a steep incline? What does it look like where the surface plot is almost flat?
    2. What can you say about the surface plot in a region where the contour plot looks like a series of nested circles?
  2. Generate a surface plot for the following functions on the domains given.
    1. $r=z^2(1+\cos(2\theta))+1/4$ for $0 \leq \theta \leq 2 \pi$ and $-1
\leq z \leq 1$. Use cylindrical coordinates.
    2. $\rho = \exp(\theta/3)\sin(\phi)$ for $0 \leq \theta \leq 2 \pi$ and $0 \leq \phi \leq \pi$. Use spherical coordinates.
  3. Consider the following function

    \begin{displaymath}r(x,y) = \frac{2x+y+1}{1+x^2+3y^2} \end{displaymath}

    which represents the deviation, in inches, of last year's rainfall from the average annual rainfall in a certain area. Considering only the domain $-3\leq x\leq 3$ and $-3\leq y\leq 3$, use a contour plot to find the region in this domain in which the deviation was at least $0.9$ in. but no more than $1.2$ in.

  4. Some surfaces in three dimensions can't be easily represented in any of the three coordinate systems we have described so far. In such cases, a parametric plot often works. Try the following command and describe what you see.
    > plot3d([4*cos(s)+cos(t)*cos(s),4*sin(s)+cos(t)*sin(s),sin(t)],
       s=0..2*Pi,t=0..2*Pi,style=patch);
    
    This surface is called a torus. Can you explain why it can't be represented in Cartesian coordinates as $z = f(x,y)$, in cylindrical coordinates as $r=g(\theta,z)$, or in spherical coordinates as $\rho =
h(\theta,\phi)$?


next up previous
Next: About this document ... Up: lab_template Previous: lab_template
William W. Farr
2004-04-06