In order to build and run this code, you need the following tools installed on your PC:
- g++
- cmake
- libxerces-c-dev
-
Create a
builddirectory and enter it:mkdir build && cd build -
Build the code:
cmake ..The default log level is
INFO.If you wish to set the log level manually, run:
LOG_LEVEL={WANTED_LOG_LEVEL} cmake ..Valid log levels are:
TRACE,DEBUG,INFO,WARN,ERROR,CRITICAL,OFF. -
Make:
make -j $(nproc)If you also wish to build the documentation, run:
make doc_doxygen -
Run the code:
./MolSim {INPUT} {DELTA_T} {END_TIME} {OUTPUT_WRITER} {CALCULATOR}Example calls:
./MolSim --help./MolSim --input=../resources/input-sun.txt --delta_t=0.014 --end_time=1000 --output=vtk --calculator=sv./MolSim --input=../resources/input-cuboid.txt --delta_t=0.0002 --end_time=5 --output=vtk --calculator=lj
-
Available options for arguments:
{HELP}: Prints out a list of available options for arguments.{INPUT}: The txt file to be read as input for the file reader.{DELTA_T}: The time step for the simulation. It should be a positive number.{END_TIME}: The end time of the simulation. It should be a positive number.{OUTPUT_WRITER}: The output writer to use. Available options are vtk or xyz.{CALCULATOR}: The calculator to use. Available options are sv, lj or dummy. -
If you wish to execute the tests:
./MolSimTestsorctest -V -R '.*Test'
-
If you wish to execute the benchmarks:
./MolSimBenchmark