Menu

Tree [27089f] 0.2.2 /
 History

HTTPS access


File Date Author Commit
 Demos 2018-07-23 Ulf Lorenz Ulf Lorenz [d55a99] Ticket 117: added python demo for the free-part...
 doc 2018-05-21 Ulf Lorenz Ulf Lorenz [7caaa3] Ticket 127: reduced number of decimal places in...
 extern 2018-07-21 Ulf Lorenz Ulf Lorenz [5f7cd6] Ticket 117: Got the first two classes running a...
 include 2018-08-19 Ulf Lorenz Ulf Lorenz [a4048e] Last release fixes / polish
 licenses 2018-08-17 Ulf Lorenz Ulf Lorenz [9f6397] Added cotire license
 python 2018-08-19 Ulf Lorenz Ulf Lorenz [27089f] Ticket 117: forgot to add a file
 scripts 2018-08-19 Ulf Lorenz Ulf Lorenz [6dd6ca] release preparations:
 src 2018-05-30 Ulf Lorenz Ulf Lorenz [a6e736] Ticket 126: fixed compilation errors
 test 2018-05-31 Ulf Lorenz Ulf Lorenz [446c50] Ticket 104: removed odeint dependency in wavepa...
 tools 2018-05-19 Ulf Lorenz Ulf Lorenz [3860f6] Ticket 127: added tiny comment on how to use ch...
 AUTHORS 2018-02-02 Ulf Lorenz Ulf Lorenz [b44a5d] Ticket 97: updated acceptance test and removed ...
 CMakeLists.txt 2018-08-19 Ulf Lorenz Ulf Lorenz [6dd6ca] release preparations:
 CONTRIBUTING 2018-01-22 Ulf Lorenz Ulf Lorenz [4ce87a] minor rewording in contribution file
 LICENSE 2017-08-27 Ulf Lorenz Ulf Lorenz [3bb05e] Ticket 94: put all documentation files under CC...
 NEWS 2018-08-19 Ulf Lorenz Ulf Lorenz [a4048e] Last release fixes / polish
 README 2018-08-19 Ulf Lorenz Ulf Lorenz [6dd6ca] release preparations:
 WavePacketConfig.cmake 2017-03-03 Ulf Lorenz Ulf Lorenz [a34083] Ticket 72: added first test for parameter funct...

Read Me

Description
===========

This is a C++ library to numerically solve the Schroedinger equation for
distinguishable particles.

The code is under the (very permissive) ISC license. See the file LICENSE for further details.

The current status in brief:
- you can solve the time-dependent and time-independent Schroedinger equation
- you can solve Liouville-von-Neumann equations;
  Lindblad and Redfield dissipation is implemented
- multiple coupled equations can be solved; multiple coupled channels
  (electronic states) are also supported
- plane wave expansions and a spherical harmonics grid are implemented
- Some common operators are defined, in particular Cartesian kinetic energy,
  the L^2 operator and harmonic and Morse potentials.
- Various operators allow extension with user-defined functions (potentials and such,
  time-dependent laser fields), and complex operators can be composed from elementary
  ones (addition, multiplication)
- absorbing boundary conditions can be added
- Several ODE propagators as well as the Chebychev polynomial method are implemented
- initial product states can be set up from various standard types; more complex
  compositions are partially supported
- you can print standard values and calculate and print out expectation values
- basic plotting (one-dimensional wave functions only) is implemented

Also, there is some optimization lacking for complex Hamiltonians etc.
Naturally, we plan to extend this in the nearer future.

There is also a prototype python interface. This requires you to have python
installed and activate the OPT_BuildPython parameter in cmake (see the
compilation instructions below). Currently, only the free particle demo has
been ported, see Demos/FreeParticle/Gaussian_1D/1/demo.py.


System requirements
===================

Note that there is a virtual machine image on the homepage for quick&simple installation.
See https://sourceforge.net/p/wavepacket/cpp/wiki/VirtualMachine/

To be able to compile the code, you need the following:

* A Unix system.
  I only test the build under Linux, but if you get the other requirements, any
  other Unix should be fine as well.
* CMake, at least version 3.5
* a compiler that implements the C++-11 standard.
  One of the later g++ (around version 4.7) or CLang++ version 3.2 or later should be fine.
* the tensor library that we use
    - clone it via git
      git clone https://github.com/juanjosegarciaripoll/tensor.git
      then compile and install it (usual autoconf setup)
    - note that you will need to enable FFTW support, which also requires the fftw libraries
      (run the configure script with "--with-fftw")
    - you can also try out the mps-bundle, which may offer more convenient compilation
      git clone https://github.com/juanjosegarciaripoll/mps-bundle.git
* the boost libraries from http://www.boost.org
    - You need at least boost version 1.56
* doxygen if you want to build the documentation ("make build-doc") 
* gnuplot, ffmpeg, possibly ImageMagick for the processing of the plotting output


Compilation and getting started
===============================

Simple Installation
-------------------

Since version 0.1.2, WavePacket uses CMake for the setup of the build process.
Assuming you have all requirements installed in standard locations, you can
compile and install the library by the following steps. They assume
the wavepacket directory (where this Readme resides) to be ${WP_SRCDIR}.

1. Create a new build directory where the binary files will be placed
   (we do a so-called out-of-source build)
2. In the build directory, run "cmake ${WP_SRCDIR}"
   Depending on your CMake and Boost version, there may be a warning about
   imported targets in FindBoost.cmake. You can safely ignore that.
3. In the build directory, run "make -j 4" (or however many cores you have).
   You can also build the documentation with "make build-doc"
4. Check that everything went ok by running "test/TestRunner"; all tests should be
   green (rarely, a test can fail by chance, then a rerun should be green, if you
   still have problems, drop a mail).
5. Install everything by running "make install" with admin privileges
   afterwards you can remove the build directory if you wish


Configuring the build
---------------------

You can change various settings of the build process by defining variables to
your preferences. There are three ways to do so:

1. When you originally run cmake, add flags "-D<var>=<value>", for example
   cmake -DCMAKE_BUILD_TYPE=Debug ${WP_SRCDIR}
2. After running cmake once, run
   ccmake ${WP_SRCDIR}
   This fires up a textmode program where you can edit the variables and
   reconfigure/regenerate the build system by hitting "c", then "g".
   Some variables are marked as advanced, hit "t" to be able to edit them.
3. Alternatively, you can run "cmake-gui" for a graphical interface for
   the editing of the variables.

The most important variables that you may wish to change:

* TENSOR_CONFIG
    the full path to the tensor-config script that was installed together
    with the tensor library. Only needed if you installed into an uncommon
    directory.
* Opt_BuildDemos
    If you set this to "OFF", the demos will not be built.
* Opt_UseCotire
    Setting this to "ON" substantially reduces build time by using precompiling headers
* CMAKE_INSTALL_PREFIX
    defines the root path where all the libraries and such will be installed.
    Default is "/usr/local"
* CMAKE_CXX_COMPILER
    the full path to the C++ compiler to use



First Steps
-----------

The installation also installs a build script to simplify the compilation of your
own programs. The syntax is

wp-build.sh  <executable_name> <source_file>

The script is documented and can be found under scripts/ for additional
details. The building is also documented in the package documentation (the
"Hello, world" tutorial).

The package documentation is available online: 
http://wavepacket.sourceforge.net/cpp-doc/0.2.2/index.xhtml
It contains a small tutorial that should cover the basic concepts of the library.
Also, some special use-cases/demos are discussed in depth. Several solutions to
common problems can be found under the demos (everything below directory
Demos/), and in the acceptance tests under test/acceptance/.
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.