Version 25 (modified by steve, 11 years ago) (diff)


Installing ANUGA on Ubuntu using the very latest (bleeding edge) version of the code

Packages to install

Install the following packages via the commands

sudo apt-get install subversion
sudo apt-get install python-dev
sudo apt-get install python-matplotlib

Pre Ubuntu 12.04

Also need to install the following packages

sudo apt-get install python-argparse
sudo apt-get install python-profiler

Finally we need scientific python to provide netcdf support. Pre 12.04 just install the package via

sudo apt-get install python-scientific

Ubuntu 12.04

For Ubuntu 12.04 the default python-scientific is the old version 2.8, and this leads to segmentation faults. So we need to install scientific python version 2.9.1 from source.

First we need to install netcdf support via

sudo apt-get install netcdf-bin libnetcdf-dev

Now get the scientific python 2.9.1 source from

Follow this link and the file should download to your machine. Save the file and then extract it to your Downloads directory.

You may need to manually extract via the tar command, i.e.

tar xvf ScientificPython-2.9.1.tar.gz

You should end up with a directory ScientificPython-2.9.1

Change into the directory and install scientific python via

python build
sudo python install

Checkout anuga via svn

From your home directory run:

svn checkout anuga_core

This should produce an anuga_core directory in your home directory


Put the following in your .bashrc file (if you use the bash shell. With some version of linux you need to put this command in the file .profile )

export PYTHONPATH=/home/username/anuga_core/source

(of course change /home/username to your home directory. )

Should rerun your .bashrc file with

source .bashrc

Actually it is usually safer to fire up a new terminal to see if you have been successful in setting up the PYTHONPATH

You can check your PYTHONPATH with the command


Compile ANUGA Code

Now go to the directory anuga_core and compile the anuga files via:


Run Unit tests

From the anuga_core directory run the unit tests via:



Hopefully all the unit tests pass. As this is bleeding edge there are sometimes a small number of failures as this is a work in progress. Have a look at the demos in the directory anuga_core/documentation/user_manual/demos (along with the user manual) to see how to use anuga.


From time to time you should update your version of anuga. This is fairly easy. From your anuga_core directory update the anuga code via the subversion command

svn update

Then again from the anuga_core directory recompile the code and check the unit tests via