Running numgeo from command line
numgeo is designed as a command line tool, i.e. to run a simulation numgeo must be executed from some sort of command window. On Windows this is usually the Command prompt, Power shell or the Intel(r) oneAPI command prompt. On Linux systems its the Shell or Intel(r) oneAPI command prompt.
If numgeo is added to you system path as recommended, the command to run numgeo is as follows:
numgeo inp=... [out=... ncpus=... oldjob=... no-msg no-sta]
Where
inp=...
(mandatory) \(\rightarrow\) specify here the name of the input file containing the models and analysis description. If the file is not located in the current working directory, the file name must also contain the path to the input file.out=...
(optional) \(\rightarrow\) specify the name of the output files. If this keyword is committed, then the name of the input file will be used for the output files as well.ncpus=...
(optional) \(\rightarrow\) specify the number of cpus (threads) to be used for the simulation. If this keyword is omitted, the number of threads used for the simulation may vary depending on the operating system.oldjob=...
(optional) \(\rightarrow\) specify the name of the files of the previous simulation from which the new simulation should be started/continued.no-msg
(optional) \(\rightarrow\) tell numgeo not to report the convergence history in the message (msg) file.no-sta
(optional) \(\rightarrow\) tell numgeo not to report the convergence history in the statistic (sta) file.
In case numgeo is not added to you system path, you must point to the directory where the numgeo executable is located. Assuming that numgeo is in the current working directory (the directory where the command prompt is operating in), the command to run numgeo on Windows would take the following form:
numgeo.exe inp=... [out=... ncpus=... oldjob=... no-msg no-sta]
In case numgeo is not added to the system path, the Intel(r) oneAPI environment variables must be set before running numgeo. Details are provided section numgeo not added to the system path.
A typical workflow of the process of running a numgeo simulation and potential trouble shooting is explained in the Typical workflow section.
Typical workflow
The following flowchart gives an overview of typical procedures when using numgeo and how a simulation is started with numgeo.
graph TD
A[Open terminal] --> B[Change to directory where numgeo executable <br> and input files are located];
B --> C[Start simulation using <br>./numgeo inp=... out=... npcus=... <br>Or using Windows: <br>numgeo inp=... out=... npcus=...];
C --> D{Terminal reports error};
C --> E[Simulation runs <br> Terminal may report warnings];
D --> F[Open the .log file <br> Read error message];
E --> G[Check progress in the <br> .sta file and .msg file];
F --> H[Rerun];
G --> I[You can terminate the simulation <br> anytime using CTRL+C];
G --> J[Simulation is finished];
G --> K[Simulation aborts];
J --> L[Check results in ParaView <br> by opening the .pvd file];
J --> M[Plot results contained in <br> the print output folder];
K --> N[Open the .log file <br> Read error messages <br> Check results in ParaView];
numgeo not added to the system path
Adding numgeo to the system path is the recommended way of using numgeo. In this case numgeo ships with all dependencies an no other third-party libraries are required. There are situations where this is (1) not possible or (2) not enough (e.g. when you want to use user defined subroutines or external solvers).
In such cases a (full) installation of Intel(r) oneAPI including MKL is required. Before running numgeo, the environment variables of oneAPI must be set.
call "C:/Program Files (x86)/Intel/oneAPI/"setvars.bat
numgeo.exe inp=input_foundation_soil ncpus=1
source /xx/xx/intel/oneapi/setvars.sh
./numgeo inp=input_foundation_soil ncpus=1
Batch/shell scripts to run numgeo
Batch/Shell scripts are powerful "little" scripts that can help reducing redundant work or automating workflows. Sample batch/shell scripts for Windows and Linux are given below.
REM This is a comment
call "C:/Program Files (x86)/Intel/oneAPI/"setvars.bat
REM Set the number of omp threads on the environment level
set MKL_NUM_THREADS=1
set OMP_NUM_THREADS=1
numgeo.exe inp=input_foundation_soil ncpus=1
#!/bin/bash
# Set the oneAPI environment variables
# Adapt the following line to the path to setvars.sh on your system
source /xx/xx/intel/oneapi/setvars.sh
# change the rights for the numgeo program (make it executable)
chmod 777 numgeo
# Set the number of omp threads on the environment level
export MKL_NUM_THREADS=1
export OMP_NUM_THREADS=1
# now run numgeo
./numgeo inp=input_foundation_soil ncpus=1