Simulations

Setup and running

TimeEvolutionPEPO.SimulationType
struct Simulation{E<:TimeEvolutionPEPO.AbstractTimeEvolution, P<:AbstractPEPO, L<:TimeEvolutionPEPO.AbstractTimeStepper, M, T}

Concrete type representing mutable state of a simulation. Note, the fields of Simulation are internal and not part of the public API.

Constructors

Simulation(pepo::PEPO, model, method::AbstractMethod; timestep::Float64, kwargs...)

Initialise a Simulation of the model model using method with initial quantum state defined by pepo. A timestep must be supplied as a keyword argument. An addition, the following optional keywords can also be used:

Optional Keywords

  • order::Int=1: order of the trotter decomposition (if any).
  • storeall::Bool=true: this should be set to false if one does not wish to store objects that can be reconstructed; useful if, for example, very large tensors are used for the time evolution. Repeated calls to simulate! will be slower if this is set to true.

See also: simulate!

source
TimeEvolutionPEPO.simulate!Function
simulate([callback = identity], sim::Simulation; numsteps::Int, kwargs...)

Run the simulation defined in sim for numsteps iterations. Note, numsteps is a keyword argument. The callable callback takes a single argument, the sim object itself and is executed during every shot (default behaviour results in a shot at the end of each step).

Optional Keywords

  • breaktol::Integer=0.0: break the simulation when convergence falls below this value.
  • maxshots::Integer=numsteps: callback will be executed at most maxshots number of times at evenly spaced intervals throughout the time evolution
  • maxtime::Float64=Inf: maximum wall clock time allowed. If the wall clock time since the start simulate was called exceeds this value, then no more iterations occur.
  • numinit::Integer=0: skip this many iterations. Useful if you are resuming a simulation but wish to maintain the same sot schedule
  • verbose::Bool=true: if true, log simulation progress at the @info log level

See also: Simulation.

source

Accessing data

Updating parameters