@@ -180,9 +180,7 @@ function Base.iterate(it::TimeEvolver{<:SimpleUpdate}, state = it.state)
180180end
181181
182182"""
183- timestep(
184- it::TimeEvolver{<:SimpleUpdate}, psi::InfiniteState, env::SUWeight
185- ) -> (psi, env, info)
183+ $(SIGNATURES)
186184
187185Given the `TimeEvolver` iterator `it`, perform one step of time evolution
188186on the input state `psi` and its environment `env`.
@@ -202,17 +200,10 @@ function MPSKit.timestep(
202200end
203201
204202"""
205- time_evolve(
206- it::TimeEvolver{<:SimpleUpdate};
207- tol::Float64 = 0.0, check_interval::Int = 500
208- ) -> (psi, env, info)
203+ $(SIGNATURES)
209204
210205Perform time evolution to the end of `TimeEvolver` iterator `it`,
211- or until convergence of `SUWeight` set by a positive `tol`.
212-
213- - Setting `tol > 0` enables convergence check (for imaginary time evolution of InfinitePEPS only).
214- For other usages it should not be changed.
215- - `check_interval` sets the number of iterations between outputs of information.
206+ `check_interval` sets the number of iterations between outputs of information.
216207"""
217208function MPSKit. time_evolve (
218209 it:: TimeEvolver{<:SimpleUpdate} ; check_interval:: Int = 500
@@ -243,13 +234,20 @@ function MPSKit.time_evolve(
243234 return
244235end
245236
237+ """
238+ $(SIGNATURES)
239+
240+ Perform time evolution until convergence of `TimeEvolver` iterator `it`.
241+ For `SimpleUpdate`, convergence is determined by the change of `SUWeight`
242+ between two iterations being smaller than `tol`.
243+ """
246244function MPSKit. time_evolve (
247- it:: TimeEvolver{<:SimpleUpdate} , H:: LocalOperator ;
245+ it:: TimeEvolver{<:SimpleUpdate, G, S } , H:: LocalOperator ;
248246 tol:: Float64 = 1.0e-8 , check_interval:: Int = 500
249- )
247+ ) where {G, S <: SUState{<:InfinitePEPS} }
250248 time_start = time ()
251249 @info " --- Time evolution (simple update), dt = $(it. dt) ---"
252- @assert ( it. state . psi isa InfinitePEPS) && it . alg. imaginary_time " Only imaginary time evolution of InfinitePEPS allows convergence checking."
250+ @assert it. alg. imaginary_time " Only imaginary time evolution allows convergence checking."
253251 env0, time0 = it. state. env, time ()
254252 for (psi, env, info) in it
255253 iter = it. state. iter
0 commit comments