Skip to content
Split-step solver for the 3D (dipolar) Gross-Pitaevskii equation
C++ Python Makefile
Branch: master
Clone or download

Latest commit

Fetching latest commit…
Cannot retrieve the latest commit at this time.


Type Name Latest commit message Commit time
Failed to load latest commit information.

Dipolar Gross-Pitaevskii Solver

gpepython is a split-step solver for the (dipolar) Gross-Pitaevskii equation. The main part of the code is written in C++ and parallelized using OpenMP. The simulations can be controlled through a Python interface.

Dipolar Bose gas in a triple-well potential

Sample simulation


from gpe import HarmonicTrapGPE, GPE

# Load GPE
sim = HarmonicTrapGPE("Simple", 1.0, 1.0, 1.0)

# Grid parameters

# Contact interaction
# Only the product (atomNumber - 1) * scatteringLength is important
sim.set("atomNumber",       2)
sim.set("scatteringLength", 1)

# Dipolar interaction (switched off)
sim.set("dipolarLength", 0)
sim.set("evolutionDipolar", False)

# Number of threads. Equals number of cores if not set
# sim.setThreads(4)


# Imaginary time evolution
sim.ite(steps=10000, monitorSteps=500, plotSteps=500)


Dependencies needed:

  • Recent version of g++ with C++0x and OpenMP support
  • Multi-threaded fftw3
  • Boost with support for Python
  • Works with both Python 2 and 3 (see Makefile, tested with 2.7 and 3.4)

Run make in the gpe folder.


See appendix C of this thesis.

You can’t perform that action at this time.