http://www.elmerfem.org/elmerwiki/index ... r_on_Linux
http://ascend4.org/Building_Elmer_on_Ubuntu_12.04
https://subversion.apache.org/packages.html#debian
viewtopic.php?f=2&t=3653&sid=be626f5ee2 ... b11186abeb
Steps:
Note:
For the context of here , the scripts with "$" in their front mean that they are to be typed in the terminal and if they are without it "they are to be pasted in a file" and then will be implemented.
1. Check out for the subversion
Code: Select all
$ sudo apt-get install subversion
$ sudo apt-get install libapache2-svn
2. Get the elmerfem source via the subversion
Code: Select all
$ svn checkout http://svn.code.sf.net/p/elmerfem/code/trunk elmerfem
Code: Select all
$ svn checkout https://svn.code.sf.net/p/elmerfem/code/trunk elmerfem
Code: Select all
$ cd elmerfem
Code: Select all
#!/bin/sh -f
#the compiler (here the gcc 4.X suite)
export CC=gcc
export CXX=g++
export FC=gfortran
export F77=gfortran
#the compiler flags
export CFLAGS=""
export FCFLAGS=""
export F77FLAGS=""
export FFLAGS=""
#linking
export LDFLAGS=""
#paths
#export ELMER_HOME="/path/to/Elmerdir"
export ELMER_HOME="$HOME/elmerinst"
# modules
modules="matc umfpack mathlibs elmergrid meshgen2d eio hutiter post"
# configure and build
for m in $modules; do
cd $m ; ./configure --prefix=$ELMER_HOME && make clean && make && make install && cd ..
# configure and build the module fem using mpi related aspect
cd fem; ./configure --prefix=$ELMER_HOME --with-mpi-inc-dir=/usr/include/mpich2 && make clean && make && make install && cd ..
done
Code: Select all
$ chmod u+x compile.sh
$ ./compile.sh
- In the terminal, type the following;
Code: Select all
$ gedit ~/.bashrc
Code: Select all
export ELMER_HOME=$HOME/elmerinst
export ELMER_POST_HOME=$ELMER_HOME/share/elmerpost
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$ELMER_HOME/lib
export PATH=$PATH:$ELMER_HOME/bin
Steps for Testing of the ElmerNonGui
It is assumed that the elmerfem and elmerinst folders are in the home directory.
1. Make an elmer project directory
Code: Select all
$mkdir elmer_project
Code: Select all
$cp -r $HOME/elmerfem/fem/tests/CavityLid/ $HOME/elmer_project/CavityLid
Code: Select all
$cd ~/elmer_project/CavityLid/
Code: Select all
$ElmerGrid 1 2 square.grd
Code: Select all
$gedit case.sif
Code: Select all
Post File = case.vtu
Save the edited file.
6. Run the ElmerSolver command
Code: Select all
$ElmerSolver > anyname.log 2>&1
Code: Select all
$paraview
Code: Select all
$sudo apt-get install paraview
The following reply to this post describes the steps for running ElmerNonGUI in Ubuntu 12.04.
Yours
Anil Kunwar