Mathematica™ is a general mathematics package that can perform sophisticated calculations numerically and/or symbolically. When the program is launched, two separate components are running:
- The User Interface: This should be thought of as nothing more than a mathematics-oriented word processor. You can type in anything you wish in a variety of different formats. The interface by itself does not perform any calculations.
- The Kernel: This is the mathematics engine. It runs entirely in the background, and only executes commands when you explicitly tell it to, and only in the order in which you tell it to.
A Mathematica™ document, or “notebook,” consists of a series of “cells,” one after another, running from the top of the notebook to the bottom. There are numerous cell types that Mathematica™ recognizes, which you can see either in the Format/Style menu or by right-clicking and selecting Insert New Cell. The cell types we will be most concerned with are:
- Title: A title for the document (name, homework number, etc.).
- Section: A header type that you can use to mark off a section of your notebook. You can use this, for example, to specify the problem number on a homework.
- Subsection: A header type that marks off subsections within a section.
- Text: This is the most word-processor-like cell type. You will use this cell type for any explanations or other text may be necessary.
- Item: If you need a bulleted list for some reason, use this.
- Subitem: If you need a nested bulleted list for some reason, use this.
- Input: Executable commands.
- Output: The results of executable commands.
These various cell types can be formatted in a variety of different ways, depending on which stylesheet (Format/Stylesheet) a particular notebook uses. My personal preference is the Report/StandardReport stylesheet, because that stylesheet uses:
- convenient icons next to sections and subsections allowing you to hide a section/subsection you aren’t currently working on, and
- visually distinguishes clearly between input and output cells using different background colors.
In the above figure, notice the brackets to the right of the window, indicating the span of cells, and the nesting organization of those cells. Clicking on those brackets lets you select a cell in its entirety. Right-clicking on it brings up a context-sensitive menu that, among other things, lets you change cell types. Double-clicking on it will collapse that cell so that it isn’t visible. The carat icons next to the section headings can be used for that same purpose.
In the lower-right-hand corner of the window, there is a zoom indicator, shown as 100% in the above screenshot. This is a convenient option to change when you are working on a monitor where the cell text seems too small to read.