# Crystalline silicon
# Calculation of the GW corrections

ndtset      10
udtset      5  2

# Convergence with respect to the number of bands to calculate epsilon^-1
nband11  25
nband21  50
nband31  100
nband41  150
nband51  200

# Calculation of the screening (epsilon^-1 matrix)
optdriver?1  3
ecuteps      6.0

# Calculation of the Self-Energy matrix elements (GW corrections)
optdriver?2  4
getscr?2     -1
ecutsigx     8.0
nband?2      100
nkptgw?2      1
kptgw?2      0.000    0.000    0.000
bdgw?2       4  5 

getwfk       2
ppmfrq      16.7 eV

# Definition of the unit cell: fcc
acell  3*10.26         # Experimental lattice constants
rprim  0.0  0.5  0.5   # FCC primitive vectors (to be scaled by acell)
       0.5  0.0  0.5
       0.5  0.5  0.0

# Definition of the atom types
ntypat  1         # There is only one type of atom
znucl 14          # The keyword "znucl" refers to the atomic number of the
                  # possible type(s) of atom. The pseudopotential(s)
                  # mentioned in the "files" file must correspond
                  # to the type(s) of atom. Here, the only type is Silicon.

# Definition of the atoms
natom 2           # There are two atoms
typat  1 1        # They both are of type 1, that is, Silicon.
xred              # Reduced coordinate of atoms
      0.0  0.0  0.0
      0.25 0.25 0.25

# Definition of the planewave basis set (at convergence 16 Rydberg 8 Hartree)
ecut 8.0          # Maximal kinetic energy cut-off, in Hartree


# Sampling of the BZ
ngkpt   2 2 2
nshiftk 1
shiftk  0.0 0.0 0.0
istwfk  *1         # This is mandatory in all the GW steps.


 pp_dirpath "$ABI_PSPDIR"
 pseudos "Pseudodojo_nc_sr_04_pbe_standard_psp8/Si.psp8"

##############################################################
# This section is used only for regression testing of ABINIT #
##############################################################
#%%<BEGIN TEST_INFO>
#%% [setup]
#%% executable = abinit
#%% exclude_builders = .*_nag_7.0_.*
#%% test_chain = tgw1_2.abi, tgw1_3.abi, tgw1_4.abi, tgw1_5.abi
#%% [files]
#%% files_to_test = 
#%%   tgw1_4.abo, tolnlines= 70, tolabs=  7.000e-02, tolrel=  3.000e-02
#%% [paral_info]
#%% max_nprocs = 4
#%% [extra_info]
#%% authors = Unknown
#%% keywords = GW
#%% description = 
#%%   Crystalline silicon
#%%   Calculation of the GW corrections
#%%<END TEST_INFO>
