File tree Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -248,6 +248,7 @@ spectrum_correlation_fft
248248spectrum
249249ExponentialSeries
250250PseudoInverse
251+ Lanczos
251252```
252253
253254## [ Entropy and Metrics] (@id doc-API: Entropy-and-Metrics )
Original file line number Diff line number Diff line change @@ -59,6 +59,7 @@ S(\omega) = \int_{-\infty}^\infty \lim_{t \rightarrow \infty} \left\langle \hat{
5959See also the following list for `SpectrumSolver` docstrings:
6060- [`ExponentialSeries`](@ref)
6161- [`PseudoInverse`](@ref)
62+ - [`Lanczos`](@ref)
6263"""
6364function spectrum (
6465 H:: QuantumObject{HOpType} ,
@@ -228,7 +229,8 @@ function _spectrum(
228229 # Loop over the Krylov subspace(s)
229230 for k in 1 : solver. maxiter
230231 # k-th diagonal element
231- Ξ±β = (wβ * L. data) * vβ
232+ wββ = wβ * L. data
233+ Ξ±β = wββ * vβ
232234
233235 # Update A(k), B(k) and continuous fraction; normalization avoids overflow
234236 Aβ .= (- 1im .* ΟList .+ Ξ±β) .* Aββ .- (Ξ²β * Ξ΄β) .* Aββ
@@ -257,8 +259,9 @@ function _spectrum(
257259
258260 # (k+1)-th left/right vectors, orthogonal to previous ones
259261 # Consider using explicit BLAS calls
260- vββ .= L. data * vβ .- Ξ±β .* vβ .- Ξ²β .* vββ
261- wββ .= wβ * L. data .- Ξ±β .* wβ .- Ξ΄β .* wββ
262+ vββ = L. data * vβ
263+ vββ .= vββ .- Ξ±β .* vβ .- Ξ²β .* vββ
264+ wββ .= wββ .- Ξ±β .* wβ .- Ξ΄β .* wββ
262265 vββ .= vβ
263266 wββ .= wβ
264267 vβ .= vββ
You canβt perform that action at this time.
0 commit comments