# C in diamond structure. 
# Very rough 2x2x2 q-point grid; low ecut.

ndtset 4

getwfk   20      # Read GS wavefunctions from DS20_WFK
getddb   20      # Read DDB files from DS20_DDB

# Global parameters.
ecut   20
ecutsm 0.5
tolwfr 1e-16
istwfk *1
prtphdos 0

# K-mesh (must equal the one used to produce the WFK file)
ngkpt    4 4 4
nshiftk  1
shiftk   0.0 0.0 0.0

ddb_ngqpt 2 2 2  # q-mesh used to produce the DDB file (must be consistent with DDB data)

############
# EPH related parameters
############
symsigma  1

optdriver  7
nband      8
eph_task   -4
tmesh 5 295 2
eph_extrael 1e-6
occopt 3

gw_qprange 2
eph_intmeth 1

###########
# Use of the two-grids technique
###########
getwfkfine_filepath1 "t50o_DS6_WFK"
getwfkfine_filepath2 "t50o_DS6_WFK"
eph_intmeth2 2

bs_interp_kmult3 2 2 2
bs_interp_kmult4 2 2 2
eph_intmeth4 2

# Structure 
acell 3*6.70346805
rprim 0 .5 .5 .5 0 .5 .5 .5 0
natom 2
typat 1 1
xred 3*0.0 3*0.25
ntypat  1
znucl 6

 pp_dirpath "$ABI_PSPDIR"
 pseudos "PseudosTM_pwteter/6c.pspnc"

#%%<BEGIN TEST_INFO>
#%% [setup]
#%% executable = abinit
#%% test_chain = t50.abi, t51.abi, t52.abi, t53.abi, t54.abi, t55.abi, t56.abi
#%% [files]
#%% files_to_test = 
#%%   t55.abo, tolnlines = 150, tolabs = 400, tolrel = 7.2e-2
#%% [paral_info]
#%% max_nprocs = 10
#%% [extra_info]
#%% authors = G. Brunin, M. Giantomassi
#%% keywords = NC, DFPT, EPH, RTA
#%% description = 
#%%   Calculation of the imaginary part of the Fan-Migdal self-energy matrix elements.
#%%   Use of the two-grids technique
#%%<END TEST_INFO>
