11"""
22 entropy(state, [site::Int])
33
4- Calculate the Von Neumann entanglement entropy of a given MPS. If an integer `site` is
4+ Calculate the von Neumann entanglement entropy of a given MPS. If an integer `site` is
55given, the entropy is across the entanglement cut to the right of site `site`. Otherwise, a
66vector of entropies is returned, one for each site.
77"""
@@ -85,7 +85,7 @@ overlap of a given `above` state and a `below` state. The `sector` keyword argum
8585used to specify a non-trivial total charge for the transfer matrix eigenvectors.
8686Specifically, an auxiliary space `ℂ[typeof(sector)](sector => 1)'` will be added to the
8787domain of each eigenvector. The `tol` and `num_vals` keyword arguments are passed to
88- `KrylovKit.eigolve `
88+ `KrylovKit.eigsolve `
8989"""
9090function transfer_spectrum (
9191 above:: InfiniteMPS ; below = above, tol = Defaults. tol, num_vals = 20 ,
@@ -110,15 +110,16 @@ function transfer_spectrum(
110110end
111111
112112"""
113- entanglement_spectrum(ψ, site::Int) -> SectorDict{ sectortype(ψ),Vector{<:Real }}
113+ entanglement_spectrum(ψ, site::Int) -> SectorVector{T, sectortype(ψ), AbstractVector{T }}
114114
115115Compute the entanglement spectrum at a given site, i.e. the singular values of the gauge
116- matrix to the right of a given site. This is a dictionary mapping the charge to the singular
117- values.
116+ matrix to the right of a given site. This is a vector containing the singular
117+ values. The contributions from specific sectors can be viewed by indexing accordingly, i.e.
118+ `entanglement_spectrum(ψ, site)[sector]`.
118119
119120For `InfiniteMPS` and `WindowMPS` the default value for `site` is 0.
120121
121- For `FiniteMPS` no default value for `site` is given, it is up to the user to specify.
122+ For `FiniteMPS` no default value for `site` is given; it is up to the user to specify.
122123"""
123124function entanglement_spectrum (st:: Union{InfiniteMPS, WindowMPS} , site:: Int = 0 )
124125 checkbounds (st, site)
0 commit comments