Skip to content

Commit 50d2c94

Browse files
committed
be happy with anything that acts like a vector
1 parent b88c9b2 commit 50d2c94

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/algorithms/toolbox.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ function marek_gap(above::InfiniteMPS; tol_angle = 0.1, kwargs...)
151151
return marek_gap(spectrum; tol_angle)
152152
end
153153

154-
function marek_gap(spectrum::Vector{T}; tol_angle = 0.1) where {T <: Number}
154+
function marek_gap(spectrum::AbstractVector{T}; tol_angle = 0.1) where {T <: Number}
155155
# Remove 1s from the spectrum
156156
inds = findall(abs.(spectrum) .< 1 - 1.0e-12)
157157
length(spectrum) - length(inds) < 2 || @warn "Non-injective mps?"
@@ -187,7 +187,7 @@ function correlation_length(above::InfiniteMPS; kwargs...)
187187
return 1 / ϵ
188188
end
189189

190-
function correlation_length(spectrum::Vector{T}; kwargs...) where {T <: Number}
190+
function correlation_length(spectrum::AbstractVector{T}; kwargs...) where {T <: Number}
191191
ϵ, = marek_gap(spectrum; kwargs...)
192192
return 1 / ϵ
193193
end

0 commit comments

Comments
 (0)