Skip to content

Commit

Permalink
Merge dftbplus/main
Browse files Browse the repository at this point in the history
  • Loading branch information
pecchia committed Jul 26, 2022
2 parents 23c99a2 + 44c4e6f commit 8396646
Show file tree
Hide file tree
Showing 75 changed files with 5,436 additions and 1,888 deletions.
8 changes: 6 additions & 2 deletions AUTHORS.rst
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ contributed to DFTB+ :

* Sebastian Ehlert (University of Bonn, Germany)

* Tammo van der Heide (University of Bremen, Germany)

* Jan Hermann (Free University of Berlin, Germany)

* Jacek Jakowski (Oak Ridge National Laboratory, USA)
Expand All @@ -52,8 +54,10 @@ contributed to DFTB+ :

* Reinhard Maurer (University of Warwick, UK)

* Tobias Melson (Max Planck Computing and Data Facility, Germany)

* Izaac Mitchell (University of Newcastle, Australia)

* Thomas Niehaus (University of Lyon, France)

* Alessandro Pecchia (University of Rome "Tor Vergata", Italy)
Expand All @@ -63,7 +67,7 @@ contributed to DFTB+ :

* Jan Řezáč (Institute of Organic Chemistry and Biochemistry AS CR, Czech
Republic)

* Cristián G. Sánchez (Universidad Nacional de Cuyo, Argentina)

* Miguel Steiner (ETH Zurich, Switzerland)
Expand Down
23 changes: 20 additions & 3 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,27 @@ Notable project changes since release 1.3.1 (2017-02-22).
Unreleased
==========


Fixed
-----

- Onsite and +U potentials in real time-propagation, which was broken
in October 2019 by commit 11abba39b


22.1 (2022-05-25)
=================

Added
-----

- Real time electronic dynamics for xTB Hamiltonian

- Support for MPI-parallel GPU accelerated calculations via ELPA/ELSI library

- Real time electronic dynamics for range separated DFTB

- Support for MPI-parallel GPU accelerated calculations via ELPA/ELSI library

- (Optionally) Rescale externally applied fields and dipole moments
- (Optionally) rescale externally applied fields and dipole moments
when implicit solvents are used

- Enable lattice constraints in new geometry optimization driver
Expand All @@ -28,9 +37,17 @@ Added

- API call for CM5 charges

- Numerical Hessian calculation can be split over multiple runs


Changed
-------

- PLUMED simulations may deliver due to an incompatible change in version 2.8.0
of the external PLUMED library slightly different results as before. See also
the `change log of PLUMED 2.8
<https://www.plumed.org/doc-v2.8/user-doc/html/_c_h_a_n_g_e_s-2-8.html>`_.

- Allow electric fields in periodic systems even when interactions
cross the sawtooth in the field

Expand Down
69 changes: 41 additions & 28 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ include(DftbPlusUtils)
dftbp_ensure_out_of_source_build()
dftbp_load_build_settings()

set(DFTBPLUS_VERSION "21.2")
set(DFTBPLUS_VERSION "22.1")

project(dftbplus VERSION ${DFTBPLUS_VERSION} LANGUAGES Fortran C)

Expand Down Expand Up @@ -174,11 +174,14 @@ if(WITH_CHIMES)
set(CMAKE_CXX_LINKER_PREFERENCE_PROPAGATES 0)
endif()

# If INCLUDE_INDIRECT_DEPS is non-empty, indirect dependencies must also be explicitely treated
string(REGEX MATCH "(^|;)[Ss]ubmodule(^|;)" INCLUDE_INDIRECT_DEPS "${HYBRID_CONFIG_METHODS}")

# Note: GIT_TAG hashes below must be updated with the utils/test/check_submodule_commits script!

if(WITH_MPI)
set(MPIFX_GIT_REPOSITORY "https://github.com/dftbplus/mpifx.git")
set(MPIFX_GIT_TAG "0641eead6ff9bf04c7ca2ec676a281780e2029e2") # do not change manually!
set(MPIFX_GIT_TAG "da51073aa87831a91ae756a9773e39ea000d1c3a") # do not change manually!
dftbp_config_hybrid_dependency(MpiFx MpiFx::MpiFx "${HYBRID_CONFIG_METHODS}" "QUIET"
external/mpifx "${exclude}" "${MPIFX_GIT_REPOSITORY}" "${MPIFX_GIT_TAG}")

Expand All @@ -204,7 +207,7 @@ endif()

if(WITH_TRANSPORT)
set(LIBNEGF_GIT_REPOSITORY "https://github.com/libnegf/libnegf.git")
set(LIBNEGF_GIT_TAG "c8ed2caf9ed00fce1a7d9583a605bec211920d2b") # do not change manually!
set(LIBNEGF_GIT_TAG "5b769f76406b12ec2faad30593cb061c5bec7d47") # do not change manually!
dftbp_config_hybrid_dependency(Negf Negf::Negf "${HYBRID_CONFIG_METHODS}" "QUIET"
external/libnegf "${exclude}" "${LIBNEGF_GIT_REPOSITORY}" "${LIBNEGF_GIT_TAG}")
#list(APPEND PKG_CONFIG_REQUIRES negf)
Expand All @@ -213,45 +216,54 @@ add_subdirectory(external/mudpack)

if(WITH_TBLITE OR WITH_SDFTD3)
set(MCTC_LIB_GIT_REPOSITORY "https://github.com/grimme-lab/mctc-lib.git")
set(MCTC_LIB_GIT_TAG "1f690009020fb5f196c1dc359056741738416db6") # do not change manually!
set(MCTC_LIB_GIT_TAG "3d0e921085eb6ca535dfceec876bc99baf52f05d") # do not change manually!
dftbp_config_hybrid_dependency(mctc-lib mctc-lib::mctc-lib "${HYBRID_CONFIG_METHODS}" "QUIET"
external/mctc-lib "${exclude}" "${MCTC_LIB_GIT_REPOSITORY}" "${MCTC_LIB_GIT_TAG}")
#list(APPEND PKG_CONFIG_REQUIRES mctc-lib)

set(MSTORE_GIT_REPOSITORY "https://github.com/grimme-lab/mstore.git")
set(MSTORE_GIT_TAG "1f690009020fb5f196c1dc359056741738416db6") # do not change manually!
dftbp_config_hybrid_dependency(mstore mstore::mstore "${HYBRID_CONFIG_METHODS}" "QUIET"
external/mstore "${exclude}" "${MSTORE_GIT_REPOSITORY}" "${MSTORE_GIT_TAG}")
#list(APPEND PKG_CONFIG_REQUIRES mstore)
if(INCLUDE_INDIRECT_DEPS)
set(MSTORE_GIT_REPOSITORY "https://github.com/grimme-lab/mstore.git")
set(MSTORE_GIT_TAG "90fc6fc4d8a6c3d72e5a910347a45edabf65343c") # do not change manually!
dftbp_config_hybrid_dependency(mstore mstore::mstore "${HYBRID_CONFIG_METHODS}" "QUIET"
external/mstore "${exclude}" "${MSTORE_GIT_REPOSITORY}" "${MSTORE_GIT_TAG}")
#list(APPEND PKG_CONFIG_REQUIRES mstore)
endif()

set(TOML_F_GIT_REPOSITORY "https://github.com/toml-f/toml-f.git")
set(TOML_F_GIT_TAG "f066ec6e7fb96d8faf83ab6614ee664a26ad8d57") # do not change manually!
dftbp_config_hybrid_dependency(toml-f toml-f::toml-f "${HYBRID_CONFIG_METHODS}" "QUIET"
external/toml-f "${exclude}" "${TOML_F_GIT_REPOSITORY}" "${TOML_F_GIT_TAG}")
#list(APPEND PKG_CONFIG_REQUIRES toml-f)
if(INCLUDE_INDIRECT_DEPS)
set(TOML_F_GIT_REPOSITORY "https://github.com/toml-f/toml-f.git")
set(TOML_F_GIT_TAG "f066ec6e7fb96d8faf83ab6614ee664a26ad8d57") # do not change manually!
dftbp_config_hybrid_dependency(toml-f toml-f::toml-f "${HYBRID_CONFIG_METHODS}" "QUIET"
external/toml-f "${exclude}" "${TOML_F_GIT_REPOSITORY}" "${TOML_F_GIT_TAG}")
#list(APPEND PKG_CONFIG_REQUIRES toml-f)
endif()

set(S_DFTD3_GIT_REPOSITORY "https://github.com/awvwgk/simple-dftd3.git")
set(S_DFTD3_GIT_TAG "6623834fe0be9f6ed22f9c0cb1c61ea121753c28") # do not change manually!
set(S_DFTD3_GIT_TAG "02dead293e59408100eb382e97be56e2a03fb317") # do not change manually!
dftbp_config_hybrid_dependency(s-dftd3 s-dftd3::s-dftd3 "${HYBRID_CONFIG_METHODS}" "QUIET"
external/s-dftd3 "${exclude}" "${S_DFTD3_GIT_REPOSITORY}" "${S_DFTD3_GIT_TAG}")
#list(APPEND PKG_CONFIG_REQUIRES s-dftd3)
endif()

if(WITH_TBLITE)
set(MULTICHARGE_GIT_REPOSITORY "https://github.com/grimme-lab/multicharge.git")
set(MULTICHARGE_GIT_TAG "46ea4e370b1a59e01cc022d1f65c64bae8dbf968") # do not change manually!
dftbp_config_hybrid_dependency(multicharge multicharge::multicharge "${HYBRID_CONFIG_METHODS}" "QUIET"
external/multicharge "${exclude}" "${MULTICHARGE_GIT_REPOSITORY}" "${MULTICHARGE_GIT_TAG}")
#list(APPEND PKG_CONFIG_REQUIRES multicharge)

set(DFTD4_GIT_REPOSITORY "https://github.com/dftd4/dftd4.git")
set(DFTD4_GIT_TAG "b1faf68231d8b0fd44cf0701e9f27c8092bd7926") # do not change manually!
dftbp_config_hybrid_dependency(dftd4 dftd4::dftd4 "${HYBRID_CONFIG_METHODS}" "QUIET"
external/dftd4 "${exclude}" "${DFTD4_GIT_REPOSITORY}" "${DFTD4_GIT_TAG}")
#list(APPEND PKG_CONFIG_REQUIRES dftd4)
if(INCLUDE_INDIRECT_DEPS)
set(MULTICHARGE_GIT_REPOSITORY "https://github.com/grimme-lab/multicharge.git")
set(MULTICHARGE_GIT_TAG "46ea4e370b1a59e01cc022d1f65c64bae8dbf968") # do not change manually!
dftbp_config_hybrid_dependency(multicharge multicharge::multicharge "${HYBRID_CONFIG_METHODS}"
"QUIET" external/multicharge "${exclude}" "${MULTICHARGE_GIT_REPOSITORY}"
"${MULTICHARGE_GIT_TAG}")
#list(APPEND PKG_CONFIG_REQUIRES multicharge)
endif()

if(INCLUDE_INDIRECT_DEPS)
set(DFTD4_GIT_REPOSITORY "https://github.com/dftd4/dftd4.git")
set(DFTD4_GIT_TAG "f572723f5a5cb8243ea88b0253e182088311c6f3") # do not change manually!
dftbp_config_hybrid_dependency(dftd4 dftd4::dftd4 "${HYBRID_CONFIG_METHODS}" "QUIET"
external/dftd4 "${exclude}" "${DFTD4_GIT_REPOSITORY}" "${DFTD4_GIT_TAG}")
#list(APPEND PKG_CONFIG_REQUIRES dftd4)
endif()

set(TBLITE_GIT_REPOSITORY "https://github.com/tblite/tblite.git")
set(TBLITE_GIT_TAG "7bde301ead9b71e08f0ecc19390128f7209644d2") # do not change manually!
set(TBLITE_GIT_TAG "0542ce7ae0e323941156949a0620ca260bc0ce7f") # do not change manually!
dftbp_config_hybrid_dependency(tblite tblite::tblite "${HYBRID_CONFIG_METHODS}" "QUIET"
external/tblite "${exclude}" "${TBLITE_GIT_REPOSITORY}" "${TBLITE_GIT_TAG}")
#list(APPEND PKG_CONFIG_REQUIRES tblite)
Expand All @@ -262,7 +274,8 @@ endif()
if(WITH_CHIMES)
set(CHIMES_GIT_REPOSITORY "https://github.com/dftbplus/chimes_calculator.git")
set(CHIMES_GIT_TAG "98e365365d3b3e4b11b363b4a50dd2ad6cc825d4") # do not change manually!
dftbp_config_hybrid_dependency(ChimesCalc ChimesCalc::ChimesCalc_Fortran "${HYBRID_CONFIG_METHODS}" "QUIET"
dftbp_config_hybrid_dependency(ChimesCalc ChimesCalc::ChimesCalc_Fortran
"${HYBRID_CONFIG_METHODS}" "QUIET"
external/chimes "${exclude}" "${CHIMES_GIT_REPOSITORY}" "${CHIMES_GIT_TAG}")
endif()

Expand Down
51 changes: 41 additions & 10 deletions INSTALL.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ Requirements

In order to compile DFTB+, you need the following software components:

* Fortran 2003 compliant compiler
* Fortran compiler supporting Fortran 2008 and OpenMP 4.0

* C compiler

* C++ compiler (built with ELSI/PEXSI or ChIMES support)
* C++ compiler (when built with ELSI/PEXSI or ChIMES support)

* CMake (version 3.16 or newer)

Expand All @@ -27,6 +27,34 @@ In order to compile DFTB+, you need the following software components:
* Python (version >= 3.2) for the source preprocessor


Fortran compiler
----------------

The following Fortran compilers are known to build DFTB+ correctly:

* GNU >= 9

* Intel >= 19 or >= 2020 (when built to include the tblite library, as tblite is
known to produce incorrect results with Intel 19)

* NAG >= 7.1 (when built without OpenMP support)


The following Fortran compilers are known to fail to build DFTB+:

* NAG (when built with OpenMP support, unsupported OpenMP 4.0 constructs, last
tested version: 7.1)

* NVIDIA (internal compiler error & unsupported OpenMP 4.0 constructs, last
tested version: 22.3)


Older versions of the compilers above are likely to fail due to missing Fortran
features and/or compiler bugs. Compilers by other vendors may work, but have not
been tested extensively (see also `Tested build environments
<#tested-build-environments>`_ and `Testing DFTB+ <#testing-dftb>`_).


Optional extra dependencies
---------------------------

Expand Down Expand Up @@ -87,7 +115,7 @@ following architectures:
+---------------+----------------------+-------------+------------------+-----+
| Architecture | Compiler | MPI | Ext. libraries |Notes|
+===============+======================+=============+==================+=====+
| x86_64 / | GNU Fortran/C 8.4 | OpenMPI 3.1 | OpenBlas 0.3.7, | |
| x86_64 / | GNU Fortran/C 9.2 | OpenMPI 4.0 | OpenBlas 0.3.7, | |
| Linux | | | ScaLAPACK 2.1 | |
| | | | ELSI 2.6.1 | |
+---------------+----------------------+-------------+------------------+-----+
Expand All @@ -98,20 +126,16 @@ following architectures:
| x86_64 / | Intel Fortran/C 19.0 | MPICH 3.3 | MKL 19.0 | |
| Linux | | | ELSI 2.6.1 | |
+---------------+----------------------+-------------+------------------+-----+
| x86_64 / | NAG Fortran 7.0 | MPICH 3.3 | OpenBlas 0.3.7 | [1] |
| x86_64 / | NAG Fortran 7.1 | MPICH 3.4 | OpenBlas 0.3.18 | [1] |
| Linux | GNU C 9.2 | | ScaLAPACK 2.1 | |
| | | | ELSI 2.5.0 | |
+---------------+----------------------+-------------+------------------+-----+
| x86_64 / | GNU Fortran/C 9.4 | -- | OpenBlas 0.3.18 | [2] |
| x86_64 / | GNU Fortran/C 9.4 | -- | OpenBlas 0.3.20 | [2] |
| OS X | | | | |
+---------------+----------------------+-------------+------------------+-----+

All builds are also tested with the optional ARPACK-NG 3.7 and PLUMED 2.5
libraries.

Notes:

[1] Only Debug build is tested regulary with OpenMP turned off.
[1] Only Debug build is tested regulary with OpenMP turned off and without ELSI.
[2] Only partial testing of the serial version.


Expand Down Expand Up @@ -148,6 +172,13 @@ include the Slater-Koster (slako) data for testing the compiled code.
For more information see the detailed help for this tool by issuing
``./utils/get_opt_externals -h``.

Slater-Koster file locations
^^^^^^^^^^^^^^^^^^^^^^^^^^^^

The DFTB+ code checks the shell variable `DFTBPLUS_PARAM_DIR` when
setting the path to check the Prefix keyword for finding data. If
unset, it assumes the local directory as the starting path.


Building
========
Expand Down
24 changes: 20 additions & 4 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,28 @@ management framework using `Miniconda
``conda-forge`` channel in order to be able to access DFTB+. (Please consult the
conda documentation for how to set-up your conda environment.)

We provide several build variants (mpi, non-mpi), choose the one suiting your
needs. For example, by issuing ::
We recommend the use of the `mamba installer <https://mamba.readthedocs.io/>`_,
as we have experienced dependency resolution problems with the original conda
installer in the past::

conda install 'dftbplus=*=nompi_*'
conda install -n base mamba

you obtain the latest stable non-MPI version of DFTB+.
We provide several build variants, choose the one suiting your needs. For
example, by issuing ::

mamba install 'dftbplus=*=nompi_*'

or ::

mamba install 'dftbplus=*=mpi_mpich_*'

or ::

mamba install 'dftbplus=*=mpi_openmpi_*'

to get the last stable release of DFTB+ with, respectively,
serial (OpenMP-threaded) build or with MPI-parallelized build using either the
MPICH or the Open MPI framework.


Downloading the binary
Expand Down
14 changes: 10 additions & 4 deletions app/misc/units/printunits.F90
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,24 @@

!> Printing out the conversion factors for the different units
program printunits
use dftbp_common_unitconversion
use dftbp_common_constants
use dftbp_common_unitconversion, only : lengthUnits, inverseLengthUnits, energyUnits, forceUnits,&
& timeUnits, freqUnits, volumeUnits, chargeUnits, eFieldUnits, bFieldUnits, pressureUnits,&
& velocityUnits, dipoleUnits, massUnits, angularUnits, massDensityUnits, TUnit
implicit none

type(TUnit) :: localUnit
integer :: ii

write(*,*)"Convert from unit to a.u. by multiplying with"
#:for names, units in CONVERSIONS
write(*,*)
write(*,"(A)")"${names}$:"
write(*,"(a)")"${names}$:"
do ii = 1, size(${units}$)
write(*,"(1X,A20,E24.15)") ${units}$(ii)%name, ${units}$(ii)%convertValue
! Workaround: nag 7.1
! Can not print derived type, if part of an array
! write(*,"(1x,dt)") ${units}$(ii)
localUnit = ${units}$(ii)
write(*,"(1x,dt)") localUnit
end do
#:endfor

Expand Down
Loading

0 comments on commit 8396646

Please sign in to comment.