Skip to content

Commit

Permalink
aesthetics
Browse files Browse the repository at this point in the history
  • Loading branch information
abhirup-m committed Nov 5, 2024
1 parent acb7c10 commit 0a7ee24
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/correlations.jl
Original file line number Diff line number Diff line change
Expand Up @@ -282,9 +282,11 @@ function SpecFunc(
energyGs = minimum(eigVals)
specFunc = 0 .* freqValues

for groundState in eigVecs[eigVals .≤ energyGs + abs(energyGs) * degenTol]
degenerateManifold = eigVals .≤ energyGs + abs(energyGs) * degenTol
println("Degeneracy = ", length(eigVals[degenerateManifold]), "; Range=[$(eigVals[degenerateManifold][1]), $(eigVals[degenerateManifold][end])]")
@showprogress for groundState in eigVecs[degenerateManifold]
spectralWeights = [(0.,0.) for _ in eigVecs]
@showprogress Threads.@threads for index in eachindex(eigVecs)
Threads.@threads for index in eachindex(eigVecs)
excitedState = eigVecs[index]
spectralWeights[index] = ((groundState' * probes["destroy"] * excitedState) * (excitedState' * probes["create"] * groundState),
(excitedState' * probes["destroy"] * groundState) * (groundState' * probes["create"] * excitedState)
Expand Down

0 comments on commit 0a7ee24

Please sign in to comment.