Skip to content
This repository has been archived by the owner on Mar 22, 2023. It is now read-only.
/ gscf Public archive

A general library for solving self-consistent field problems

License

GPL-3.0, Unknown licenses found

Licenses found

GPL-3.0
LICENCE
Unknown
LICENSE
Notifications You must be signed in to change notification settings

molsturm/gscf

Repository files navigation

gscf

Build Status Coverage Status Licence

A library of algorithms for solving non-linear generalised eigenproblems as they frequently occur when finding a self-consistent field (SCF) solution to a partial differential equation in theoretical physics or chemistry.

At the moment the major application of the code is electronic structure theory, more precisely solving the Hartree-Fock approximation to the many-body Schrödinger equation. Most available algorithms, however, are implemented in a way such that they are not specific to this problem or the type of basis used to model the physical system. Hence the name gscf for generalised SCF.

Dependencies

gscf depends on the following:

  • krims for many basic utilities (GenMap, Exception handling, Subscription pointers, ...)
  • lazyten as a flexible linear algebra backend. lazyten has further dependencies in order to perform the linear algebra. See github.com/lazyten/lazyten for details.

Testing gscf further requires

For building gscf (see below) you only need the gscf source code and the build dependencies of lazyten, i.e. armadillo, LAPACK and some BLAS library to be present on your system. The other dependencies (including krims and lazyten) can be automatically downloaded during the build process if you choose to do so (set AUTOCHECKOUT_MISSING_REPOS to ON, more below)

Building gscf

For configuring the build we need at least cmake 3.0.0.
All compilers starting from clang-3.5 and gcc-4.8 should be able to build the code. We strictly require C++11 to build this library.

If you choose to build with the flag AUTOCHECKOUT_MISSING_REPOS set to ON all required dependencies will be automatically downloaded and compiled alongside gscf.

In order to build gscf with tests (recommended) run

mkdir build && cd build
cmake -DAUTOCHECKOUT_MISSING_REPOS=ON ..
cmake --build .
ctest

In order to build without tests run

mkdir build && cd build
cmake -DAUTOCHECKOUT_MISSING_REPOS=ON -DENABLE_TESTS=OFF ..
cmake --build .

Short description of gscf

In gscf we wish to solve a nonlinear SCF problem like

A(v,x) x = v x

where A is a matrix depending on its own eigenvalues v and eigenvectors x implicitly.

The following SCF algorithms are currently implemented for this task:

  • Plain SCF: Start with an initial guess for A and diagonalise it to obtain a hopefully improved set of eigenpairs (v,x). From these build a new matrix A and repeat.
  • DIIS: An scf algorithm based on the direct inversion of the iterative subspace method by Peter Pulay.
  • Truncated optimal damping: Based on the optimal-damping algorithm by Eric Cancès and Claude le Bris. This algorithm is specific to the Hartree-Fock problem only.