This folder contains the experiments documented in the paper "FunG - Invariant-based modeling". The experiments for section 4 are contained in the subfolder "performance-optimization" and for section 6 in "comparison-with-ad-libraries".
Both folders contain short instructions for compiling and running the examples.

Requirements (installation instructions are given for Ubuntu 14.04):
  1.  - In general FunG requires a recent compiler that supports at least some parts of C++14, such as decltype(auto) and trailing _t in type_traits:
  
        - sudo add-apt-repository ppa:ubuntu-toolchain-r/test
        - sudo apt-get update
        - sudo apt-get install gcc-4.9 g++-4.9
        - sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-4.9
      
      - Moreover cmake is required as build tool:
      
        - sudo apt-get install cmake
        
      
  1. For the examples in "performance-optimization" the Eigen linear algebra library (v3) is required:
  
     - sudo apt-get install libeigen3-dev
       ( also available from http://eigen.tuxfamily.org )
       

  2. - For the examples in "comparison-with-ad-libraries" we need blas, lapack and gomp (for trilinos):
  
       - sudo apt-get install libblas-dev
       - sudo apt-get install liblapack-dev
       - sudo apt-get install lib64gomp1 (resp. lib32gomp1 on 32-bit systems)
     
     - For the compilation of the AD-libraries used in the paper run the bash script 'install-ad-libraries'. Compiling Sacado and its dependencies from Trilinos may take some minutes. 
       You can speed up the compilation process by increasing the variable 'nThreads' in 'install-ad-libraries'.
      