Skip to content

Commit

Permalink
quick update raritan
Browse files Browse the repository at this point in the history
  • Loading branch information
kfgarrity committed Sep 17, 2024
1 parent c5c5061 commit 50b9307
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions src/SCF.jl
Original file line number Diff line number Diff line change
Expand Up @@ -572,13 +572,13 @@ Solve for scf energy, also stores the updated electron density and h1 inside the
push!(rho_in, e_denA)
# println("iter $iter add rho_in $(length(rho_in))")
#println("calc_energy")
if use_sym
@time if use_sym
# println("hk3 ", size(hk3), " " , typeof(hk3))
# println("sk3 ", size(sk3), " " , typeof(sk3))
# println("nelec ", tbc.nelec)


energy_band , efermi, e_den_NEW, VECTS, VALS, error_flag = calc_energy_charge_fft_band2_sym(hk3, sk3, tbc.nelec, smearing=smearingA, h1=h1, h1spin = h1spin, DEN=DEN_w, VECTS=VECTS_w, SK = SK_w, nk_red=nk_red, grid_ind=grid_ind, kweights=kweights)
energy_band , efermi, e_den_NEW, VECTS, VALS, error_flag = calc_energy_charge_fft_band2_sym(hk3, sk3, tbc.nelec, smearing=smearingA, h1=h1, h1spin = h1spin, DEN=DEN_w, VECTS=VECTS_w, SK = SK_w, nk_red=nk_red, grid_ind=grid_ind, kweights=kweights)

# push!(DenMat, denmat)
# push!(HK, hk)
Expand Down
14 changes: 7 additions & 7 deletions src/TB.jl
Original file line number Diff line number Diff line change
Expand Up @@ -4494,8 +4494,8 @@ end

function calc_energy_charge_fft_band2_sym(hk3, sk3, nelec; smearing=0.01, h1 = missing, h1spin=missing, VECTS=missing, DEN=missing, SK = missing, nk_red=nk_red, grid_ind=[1 1 1], kweights = [2.0] )

#println("begin")
begin
println("begin")
@time begin
thetype=typeof(real(sk3[1,1,1,1,1]))

# println("size ", size(hk3))
Expand Down Expand Up @@ -4568,13 +4568,13 @@ function calc_energy_charge_fft_band2_sym(hk3, sk3, nelec; smearing=0.01, h1 = m
end


#println("go eig time")
go_eig_sym(grid, nspin,nspin_ham, VALS, VALS0, VECTS, sk3, hk3, h1, h1spin, SK, nk_red,grid_ind)
println("go eig time")
@time go_eig_sym(grid, nspin,nspin_ham, VALS, VALS0, VECTS, sk3, hk3, h1, h1spin, SK, nk_red,grid_ind)

# println("VALS ", VALS)
# println("VALS0 ", VALS0)

begin
@time begin

if nelec > 1e-10
# println("VALS ", VALS[1,:,1])
Expand Down Expand Up @@ -4605,8 +4605,8 @@ function calc_energy_charge_fft_band2_sym(hk3, sk3, nelec; smearing=0.01, h1 = m

#println("nelec $nelec")

#println("chargeden")
if nelec > 1e-10
println("chargeden")
@time if nelec > 1e-10
chargeden = go_charge15_sym(VECTS, SK, occ, nspin, max_occ, rDEN, iDEN, rv, iv, nk_red,grid_ind, kweights)
else
chargeden = zeros(nspin, nwan)
Expand Down

0 comments on commit 50b9307

Please sign in to comment.