VMaChine is a general variational Monte Carlo (VMC) solver written in object-oriented C++. It was implemented with focus on quantum dot systems, and standard trial wave functions (Hermite functions) are implemented. However, we primary aim of examining trial wave functions where a less amount of physical intuition is required. Therefore, several trial wave functions based on neural networks and machine learning are also included, hence VMaChine. The code is largely parallelizable and is well-suited for large clusters.
After compiling the code, a configuration file input.in
is run by
vmachine input.in
on a single thread or
mpirun -n 4 vmachine input.in
on 4 CPUs (might be any number).
- Added Xavier initialisation class
- Now supporting weight initialisation from file
- Added better comments
- Splitted up system.cpp in several files to increase readability
- An interaction class is added. The old style "interaction: true" is now superseded by "interactionStyle: coulomb".
- The log (printed to the terminal by default) is now more readable both for a human eye and for the computer
- Examples added
- Fixed bug in CMakeLists.txt
- Removed support for Armadillo, as it was found to be more confusing than useful
To run the code without issues, C++14 is required. In addition, a few external packages are needed:
- MPI
- Eigen
MPI is used for parallel processing. On Linux, the package can be installed by the following commands
sudo apt-get install libopenmpi-dev
sudo apt-get install openmpi-bin
MPI is also avaliable on other platforms.
Eigen is a C++ template library for linear algebra operations. See http://eigen.tuxfamily.org/ for installation details.
VMaChine can be installed by cloning this repository. This is preferably done in the home directory:
cd
git clone https://github.com/evenmn/VMaChine.git
Then copy Eigen header files and blocker files to VMaChine:
cd ~/Download/eigen-3.3.9 # insert correct path here
cp -r Eigen ~/VMaChine/include/
The code can be compiled by either CMake or QMake
Build VMaChine in the usual CMake way:
mkdir build
cd build
cmake ..
make -j8
The executable is then found in ~/VMaChine/build
folder, which is added to the bash resource path by
echo "export PATH=~/VMaChine/build:\$PATH" >> ~/.bashrc
- Download QT-creator
- Configure the building file
src/vmachine.pro
The project can then be run in QT-creator using ctrl
+ R
.
The desired simulation parameters are specified in a configuration file. A typical configuration file can be found in input.in:
# system
numParticles: 2
numDimensions: 2
hamiltonian: harmonicOscillator
omega: 1.0
interactionStyle: coulomb
# wave function
waveFunctionElement: gaussian
waveFunctionElement: padeJastrow
# simulation
numIterations: 100
numSteps: 100000
learningRate: 0.1
stepLength: 0.1
The configuration file is simply run by
vmachine input.in