If you want to modify the BerkeleyGW package, it is wise to compare the outputs of new code (exchange integrals, transition matrix elements, orbital moments...) with published results. I recently wrote a routine for which the most obvious comparison was an analytical result for the hydrogenic single-particle wavefunctions
The DFT wavefunctions typically used as inputs in BerkeleyGW would be insufficiently accurate for this purpose due to self-interaction error, so I instead implemented the exact form of the hydrogen wavefunctions in the BerkeleyGW WFN.h5 format. As BerkeleyGW stores the wavefunctions in plane wave components, this required the momentum-space representation of the hydrogen wavefunctions:[1]
The python script in this repository can be run as write_hydrogen_wfns.py [WFNfilename] [nbnd < 18] and it will populate an existing BerkeleyGW WFN.h5 file with the first nbnd spinor wavefunctions for a hydrogen atom at the origin, in the order:
The file WFN_small.h5 contains one band and can be run with the command above to generate the number of states needed. It was generated from a calculation in Quantum ESPRESSO with a 100 Ry plane-wave cutoff in a 20 Å nspin=4) and have only the
[1] Bransden, B. H., Joachain, C. J. (1983). Physics of atoms and molecules. pp 621. United Kingdom: Longman.