mirror of
https://github.com/ParticulateFlow/CFDEMcoupling-PFM.git
synced 2025-12-08 06:37:44 +00:00
176 lines
6.0 KiB
HTML
176 lines
6.0 KiB
HTML
<HTML>
|
|
<CENTER><A HREF = "http://www.cfdem.com">CFDEMproject WWW Site</A> - <A HREF = "CFDEMcoupling_Manual.html#comm">CFDEM Commands</A>
|
|
</CENTER>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<HR>
|
|
|
|
<H3>githubAccess_public
|
|
</H3>
|
|
<HR>
|
|
|
|
<P><B>Description:</B>
|
|
</P>
|
|
<P>This routine describes how to setup a github account and pull repositories of the CFDEMproject.
|
|
After setting some environment variables LIGGGHTS and CFDEMcoupling can be compiled
|
|
</P>
|
|
<P><B>Procedure:</B>
|
|
</P>
|
|
<P>Basically the following steps have to be performed:
|
|
</P>
|
|
<UL><LI><I>git clone</I> the desired repository
|
|
|
|
<LI>update your repositories by <I>git pull</I>
|
|
|
|
<LI>set environment variables
|
|
|
|
<LI>compile LIGGGHTS and CFDEMcoupling
|
|
|
|
<LI>run your own cases
|
|
|
|
|
|
</UL>
|
|
<P><B><I>git clone</I> the desired repository:</B>
|
|
</P>
|
|
<P>If not already done, open a terminal and create a directory for LIGGGHTS in $HOME:
|
|
</P>
|
|
<PRE>cd
|
|
</PRE>
|
|
<PRE>mkdir LIGGGHTS
|
|
</PRE>
|
|
<PRE>cd LIGGGHTS
|
|
</PRE>
|
|
<P>To clone the public LIGGGHTS repository, open a terminal and execute:
|
|
</P>
|
|
<PRE><H6>git clone git://github.com/CFDEMproject/LIGGGHTS-PUBLIC.git LIGGGHTS-PUBLIC
|
|
</H6></PRE>
|
|
<P>If not already done, open a terminal and create a directory for CFDEMcoupling in $HOME:
|
|
</P>
|
|
<PRE>cd
|
|
</PRE>
|
|
<PRE>mkdir CFDEM
|
|
</PRE>
|
|
<PRE>cd CFDEM
|
|
</PRE>
|
|
<P>Make sure that OpenFOAM(R)-2.1.x is already set up correctly!
|
|
</P>
|
|
<P>To clone the public CFDEMcoupling repository, open a terminal and execute:
|
|
</P>
|
|
<PRE><H6>git clone git://github.com/CFDEMproject/CFDEMcoupling-PUBLIC.git CFDEMcoupling-PUBLIC-$WM_PROJECT_VERSION
|
|
</H6></PRE>
|
|
<P>Troubles? See Troubleshooting section below.
|
|
</P>
|
|
<P><B>Update your repositories by <I>git pull</I>:</B>
|
|
</P>
|
|
<P>To get the latest version, open a terminal, go to the location of your local installation and type:
|
|
<I>Warning: git stash will remove your changes in $HOME/CFDEM/CFDEMcoupling-PUBLIC-$WM_PROJECT_VERSION !</I>
|
|
</P>
|
|
<PRE>cd $HOME/CFDEM/CFDEMcoupling-PUBLIC-$WM_PROJECT_VERSION
|
|
git stash
|
|
git pull
|
|
</PRE>
|
|
<P><B>Set Environment Variables:</B>
|
|
</P>
|
|
<P>Now you need to set some environment variables in ~/.bashrc (if you use c-shell, manipulate ~/.cshrc accordingly). Open ~/.bashrc
|
|
</P>
|
|
<PRE>gedit ~/.bashrc &
|
|
</PRE>
|
|
<P>add the lines (you find them also in .../cfdemParticle/etc/bashrc and cshrc respectively):
|
|
</P>
|
|
<PRE>#================================================#
|
|
#- source cfdem env vars
|
|
export CFDEM_VERSION=PUBLIC
|
|
export CFDEM_PROJECT_DIR=$HOME/CFDEM/CFDEMcoupling-$CFDEM_VERSION-$WM_PROJECT_VERSION
|
|
export CFDEM_SRC_DIR=$CFDEM_PROJECT_DIR/src
|
|
export CFDEM_SOLVER_DIR=$CFDEM_PROJECT_DIR/applications/solvers
|
|
export CFDEM_DOC_DIR=$CFDEM_PROJECT_DIR/doc
|
|
export CFDEM_UT_DIR=$CFDEM_PROJECT_DIR/applications/utilities
|
|
export CFDEM_TUT_DIR=$CFDEM_PROJECT_DIR/tutorials
|
|
export CFDEM_PROJECT_USER_DIR=$HOME/CFDEM/$LOGNAME-$CFDEM_VERSION-$WM_PROJECT_VERSION
|
|
export CFDEM_bashrc=$CFDEM_SRC_DIR/lagrangian/cfdemParticle/etc/bashrc
|
|
export CFDEM_LIGGGHTS_SRC_DIR=$HOME/LIGGGHTS/LIGGGHTS-PUBLIC/src
|
|
export CFDEM_LIGGGHTS_MAKEFILE_NAME=fedora_fpic
|
|
export CFDEM_LPP_DIR=$HOME/LIGGGHTS/mylpp/src
|
|
export CFDEM_PIZZA_DIR=$HOME/LIGGGHTS/PIZZA/gran_pizza_17Aug10/src
|
|
. $CFDEM_bashrc
|
|
#================================================#
|
|
</PRE>
|
|
<P>Save the ~/.bashrc, open a new terminal and test the settings. The commands:
|
|
</P>
|
|
<PRE>$CFDEM_PROJECT_DIR
|
|
$CFDEM_SRC_DIR
|
|
$CFDEM_LIGGGHTS_SRC_DIR
|
|
</PRE>
|
|
<P>should give "...: is a directory" otherwise something went wrong and the environment variables in ~/bashrc are not set correctly.
|
|
</P>
|
|
<P>To specify the paths of pizza, please check the settings in $CFDEM_SRC_DIR/lagrangian/cfdemParticle/etc/bashrc.
|
|
</P>
|
|
<P>If $CFDEM_SRC_DIR is set correctly, you can type
|
|
</P>
|
|
<PRE>cfdemSysTest
|
|
</PRE>
|
|
<P>to get some information if the paths are set correctly.
|
|
</P>
|
|
<P><B>Compile LIGGGHTS and CFDEMcoupling:</B>
|
|
</P>
|
|
<P>If above settings were done correctly, you can compile LIGGGHTS by typing:
|
|
</P>
|
|
<PRE>cfdemCompLIG
|
|
</PRE>
|
|
<P>and you can then compile CFDEMcoupling by typing:
|
|
</P>
|
|
<PRE>cfdemCompCFDEM
|
|
</PRE>
|
|
<P>You can run the tutorial cases by executing .../etc/testTutorial.sh through the alias <I>cfdemTestTUT</I>.
|
|
Alternatively you can run each tutorial using the <I>Allrun.sh</I> scripts in the tutorial directories.
|
|
</P>
|
|
<P>In case questions concerning the installation arise, please feel free to contact our forum at www.cfdem.com.
|
|
</P>
|
|
<P><B>Run Your Own Cases:</B>
|
|
</P>
|
|
<P>If you want to run your own cases, please do so in $CFDEM_PROJECT_USER_DIR/run which is automatically being generated. E.g. copy one of the tutorial cases there, adapt it to your needs.
|
|
Changes in $CFDEM_TUT_DIR will be lost after every <I>git stash</I>!
|
|
</P>
|
|
<P><B>Additional Installations:</B>
|
|
</P>
|
|
<P>Optionally you can install lpp which will help you convert the DEM (dump) data to VTK format. For standard CFD-DEM runs this will not be necessary. To get the DEM postporcessing tool "lpp" you need python-numpy package installed:
|
|
</P>
|
|
<PRE>sudo apt-get install python-numpy
|
|
</PRE>
|
|
<P>You can pull the latest version of lpp with:
|
|
</P>
|
|
<PRE>cd $HOME/LIGGGHTS
|
|
</PRE>
|
|
<PRE>git clone git://cfdem.git.sourceforge.net/gitroot/cfdem/lpp mylpp
|
|
</PRE>
|
|
<P><B>Troubleshooting:</B>
|
|
</P>
|
|
<UL><LI>toubles with git clone?
|
|
|
|
|
|
</UL>
|
|
<P><B>a)</B> The git protocol will not work if your computer is behind a firewall which blocks the relevant TCP port, you can use alternatively (write command in one line):
|
|
</P>
|
|
<P>git clone https://user@github.com/CFDEMproject/CFDEMcoupling-PUBLIC.git
|
|
CFDEMcoupling-PUBLIC-$WM_PROJECT_VERSION
|
|
</P>
|
|
<P><B>b)</B> If you face the error: "error: SSL certificate problem, verify that the CA cert is OK. Details: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed while accessing https://github.com/...",
|
|
</P>
|
|
<P>please use: env GIT_SSL_NO_VERIFY=true git clone https://github...
|
|
</P>
|
|
<P>(see http://stackoverflow.com/questions/3777075/https-github-access)
|
|
</P>
|
|
<P><B>c)</B> If you face the error: "Agent admitted failure to sign using the key. Permission denied (publickey).", after ssh -T git@github.com
|
|
</P>
|
|
<P>please type: "ssh-add"
|
|
</P>
|
|
<P>(see: https://help.github.com/articles/error-agent-admitted-failure-to-sign)
|
|
</P>
|
|
</HTML>
|