ug4
Prerequisites on Linux / Unix

Before installing manually, you should check if the software is available in your packet manager or from your cluster management tool (e.g. module load).


Installation of UG4

Please follow the description at https://github.com/UG4/ughub to obtain a copy of ug4. Below you'll find hints on how to obtain additional software which is required to build ug4.


CMake

Note
You can use uginstall - Scripts for installation for easy installation of cmake.
  • In order to compile ug4, you have to have cmake installed.
  • Check if cmake is already installed: open a terminal, enter cmake –version. Minimum Version is 2.6.
  • If Cmake is not installed or wrong version, download CMake: Download the Unix/Linux Source code of CMake from here (min Release 2.6. direct link to 2.8.8).
  • suppose you downloaded cmake-2.8.8.tar.gz to your home directory. extract the file with tar -xzf cmake-2.8.8.tar.gz .
  • change to the created cmake-2.8.8 directory.
  • you can look at the configuration options with ./configure –help .
  • if you have root access
    • ./configure
    • make
    • sudo make install
  • if you don't have root access

  • run ./configure –prefix=. to install cmake in the current directory.
  • make
  • make install
  • cmake is now located at the bin subdirectory of your cmake-2.8.8 directory.
  • to make the cmake command available from everywhere, add $HOME/cmake-2.8.8/bin to your PATH variable (see here). (Enter the full path there, not "."). After that, do a source ~/.bashrc


You can check now if cmake is working by entering cmake in the console.


MPI

Note
You can use uginstall - Scripts for installation for easy installation of OpenMPI.
  • Note: MPI is only needed for parallel execution of ug4.
  • Check if MPI is already installed: open a terminal, enter which mpicc.
  • If MPI is not installed, download openmpi-1.6.tar.gz to your home directory.
  • the process is now the same as for cmake, only that you are looking for mpicc.
  • when you have no root: remember the –prefix=. option and to set the PATH .


Installation BLAS/LAPACK (optional)

Note
You can use uginstall - Scripts for installation for easy installation of GotoBLAS2.
  • Note: On most systems, LAPACK and BLAS are preinstalled and are found by cmake.
  • On some clusters, LAPACK/BLAS are kind of "built into" the compiler, so you don't have to specify anything. In this case, use
    cmake -DBUILTIN_BLAS=ON -DBUILTIN_LAPACK=ON
    Ask the administrator for help.
  • On some systems, you'd have to install LAPACK/BLAS manually. You can do this on most systems via their package managers.
  • If you can't find/get/install the packages: Download GotoBLAS2.
  • extract the source to ~/software/GotoBLAS2/
  • Choose one of the quickbuild.* files there and execute it.
  • Now add the path ~/software/GotoBLAS2 to the environment variable LD_LIBRARY_PATH by adding the line
      LD_LIBRARY_PATH=$LD_LIBRARY_PATH:~/software/GotoBLAS2/
    add the end of your ~/.bashrc.
  • remember to source ~/.bashrc
  • Now cmake should accept GotoBLAS2 as LAPACK/BLAS library.


Installation of ParaView (optional)

You can install a local version of ParaView by performing the following steps (only described for installation of a "precompiled binary", which usually will be the preferred way):

  1. Download tar ball:
    Go to http://www.paraview.org/paraview/resources/software.php and choose the version, type (e.g. "ParaView Binary Installer") and OS, and download the tar ball and move it in the directory where you want to install ParaView:
    mv ParaView-3.14.0-Linux-64bit.tar.gz ~/local
  2. Unpack:
    cd ~/local
    tar xvzf ParaView-3.14.0-Linux-64bit.tar.gz 
  3. After unpacking a binary installer the executables reside in e.g.
    ParaView-3.14.0-Linux-64bit/
    See the documentation (e.g. http://paraview.org/Wiki/The_ParaView_Tutorial) for how to build ParaView from sources (CMake and a compiler (of course) necessary — and a bit time).
  4. Shortcuts for executing the ParaView client and server from command-line (i.e., add lines like the following in your .bashrc (for Bash)):
    alias paraview='$HOME/local/ParaView-3.14.0-Linux-64bit/bin/paraview'
    alias pvserver='$HOME/local/ParaView-3.14.0-Linux-64bit/bin/pvserver'
    or (for Tcsh):
    alias paraview '$HOME/local/ParaView-3.14.0-Linux-64bit/bin/paraview'
    alias pvserver '$HOME/local/ParaView-3.14.0-Linux-64bit/bin/pvserver'
  5. Basic usage (using the shortcut mentioned above):
    • Start an instance of ParaView and load a datafile:
      paraview --data=<VTK-File>
    • Start an instance of ParaView and load a (previously saved) state file (with ending .pvsm):
      paraview --state=<state file>