Skip to content

Commit

Permalink
Merge branch 'correct_degauss' into 'develop'
Browse files Browse the repository at this point in the history
using Ha units for degauss in the xml file

See merge request QEF/q-e!698
  • Loading branch information
giannozz committed Dec 5, 2019
2 parents cbbed67 + a9698a6 commit 72afe45
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
8 changes: 4 additions & 4 deletions PW/src/pw_init_qexsd_input.f90
Original file line number Diff line number Diff line change
Expand Up @@ -351,18 +351,18 @@ SUBROUTINE pw_init_qexsd_input(obj,obj_tagname)
IF (tf_inp) THEN
SELECT CASE (ip_nspin)
CASE (2)
CALL qexsd_init_bands(obj%bands, nbnd_pt, smearing_loc, degauss, &
CALL qexsd_init_bands(obj%bands, nbnd_pt, smearing_loc, degauss/e2, &
ip_occupations, tot_charge, ip_nspin, &
input_occupations=f_inp(:,1),input_occupations_minority=f_inp(:,2))
CASE default
CALL qexsd_init_bands(obj%bands, nbnd_pt, smearing_loc, degauss, &
CALL qexsd_init_bands(obj%bands, nbnd_pt, smearing_loc, degauss/e2, &
ip_occupations, tot_charge, ip_nspin, input_occupations=f_inp(:,1) )
END SELECT
ELSE
IF ( tot_magnetization .LT. 0 ) THEN
CALL qexsd_init_bands(obj%bands, nbnd_pt, smearing_loc, degauss, ip_occupations, tot_charge, ip_nspin)
CALL qexsd_init_bands(obj%bands, nbnd_pt, smearing_loc, degauss/e2, ip_occupations, tot_charge, ip_nspin)
ELSE
CALL qexsd_init_bands(obj%bands, nbnd_pt, smearing_loc, degauss, ip_occupations, tot_charge, ip_nspin, &
CALL qexsd_init_bands(obj%bands, nbnd_pt, smearing_loc, degauss/e2, ip_occupations, tot_charge, ip_nspin, &
TOT_MAG = tot_magnetization)
END IF
END IF
Expand Down
3 changes: 2 additions & 1 deletion PW/src/pw_restart_new.f90
Original file line number Diff line number Diff line change
Expand Up @@ -535,7 +535,7 @@ SUBROUTINE pw_write_schema( only_init, wf_collect )
smear_obj = qexsd_input_obj%bands%smearing
ELSE
smearing_loc = schema_smearing( smearing )
CALL qexsd_init_smearing(smear_obj, smearing_loc, degauss)
CALL qexsd_init_smearing(smear_obj, smearing_loc, degauss/e2)
END IF
smear_obj_ptr => smear_obj
END IF
Expand Down Expand Up @@ -1071,6 +1071,7 @@ SUBROUTINE read_xml_file ( wfc_is_collected )
CALL qexsd_copy_kpoints( output_obj%band_structure, &
nks_start, xk_start, wk_start, nk1, nk2, nk3, k1, k2, k3, &
occupations, smearing, degauss )
degauss = degauss * e2
!
CALL set_occupations( occupations, smearing, degauss, &
lfixed, ltetra, tetra_type, lgauss, ngauss )
Expand Down

0 comments on commit 72afe45

Please sign in to comment.