Mathematica is a powerful mathmatics calculation tool. Mathematica actually consists of two different modules: the Mathematica Front End and the Mathematica Kernel. The Mathematica Front end is what runs when you double-click on the Mathematica icon. When you perform a calcuation in Mathematica, the front end passes the calculation to the Mathematica Kernel which performs the calculation and returns the result to the front end.

You can use Mathematica to plot functions. For example, if we wanted to compare the behavior of the functions:

f(x) = x

f(x) = x^2

f(x) = x^3

To plot these functions, type

We assign each of these plots to a name for further display. For example, if we typed:

Mathematica for the Mactintosh uses "Notebooks" to keep track of your calculations. The Mathematica notebooks can hold calculations, plots, programs, and other things that you can do in Mathematica. Each notebook consists of a series of "Cells" which contains a set of related calculations. For example, you can perform calculations in a cell and then plot those calculations in a related cell.

1) You can type formatted text within a cell. You can treat the cell much like a word processor and type titles, information, etc. and change the font size, color, etc. The example given in class of formatted text cells was the class list that was used to determine the order of presentations in this class.

To evaluate cells (perform the computation or operation defined in the cell), press the

Mathematica uses lists to store information. A list is a set of numbers, words, or virtually any type of data that is contained within braces with each member of the list separated by columns. For example, if you wanted to put the numbers 1 through 10 in a list, this would be {1,2,3,4,5,6,7,8,9,10} in list format. You can assign a list to a variable (just like the example with the plots above). Let's call the above list joe. To set joe equal to the above list of numbers, we can type joe = {1,2,3,4,5,6,7,8,9,10}.

In class, we used Mathematica to randomize our class presentation schedule. Here is a link to the notebook - download it and study it to see how it works.

We can determine the number of people in a list by using the Length function in Mathematica. For example, if we typed Length[joe], Mathematica would return a 10, because there are 10 numbers in the above list.

After we evaluate a function in Mathematica, it usually will spit the output out directly. If you do not want to have Mathematica give you the output of every cell, you can tell it not to do this by putting a semicolon after each evaluated function for which you do not want to see the output.

The table function takes a list, performs a specified function on the list, and outputs a list that represents the results of the calculation. For example, if we wanted to square all of the elements of the list joe that we created above, we could use the Table[joe^2,{joe,0,Length[joe]}]. This will create a list with the values of Joe^2 in it. The bracketed information is the range that you wish the command to operate on in the list. For example, if we only wanted to square the values of joe between 2 and 7, we could use the command Table[joe, {joe,2,7}] to do this.

Mathematica can perform both symbolic and numerical calculations. A numerical calculation could be something like 1+1 or any complex operation that you can usually do on a calculator. In addition, Mathematica can manipulate algebra and solve sets of algebraic equations. For example, it will solve a set of equations (e.g. 10 equations, 10 unknowns) automaticallly and return the algebraic solutions for these equations. In addition, Mathematica can integrate equations, differentiate equations, solve differential equations, etc. Basically, anything that you learned how to do in Calculus, Differential Equations, and Linear Algebra, Mathematica can do it in a matter of nanoseconds and plot up all of the results instantaneously. It is an extremely empowering piece of software because it lets you skirt around the mechanics of the math (which should be relagated to mathematicians) and let you investigate problems with some pretty serious equations.

Here is a graphic created in Mathematica:

Check out the graphics demo called "GraphicsDemo.nb" to see some of the cool things that you can do in Mathematica.

In class, we played with the

If you have inadvertently assigned a value to a variable that you do not wish to have a value, you can clear the variable's value by "zeroing" the value out. To do this, type the name of the variable followed by

There are some tool pallettes in Mathematica that allow you to symbolically integrate, differentiate, sum, raise numbers to a power, etc. To use these tools, click on the desired function (for example, the integration symbol), type your expression, and then evaluate the cell. These tools shortcut many of the intricate Mathematica expressions of past versions of the program.

We can assign values to variables and then use the variables to perform calculations. For example, if we have a box, we can represent the dimensions of the box as variables and then use the variables to calculate the volume of the box. If we measured the length, width, and height of the volume, we could type

Make sure to review the intro.nb file in order to get a grasp on the general syntax of many Mathematica commands. It is probably a good idea to read and play around with this notebook before attempting the assignment.

Many people have written all sorts of graphics and computational functions for Mathematica. These functions are not standard with Mathematica - they do not automatically load up when you run the Front End and Kernal. In order to use some of these functions, you need to tell Mathematica that you wish to use the functions and exactly where the functions are located. To do this, use the

Pages maintained by

Prof. Ramón Arrowsmith

Pages last modified on Wed Nov 26 1997.