[CP2K:8332] BAND_STRUCTURE k-point unit conversion bug leads to bogus band structures (CP2K 4.1)

hut... at chem.uzh.ch hut... at chem.uzh.ch
Thu Nov 3 08:09:10 UTC 2016


Dear Eric

thank you very much for reporting this bug. We will try to fix it
as soon as possible.

regards

Juerg
--------------------------------------------------------------
Juerg Hutter                         Phone : ++41 44 635 4491
Institut für Chemie C                FAX   : ++41 44 635 6838
Universität Zürich                   E-mail: hut... at chem.uzh.ch
Winterthurerstrasse 190
CH-8057 Zürich, Switzerland
---------------------------------------------------------------

-----cp... at googlegroups.com wrote: -----To: cp2k <cp... at googlegroups.com>
From: Eric Hermes 
Sent by: cp... at googlegroups.com
Date: 11/01/2016 09:35PM
Subject: [CP2K:8332] BAND_STRUCTURE k-point unit conversion bug leads to bogus band structures (CP2K 4.1)

Hello,
I am working with ASE to develop routines for the various DFT calculators we support for simple, automatic generation of band structures. I have run into a bug in CP2K's SPECIAL_POINT specification, wherein the specified k-points appear to undergo a redundant B_VECTOR -> CART_BOHR unit conversion. What I mean by that is if I pass the k-points as multiples of the reciprocal unit vectors (i.e. UNIT B_VECTOR, SPECIAL_POINT 0.5 0.25 0.75 for the W point of the diamond lattice), this is multiplied by the reciprocal unit cell vector *twice*. If I pass the points in units of 2pi/Bohr (i.e. UNIT CART_BOHR, SPECIAL_POINT 0.049 0.098 0.000 for a primitive Si diamond lattice with lattice constant a=5.4 angstrom), the k-points are multiplied by the reciprocal unit cell vector *anyway*, giving the same results as before. I can "trick" the system into providing the correct result by saying that I am passing the k-points in 2pi/Bohr, but actually passing the k-points in multiples of the reciprocal unit cell vectors (i.e. UNIT CART_BOHR, SPECIAL_POINT 0.5 0.25 0.75). This results in both the output file and the band structure file printing the exact k-points that I specified (i.e. the k-points in multiples of the reciprocal unit vectors), and the resulting band structure matches that of other DFT codes.
Here is an example of the input file I am using that expresses the bug: https://gist.github.com/ehermes/7ef3d7249b99eeafb34bb14e6c51fd48This input file was generated by (a modified version of) ASE, and it produces the incorrect band structure. If line 31 is changed to read "UNITS CART_BOHR", the resulting band structure is correct and matches the band structure produced by other codes (GPAW, VASP, etc).
I have taken a look at the qs_band_structure.F source file, but the origin of the bug is not obvious to me. I suspect it might be related to line 197, which multiplies each kpoint by the transpose of the unit cell vector, but I am not certain.



-- 

You received this message because you are subscribed to the Google Groups "cp2k" group.

To unsubscribe from this group and stop receiving emails from it, send an email to cp2k+uns... at googlegroups.com.

To post to this group, send email to cp... at googlegroups.com.

Visit this group at https://groups.google.com/group/cp2k.

For more options, visit https://groups.google.com/d/optout.





More information about the CP2K-user mailing list