Software for the course

You can use either Matlab or Python. The language R might also be possible but not recommended.

If you don’t know either Matlab or Python I suggest using Matlab, which was originally designed explcitly for doing numerical linear algebra and so the syntax is a bit easier, and it is more straightforward to install and use. Also everyone should know some Matlab.

If you like using Python, or know Matlab well already and are looking to expand your programming expertise, then you should consider learning to use the Python Numpy libraries for numerical computing.

Matlab

Matlab is available on the Applied Mathematics computing system for students in this department. It is also available in the Arts and Sciences Instructional Computing Lab located in Communications B-022, and also available via their terminal server.

The Student Version of Matlab is available for as little as $49. This is worth buying if you think you will use Matlab regularly.

Some useful Matlab scripts and demos will be available in the Matlab subdirectory of the Class GitHub Repository. For demos that use Matlab publish please see the following link Matlab Publish.

Python

All the functionality of Matlab that is needed for this course is also available as open source software in the NumPy and SciPy Python modules, along with matplotlib for plotting purposes. Together with the IPython shell this provides an interactive computing environment very similar to Matlab’s.

See NumPy for Matlab Users for some handy tips on the correspondence between the two (tips that are also useful for users of either system to learn some commands you may not know).

Python is a standard language that is probably on your computer already. An easy way to install all of the numerical python routines you would need for this course is to use the free Anaconda Python distribution. If you install this, you can also then use the conda package installer to install various extensions easily. Note: If you also use pip install on your computer be aware that installing different packages in different ways can lead to various incompatibilities. You might want to consider creating a new conda environment.

You should install Python 2.7 (not 3.x) to be compatible with what is used in the notebooks posted for this this class.

Juptyer Notebooks

Jupyter notebooks are a web-based notebook environment. They used to be called IPython notebooks, but proved to be useful for many languages other than Python and so the web interface was expanded as Jupyter. See http://jupyter.org for more information and documentation.

If you have a Matlab license then you can also write Matlab code in a Juptyer notebook. Some examples used in this class will be presented in this manner.

See Jupyter notebooks for hints on using notebooks.

The notebook platform is rapidly being improved but as a result how things behave often depend on what version you have installed. If you installed the Anaconda Python, you can insure you have jupyter and are up to date via the bash commands:

conda install jupyter
conda update jupyter

Then in a bash shell you should be able to execute:

jupyter notebook

to start the notebook server. You can then navigate your browser to the address shown when the notebook starts, e.g.

http://localhost:8888/tree

If you want to easily run notebooks without installing any software, you might try Using SageMathCloud.

LAPACK

Both Matlab and NumPy provide convenient wrappers for LAPACK (Linear Algebra Package), which is an open source package written in Fortran 90 for solving linear algebra problems. So under the hood, you are using the same software whether you use Matlab or Python.

For large scale computing projects you may want to call LAPACK routines directly from a Fortran or C code.

LaTeX

For writing up homework, please use latex if possible. Free distributions are available on-line for different operating systems and some include nice editing tools. See the Latex section of the bibliography for some references, but there are also many tutorials online.

SageMathCloud includes a latex editor so you can use latex there without any installation required. See Using SageMathCloud.

You might also want to try Overleaf as another free web-based online latex writing and collaboration tool.

For writing up computational results, you might want to explore the Matlab Publish tools that allow you to include latex in Matlab comments that gets rendered along with your code and output.

Jupyter notebooks also allow putting latex in markdown cells to incorporate mathematics in the description.