next up previous
Next: About this document ... Up: Labs and Projects for Previous: Labs and Projects for


Some Ideas of Differential Calculus


In Maple, loops can be used to generate much output with the input of only a few commands. Try the following code and see how it generates a list of the squares of the first six positive integers. Note that only the last line has a semicolon at the end. Because of this, after entering the first line you may get an error message

Warning, incomplete statement or missing semicolon.

Just ignore the warning and continue with the input.

  > for n from 1 to 6 do
  > print(n^2)
  > od;
if you want to print n and n2 on the same line, change the second line to read
  > lprint(n,n^2)

If you want to put labels on the output, try

  > for k from 1 to 6 do
  > lprint(`k = `,k,`  k^4= `,k^4)
  > od;
(There are additional ways to get ``pretty'' output.) As you see, any expression enclosed in the ` marks will be printed exactly as written.

Loops can also be nested. The following code can be used to check on some of the functional values of $z = \sin(x,y)$.

  > for x from 1 to 3 by 0.5 do
  > for y from 1 to 3 by 0.5 do
  > lprint(x,y,sin(x*y))
  > od
  > od;


Type all commands given in the introductory section and display the output that results.
In this exercise we consider plots of the function f(x) = x4 - 104x over intervals centered on x = 3.
Use a Maple loop to generate plots of the kind just mentioned. First set h = 1.0. Then set up a loop that will give six plots. The second line in the commands for the loop will by a plot statement for f(x) over the interval [3 - h, 3 + h]. (Note that Maple will insist that you put a semicolon at the end of this line.) On the next line set a new value of h that is 0.25 times the previous value - this will make the next plot be given over a smaller interval. Finally, finish the loop statement with an od.
Look at the y-scale on the last three plots. Do these numbers make sense? Explain what is going on with Maple.

Describe what has happened in the successive plots. What shape does the last graph appear to have? What slope is associated with the last graph? (Be careful since the x-axis and y-axis readings are on different scales. Show your computations.)

What do the results you described in (c) have to do with the basic ideas of differential calculus? Explain fully.

Look up the syntax for the Maple limit command. Use that command to evaluate the following limits.
$\displaystyle\lim_{x\rightarrow 0^+}

$\displaystyle\lim_{x\rightarrow 1}\displaystyle\frac{x^4-6x^3+7x-5}{x^2-3x+2}$

Consider $f(x) = \sqrt{2x^2+17}$ with c = 4.
Set up a statement for the slope of the secant line between the points $(4,\; f(4))$ and $(4 + h,\; f(4 + h))$. Use Maple to find the limit of this expression as h goes to 0.
Use a loop to evaluate your statement for the slope of the secant line at six small values of h.

Explain the geometric significance of what you have done in (a) and (b). Relate the work of this exercise to the answer you gave for 2(d).
Suppose the number of bacteria in a certain organism grows over time and the number, N(t), of bacteria (measured in thousands) at time t (in days) is given by
N(t) = t(2 +\cos(t))^{4/3} + 3t.\end{displaymath}\end{maplelatex}
At any given time t the number of bacteria is actually an integer, and here we are approximating the number by the value N(t).
Plot N(t) for the interval [0,10]. From inspection of the graph, choose the integer value of t, t0, at which it appears that the number of bacteria is increasing most rapidly. Calculate the average growth rate from t = t0 to t = t0 + 0.5.
Write an expression giving the average growth rate over the time interval [t0, t0 + h].
Take the limit as h goes to 0 of your expression from (b). Interpret this limit. Explain its significance.

next up previous
Next: About this document ... Up: Labs and Projects for Previous: Labs and Projects for

Christine Marie Bonini