Skip to content

Commit

Permalink
fixed a bug in AHC calculation when there are degenerate bands
Browse files Browse the repository at this point in the history
  • Loading branch information
quanshengwu committed Feb 24, 2022
1 parent 78c1f92 commit 27923f5
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/berrycurvature.f90
Original file line number Diff line number Diff line change
Expand Up @@ -451,7 +451,9 @@ subroutine get_Dmn_Ham(W, velocity_Ham, Dmn_Ham)
do i=1, 3
do n=1, Num_wann
do m=1, Num_wann
Dmn_Ham(m,n,i)=velocity_Ham(m,n,i)/(W(n)-W(m))
if (abs(W(n)-W(m))>eps12) then
Dmn_Ham(m,n,i)=velocity_Ham(m,n,i)/(W(n)-W(m))
endif
enddo
Dmn_Ham(n, n, i)=zzero
enddo
Expand Down

0 comments on commit 27923f5

Please sign in to comment.