Department of Mathematics

Math 300: Mathematical Computing

Assignment 7

In this assignment, you will write a script that plots the graph of your name function over the interval [-1,7]. For example, the instructor would have Matlab evaluate the expression \[\begin{align*} F_\text{Cooper}(x) &=\exp\left(-(x-0.75)^2\right)+\frac12\exp\left(-(x-3.75)^2\right)+\\ &\qquad\frac13\exp\left(-(x-3.75)^2\right)+\frac14\exp\left(-(x-4)^2\right)+\\ &\qquad\frac15\exp\left(-(x-1.25)^2\right)+\frac16\exp\left(-(x-4.5)^2\right).\\ \end{align*} \] at every element of some vector X, and then plot X against the values of that expression.

Figure 1: The Cooper function

The graph of this expression is shown in Figure 1. We stress that your function will not be the same as this; it will evaluate the function associated with YOUR surname. Observe that the axes of the figure are labeled.

You may do this assignment using Octave if you like, but alert the instructor to that in your email message.

The assignment is turned in when the instructor receives that .m file as an attachment to an email. The assignment is worth 25 points, and is due at 9AM on Tuesday, 23 October.

Assignment C is posted.

The test solution is available.

Department of Mathematics, PO Box 643113, Neill Hall 103, Washington State University, Pullman WA 99164-3113, 509-335-3926, Contact Us
Copyright © 1996-2015 Kevin Cooper