\magnification=\magstep1
\centerline{Mathematics 131 -- Calculus for Physical and Life Sciences}
\centerline{Lab Day 2 -- Derivatives and Families of Curves}
\centerline{\it November 11, 2013}
\bigskip
\noindent
{\it Background}
\bigskip
We have now introduced a number of tools relating
properties of the derivatives of a function $f$
to the properties of the function $f$ itself (the 
First and Second Derivative Tests for critical points,
and so forth).  These are also useful in situations
where we want to study not just one curve, but a 
whole {\it family} of curves, defined by a formula
containing one or more ``parameters'' (constants that
can take on different values).  In this lab we will
study several examples of these families of curves,
and see how the parameters can influence the shape
of the curve.
\bigskip
\noindent
{\it A Worked Example}
\bigskip
First we will study the family of curves defined by 
$$y = f(x) = e^{-(x-a)^2/b}.$$ 
Here $a$ and $b > 0$ are the two parameters in the formula.  To
work with all of these simultaneously, we can define
a function in Maple like this:
\medskip
\centerline{\tt f := (x,a,b) -> exp(-(x-a)\^{}2/b);}
\medskip
\item{}
To plot individual curves in the family, we can use the 
plot command, and supply the particular
$a$ and $b$-values for the curve in the family that
we want.  For instance, to plot the curve with $a = 0$,
$b = 1$ on the interval $-3\le x \le 3$, 
we would use 
\medskip
\centerline{\tt plot(f(x,0,1),x=-3..3);}
\medskip
\item{1)}  Now, to plot the curves in the family for
$a = 0$ and $b = .1, 1, 3, 10$ together on the same
coordinate axes.  We need to pick an appropriate range of $x$-values
to plot so that we are seeing all of the graphs
in reasonable detail.  The interval $-10\le x \le 10$ will do.
Finally, let's use different colors so we can tell the graphs 
apart.   In the following, the four formulas for the graphs are
given in the set of square brackets (a Maple ordered list).  The
list of color values in the option at the end will be associated
with the plots in the same order.  
\medskip
\centerline{\tt plot([f(x,0,.1),f(x,0,1),f(x,0,3),f(x,0,10)],x=-3..3,color=[blue,green,red,black]);}
\medskip
\noindent
Note that if we vary $b$ but keep $a$ fixed in this family, then the size of the 
parameter $b$ {\it controls the width of the peak} -- smaller values correspond
to narrower peaks, while larger values correspond to wider peaks.  
\item{2)}  Now plot the curves in the family for
$a = -2, -1, 0, 1, 2$ together on the same
coordinate axes.  Again, pick an appropriate range of $x$-values
to plot so that you are seeing all of the graphs
in reasonable detail. Describe in general what happens
if we vary $a$ but keep $b$ fixed.
\item{3)}  How does the location of the critical point(s)
of $f(x)$ depend on $a,b$ in this family?
In Maple, you can compute $f'(x)$ by using 
{\tt diff(f(x,a,b),x);}.  If you enter this on a command line, 
you should see the output  
$${-2(x - a)\over b} e^{-(x-a)^2/b}$$
or something equivalent.  This is zero only at the one point $x = a$. 
There is exactly one critical point for each of the curves in the 
family.  This should match what you were seeing in the plots
in part 2.  
\item{4)}  Finally, where do the curves in this family have
inflection points, and how does their location 
depend on $a,b$?  The second derivative can be computed with 
\medskip
\centerline{diff(diff(f(x,a,b),x),x);}
Setting this equal to zero and solving for $x$ gives
$$x = a \pm {b\sqrt{2}\over 2},$$
so there are exactly two inflection points for all choices of $a,b$.  (Recall that 
$b > 0$ by assumption here.)
\bigskip
\noindent
{\it Lab Problems}
\bigskip
A)  Consider the family of curves defined by
$$y = g(x) = x^3 - 3ax + 1.$$
(Just one parameter, $a$, here.)
\bigskip
\item{1)}  Plot the curves in the family for
$a = -2, -1, 0, 1, 2$ on the same coordinate
axes.  
\item{2)}  How do the number and type of the 
critical points in this family depend on the
value of $a$?  
\item{3)}  There is exactly one value of $a$
for which $g(x)$ has a {\it double root}.
Find this $a$ and plot the corresponding
curve in the family to check your work. 
\bigskip
\noindent
B)  Finally, we consider the family of 
curves given by 
$$y = h(x) = {1\over (x - a)^2 + b}$$
(two parameters, $a$ and $b$ here).  
\bigskip
\item{1)}  Fix $a = 0$ 
and the curves in this family for $b = -2, -1, -0.2, 0, 0.2, 1, 2$.
Plot all five curves together on the same axes.  You 
will note that some of these have vertical asymptotes.
To ``cut off'' the graphs and get reasonable pictures,
add the options {\tt y=-20..20,discont=true} in the plot
command.
\item{2)}  Now fix $b$ (you get to choose the value)
and vary $a$ in this family.
Plot four curves together on the same axes.
\item{3)}  For what values of $a$ and $b$ does the graph
$y = h(x)$ have vertical asymptotes?  (This might require 
some thought or pencil and paper calculation rather than 
a Maple calculation.)
Where are the asymptotes located (give in terms of $a,b$)?
\item{4)}  Where are the critical point(s) of 
$y = h(x)$ located?  If you fix $a$, 
does the type
of critical point (maximum, minimum, neither) depend
on the value of $b$?  Explain.
\item{5)}  Find values of $a,b$ so that the function 
$y=h(x)$ has a local maximum at the point $(x,y) = (3,5)$.
Plot your curve.
\item{6)}  Where do the curves in this family have
inflection points, and how does their location 
depend on $a,b$?
\bigskip
\noindent
{\it Assignment}
\bigskip
Submit your Maple worksheet file by email to {\tt jlittle@holycross.edu} no later than
Monday, November 18 at 8:00am. 
\bye
