Class Notes

Numpy

Links:

Numerical Representations

See the paper A Remarkable Example of Catastrophic Cancellation Unravelled for an illustration of catastrophic cancellation.

Software Carpentry: Debugging

Links:
  • The software carpentry website on debugging has some useful tips on debugging (called Rules).

You might want to browse through the software carpentry website as it is the source of inspiration for this module.

Software Carpentry: Testing

Nose testing framework

If you install one of the bigger Python distributions like enthought, then nose should already be installed.

Software Carpentry: Version Control

Links
Software
  • Subversion (for any platform, command-line interface)
  • kdesvn (for Linux: this was what I demonstrated in class)
  • TortoiseSVN (for Windows)
  • Versions (for Mac OS, commercial software)
  • SCPlugin (for Mac OS, open source)

Lab Lecture 1

For this class, we are using Python. Most of my material will be based on Python 2.5. Version 2.6, which came out recently and hasn’t yet made it into the mainstream, is also fine. However, version 3 of Python is not recommended. In particular, many of the libraries that will be introduced in the practical sessions do not support Python 3 yet.

Links for Python:

If you are using Linux, then I recommend you get the Python packages that are standard for your distribution. Be sure to look for the numpy and scipy packages as well (in ubuntu, they’re called python-numpy and python-scipy). Python-matplotlib includes the very useful matplotlib library.

Enthought Python Distribution is a Python distribution specially targetted for scientific applications. It’s a commercial product, but free for students (like you). All the sotware it includes is open-source, but it’s nice to have a single distribution (especially if you are not using a Linux distribution that does that work for you). Python(x,y) is similar, but for Windows only (Linux version available soon, but on Linux, follow the advice above and use your Linux distribution’s installation).

Mac OS X includes a version of Python with the numpy & scipy libraries (they’re, I’m told, on a separate CD). If you are using 10.5, this should suffice for this course. If you are using an older version, you might consider upgrading using one of the distributions above (like Enthought’s)

Consider installing ipython: it’s a much improved Python shell (the default version is very limited). If you are using linux, then your distribution should have a package for it (Ubuntu calls it simply ipython). On Mac OS 10.5, check out this document.

Python IDEs (integrated development environments):