File tree Expand file tree Collapse file tree 7 files changed +75
-0
lines changed Expand file tree Collapse file tree 7 files changed +75
-0
lines changed Original file line number Diff line number Diff line change 1+ INPUT_PARAMETERS
2+ #Parameters (1.General)
3+ suffix autotest
4+ calculation scf
5+ ntype 1
6+ nbands 6
7+ symmetry 1
8+ pseudo_dir ../tools/PP_ORB/
9+ pseudo_type upf201
10+
11+ #Parameters (2.Iteration)
12+ ecutwfc 20
13+ scf_thr 1e-9
14+ scf_nmax 100
15+
16+ #Parameters (3.Basis)
17+ basis_type pw
18+
19+ out_wfc_pw 1
Original file line number Diff line number Diff line change 1+ K_POINTS
2+ 0
3+ Gamma
4+ 1 1 1 0 0 0
Original file line number Diff line number Diff line change 1+ ATOMIC_SPECIES
2+ Si 14 Si_ONCV_PBE-1.0.upf
3+
4+ LATTICE_CONSTANT
5+ 10.2 // add lattice constant
6+
7+ LATTICE_VECTORS
8+ 0.5 0.5 0.0
9+ 0.5 0.0 0.5
10+ 0.0 0.5 0.5
11+
12+ ATOMIC_POSITIONS
13+ Direct
14+
15+ Si // Element type
16+ 0.0 // magnetism
17+ 2
18+ 0.00 0.00 0.00 1 1 1
19+ 0.25 0.25 0.25 1 1 1
Original file line number Diff line number Diff line change 1+ test the output of wfc_pw, and verify the maximum absolute coefficient
Original file line number Diff line number Diff line change 1+ etotref -197.1405644352783
2+ etotperatomref -98.5702822176
3+ Max_wfc_1 0.9587
4+ Max_wfc_2 0.4464
5+ Max_wfc_3 0.3321
6+ Max_wfc_4 0.4181
7+ Max_wfc_5 0.4838
8+ Max_wfc_6 0.4048
9+ totaltimeref 0.17714
Original file line number Diff line number Diff line change 3030107_PW_OB_outputbands
3131107_PW_OD_outputdos
3232107_PW_outWfcR
33+ 107_PW_outWfcPw
3334108_PW_RE
3435108_PW_RE_MB
3536108_PW_RE_MG
Original file line number Diff line number Diff line change @@ -37,6 +37,7 @@ deepks_out_labels=`grep deepks_out_labels INPUT | awk '{print $2}' | sed s/[[:sp
3737deepks_bandgap=` grep deepks_bandgap INPUT | awk ' {print $2}' | sed s/[[:space:]]//g`
3838has_lowf=` grep out_wfc_lcao INPUT | awk ' {print $2}' | sed s/[[:space:]]//g`
3939has_wfc_r=` grep out_wfc_r INPUT | awk ' {print $2}' | sed s/[[:space:]]//g`
40+ has_wfc_pw=` grep out_wfc_pw INPUT | awk ' {print $2}' | sed s/[[:space:]]//g`
4041gamma_only=` grep gamma_only INPUT | awk ' {print $2}' | sed s/[[:space:]]//g`
4142# echo $running_path
4243base=` grep -En ' (^|[[:space:]])basis_type($|[[:space:]])' INPUT | awk ' {print $2}' | sed s/[[:space:]]//g`
@@ -133,6 +134,27 @@ if ! test -z "$has_wfc_r" && [ $has_wfc_r -eq 1 ]; then
133134 done
134135fi
135136
137+ # echo "$has_wfc_pw" ## test out_wfc_pw > 0
138+ if ! test -z " $has_wfc_pw " && [ $has_wfc_pw -eq 1 ]; then
139+ if [[ ! -f OUT.autotest/WAVEFUNC1.txt ]]; then
140+ echo " Can't find file OUT.autotest/WAVEFUNC1.txt"
141+ exit 1
142+ fi
143+ awk ' BEGIN {max=0;read=0;band=1}
144+ {
145+ if(read==0 && $2 == "Band" && $3 == band){read=1}
146+ else if(read==1 && $2 == "Band" && $3 == band)
147+ {printf"Max_wfc_%d %.4f\n",band,max;read =0;band+=1;max=0}
148+ else if(read==1)
149+ {
150+ for(i=1;i<=NF;i++)
151+ {
152+ if(sqrt($i*$i)>max) {max=sqrt($i*$i)}
153+ }
154+ }
155+ }' OUT.autotest/WAVEFUNC1.txt >> $1
156+ fi
157+
136158# echo "$has_lowf" ## test out_wfc_lcao > 0
137159if ! test -z " $has_lowf " && [ $has_lowf -eq 1 ]; then
138160 if ! test -z " $gamma_only " && [ $gamma_only -eq 1 ]; then
You can’t perform that action at this time.
0 commit comments