diff --git a/docs/dev/index.html b/docs/dev/index.html index c75f9ba..0459209 100644 --- a/docs/dev/index.html +++ b/docs/dev/index.html @@ -1,2 +1,2 @@ -Developers · MPSDynamics.jl

Developers

Simulation Workflow

Flowchart of the simulation workflow

How to Contribute

Contributions are welcome! Don't hesitate to contact us if you

  • found a bug;
  • have a suggestion on how to improve the code and/or documentation;
  • would like to get involved in writing code and/or documentation.

You can contact us by raising an issue on Github, or by writing to one of the developers.

+Developers · MPSDynamics.jl

Developers

Simulation Workflow

Flowchart of the simulation workflow

How to Contribute

Contributions are welcome! Don't hesitate to contact us if you

  • found a bug;
  • have a suggestion on how to improve the code and/or documentation;
  • would like to get involved in writing code and/or documentation.

You can contact us by raising an issue on Github, or by writing to one of the developers.

diff --git a/docs/examples/anderson-model/index.html b/docs/examples/anderson-model/index.html index 6c8e49c..f19b391 100644 --- a/docs/examples/anderson-model/index.html +++ b/docs/examples/anderson-model/index.html @@ -266,4 +266,4 @@ end # Display the plots -plot(p2, p3, p4, p5, p1, layout = (3, 2), size = (1400, 1200))

________________

Bibliography

+plot(p2, p3, p4, p5, p1, layout = (3, 2), size = (1400, 1200))

________________

Bibliography

diff --git a/docs/examples/bath-observables/index.html b/docs/examples/bath-observables/index.html index 862bdc9..181ac0a 100644 --- a/docs/examples/bath-observables/index.html +++ b/docs/examples/bath-observables/index.html @@ -102,4 +102,4 @@ xlabel=L"\omega", ylabel=L"\langle n^b_\omega \rangle", title="Mode occupation in the physical bath") -plot(p1, p2, p3, p4, layout = (2, 2), size = (1400, 1200))

___________________

Bibliography

+plot(p1, p2, p3, p4, layout = (2, 2), size = (1400, 1200))

___________________

Bibliography

diff --git a/docs/examples/protontransfer/index.html b/docs/examples/protontransfer/index.html index 39a8884..1f56541 100644 --- a/docs/examples/protontransfer/index.html +++ b/docs/examples/protontransfer/index.html @@ -232,4 +232,4 @@ print("\n k = ", k) (plot(heatmap(xlist_rho, xlist_rho, abs.(ρx[:,:,t]), c=:Blues ), title="Time = $k (arb. units)", xlabel=L"$x$ (arb. units)",ylabel=L"$x$ (arb. units)", tickfontsize=(12),colorbar_title = L"||\rho_{RC}(x,x)||", legend=:none, xlims=(-0.5, 0.5), ylims=(-0.5,0.5), clims=(0,0.18),aspect_ratio=:equal)) end -display(gif(anim, "gif_reducedrho.gif", fps = 2.5))

________________

Bibliography

+display(gif(anim, "gif_reducedrho.gif", fps = 2.5))

________________

Bibliography

diff --git a/docs/examples/puredephasing/index.html b/docs/examples/puredephasing/index.html index 238b3b8..d3bcfc4 100644 --- a/docs/examples/puredephasing/index.html +++ b/docs/examples/puredephasing/index.html @@ -91,4 +91,4 @@ plot(time_analytical, t->Decoherence_ohmic(t), label="Analytics", title=L"Pure Dephasing, Ohmic $s=%$s$, $\beta = %$β ~\mathrm{K}$", linecolor=:black, xlabel="Time (arb. units)", ylabel=L"Coherence $|\rho_{12}(t)|$", linewidth=4, titlefontsize=16, legend=:best, legendfontsize=16, xguidefontsize=16, yguidefontsize=16, tickfontsize=10) -plot!(dat["data/times"], ρ12, lw=4, ls=:dash, label="Numerics")

Bibliography

+plot!(dat["data/times"], ρ12, lw=4, ls=:dash, label="Numerics")

Bibliography

diff --git a/docs/examples/sbm/index.html b/docs/examples/sbm/index.html index 186e795..a9ffd49 100644 --- a/docs/examples/sbm/index.html +++ b/docs/examples/sbm/index.html @@ -78,4 +78,4 @@ method == :DTDVP && heatmap(dat["data/times"], collect(0:N+1), dat["data/bonddims"], xlabel=L"t",ylabel="bond index") -heatmap(dat["data/times"], collect(1:N), abs.(dat["data/SXdisp"][1,:,:]), xlabel=L"t",ylabel="chain mode") +heatmap(dat["data/times"], collect(1:N), abs.(dat["data/SXdisp"][1,:,:]), xlabel=L"t",ylabel="chain mode") diff --git a/docs/examples/timedep/index.html b/docs/examples/timedep/index.html index 562c6bb..b681ec9 100644 --- a/docs/examples/timedep/index.html +++ b/docs/examples/timedep/index.html @@ -79,4 +79,4 @@ # Plots #---------- -plot(dat["data/times"], dat["data/sz"], label="Dmax = $(D...)", xlabel=L"t",ylabel=L"\sigma_z", title="") +plot(dat["data/times"], dat["data/sz"], label="Dmax = $(D...)", xlabel=L"t",ylabel=L"\sigma_z", title="") diff --git a/docs/index.html b/docs/index.html index acb265b..d226f32 100644 --- a/docs/index.html +++ b/docs/index.html @@ -8,4 +8,4 @@ author = {Dunnett, Angus and Lacroix, Thibaut and Le Dé, Brieuc and Riva, Angela}, year = {2021}, doi = {10.5281/zenodo.5106435}, -} +} diff --git a/docs/methods/index.html b/docs/methods/index.html index a1116b7..ba10500 100644 --- a/docs/methods/index.html +++ b/docs/methods/index.html @@ -1,5 +1,5 @@ -Methods · MPSDynamics.jl

List of all methods

Matrix Product State (MPS)

MPSDynamics.apply1siteoperator!Method
apply1siteoperator!(A, O, sites::Int)

Apply an operator O on the MPS A. O is acting on only one site ::Int. The resulting MPS A is the MPS modified by the operator O.

source
MPSDynamics.apply1siteoperator!Method
apply1siteoperator!(A, O, sites::Vector{Int})

Apply an operator O on the MPS A. O is acting on several sites ::Vector{Int}. The resulting MPS A is the MPS modified by the operator O.

source
MPSDynamics.applympo!Method
applympo!(A, H)

Apply an MPO H on the MPS A. H must have the same number of site than A. The resulting MPS A is the MPS modified by the MPO H.

source
MPSDynamics.chainmpsMethod
chainmps(N::Int, site::Int, numex::Int)

Generate an MPS with numex excitations on site

The returned MPS will have bond-dimensions and physical dimensions numex+1

source
MPSDynamics.chainmpsMethod
chainmps(N::Int, sites::Vector{Int}, numex::Int)

Generate an MPS with numex excitations of an equal super-position over sites

The returned MPS will have bond-dimensions and physical dimensions numex+1

source
MPSDynamics.displacedchainmpsMethod
displacedchainmps(A::Vector{Any}, N::Int, Nm::Int, γ::Any)

Given a MPS A, return a MPS B where the Nm-long chain is displaced by γ without displacing the N-long system.

source
MPSDynamics.electron2kmpsFunction
electronkmps(N::Int, k::Vector{Int}, spin=:Up, chainparams=[fill(1.0,N), fill(1.0,N-1)])

Generate an MPS with 2 electrons in k-states k1 and k2.

source
MPSDynamics.electronkmpsFunction
electronkmps(N::Int, k::Int, spin=:Up, chainparams=[fill(1.0,N), fill(1.0,N-1)])

Generate an MPS for an electron with momentum k.

source
MPSDynamics.elementmpsMethod
elementmps(A, el...)

Return the element of the MPS A for the set of physical states el...

Examples

julia> A = chainmps(6, [2,4], 1);
+Methods · MPSDynamics.jl

List of all methods

Matrix Product State (MPS)

MPSDynamics.apply1siteoperator!Method
apply1siteoperator!(A, O, sites::Int)

Apply an operator O on the MPS A. O is acting on only one site ::Int. The resulting MPS A is the MPS modified by the operator O.

source
MPSDynamics.apply1siteoperator!Method
apply1siteoperator!(A, O, sites::Vector{Int})

Apply an operator O on the MPS A. O is acting on several sites ::Vector{Int}. The resulting MPS A is the MPS modified by the operator O.

source
MPSDynamics.applympo!Method
applympo!(A, H)

Apply an MPO H on the MPS A. H must have the same number of site than A. The resulting MPS A is the MPS modified by the MPO H.

source
MPSDynamics.chainmpsMethod
chainmps(N::Int, site::Int, numex::Int)

Generate an MPS with numex excitations on site

The returned MPS will have bond-dimensions and physical dimensions numex+1

source
MPSDynamics.chainmpsMethod
chainmps(N::Int, sites::Vector{Int}, numex::Int)

Generate an MPS with numex excitations of an equal super-position over sites

The returned MPS will have bond-dimensions and physical dimensions numex+1

source
MPSDynamics.displacedchainmpsMethod
displacedchainmps(A::Vector{Any}, N::Int, Nm::Int, γ::Any)

Given a MPS A, return a MPS B where the Nm-long chain is displaced by γ without displacing the N-long system.

source
MPSDynamics.electron2kmpsFunction
electronkmps(N::Int, k::Vector{Int}, spin=:Up, chainparams=[fill(1.0,N), fill(1.0,N-1)])

Generate an MPS with 2 electrons in k-states k1 and k2.

source
MPSDynamics.electronkmpsFunction
electronkmps(N::Int, k::Int, spin=:Up, chainparams=[fill(1.0,N), fill(1.0,N-1)])

Generate an MPS for an electron with momentum k.

source
MPSDynamics.elementmpsMethod
elementmps(A, el...)

Return the element of the MPS A for the set of physical states el...

Examples

julia> A = chainmps(6, [2,4], 1);
 
 julia> elementmps(A, 1, 2, 1, 1, 1, 1)
 0.7071067811865475
@@ -11,18 +11,18 @@
 0.0
 
 julia> elementmps(A, 1, 1, 1, 1, 1, 1)
-0.0
source
MPSDynamics.entanglemententropyMethod
entanglemententropy(A)

For a list of tensors A representing a right orthonormalized MPS, compute the entanglement entropy for a bipartite cut for every bond.

source
MPSDynamics.modempsFunction
modemps(N::Int, k::Vector{Int}, numex::Int, chainparams=[fill(1.0,N), fill(1.0,N-1)])

Generate an MPS with numex excitations of an equal superposition of modes k of a bosonic tight-binding chain.

source
MPSDynamics.modempsFunction
modemps(N::Int, k::Int, numex::Int, chainparams=[fill(1.0,N), fill(1.0,N-1)])

Generate an MPS with numex excitations of mode k of a bosonic tight-binding chain.

chainparams takes the form [e::Vector, t::Vector] where e are the on-site energies and t are the hoppping parameters.

The returned MPS will have bond-dimensions and physical dimensions numex+1

source
MPSDynamics.normmpsMethod
normmps(A::Vector; mpsorthog=:None)

Calculate norm of MPS A.

Setting mpsorthog=:Right/:Left will calculate the norm assuming right/left canonical form. Setting mpsorthog=OC::Int will cause the norm to be calculated assuming the orthoganility center is on site OC. If mpsorthog is :None the norm will be calculated as an MPS-MPS product.

source
MPSDynamics.orthcentersmpsMethod
orthcentersmps(A)

Compute the orthoganality centres of MPS A.

Return value is a list in which each element is the corresponding site tensor of A with the orthoganility centre on that site. Assumes A is right normalised.

source
MPSDynamics.productstatempsFunction
productstatemps(physdims::Dims, Dmax=1; state=:Vacuum, mpsorthog=:Right)

Return an MPS representing a product state with local Hilbert space dimensions given by physdims.

By default all bond-dimensions will be 1 since the state is a product state. However, to embed the product state in a manifold of greater bond-dimension, Dmax can be set accordingly.

The indvidual states of the MPS sites can be provided by setting state to a list of column vectors. Setting state=:Vacuum will produce an MPS in the vacuum state (where the state of each site is represented by a column vector with a 1 in the first row and zeros elsewhere). Setting state=:FullOccupy will produce an MPS in which each site is fully occupied (ie. a column vector with a 1 in the last row and zeros elsewhere).

The argument mpsorthog can be used to set the gauge of the resulting MPS.

Example

julia> ψ = unitcol(1,2); d = 6; N = 30; α = 0.1; Δ = 0.0; ω0 = 0.2; s = 1
+0.0
source
MPSDynamics.entanglemententropyMethod
entanglemententropy(A)

For a list of tensors A representing a right orthonormalized MPS, compute the entanglement entropy for a bipartite cut for every bond.

source
MPSDynamics.modempsFunction
modemps(N::Int, k::Vector{Int}, numex::Int, chainparams=[fill(1.0,N), fill(1.0,N-1)])

Generate an MPS with numex excitations of an equal superposition of modes k of a bosonic tight-binding chain.

source
MPSDynamics.modempsFunction
modemps(N::Int, k::Int, numex::Int, chainparams=[fill(1.0,N), fill(1.0,N-1)])

Generate an MPS with numex excitations of mode k of a bosonic tight-binding chain.

chainparams takes the form [e::Vector, t::Vector] where e are the on-site energies and t are the hoppping parameters.

The returned MPS will have bond-dimensions and physical dimensions numex+1

source
MPSDynamics.normmpsMethod
normmps(A::Vector; mpsorthog=:None)

Calculate norm of MPS A.

Setting mpsorthog=:Right/:Left will calculate the norm assuming right/left canonical form. Setting mpsorthog=OC::Int will cause the norm to be calculated assuming the orthoganility center is on site OC. If mpsorthog is :None the norm will be calculated as an MPS-MPS product.

source
MPSDynamics.orthcentersmpsMethod
orthcentersmps(A)

Compute the orthoganality centres of MPS A.

Return value is a list in which each element is the corresponding site tensor of A with the orthoganility centre on that site. Assumes A is right normalised.

source
MPSDynamics.productstatempsFunction
productstatemps(physdims::Dims, Dmax=1; state=:Vacuum, mpsorthog=:Right)

Return an MPS representing a product state with local Hilbert space dimensions given by physdims.

By default all bond-dimensions will be 1 since the state is a product state. However, to embed the product state in a manifold of greater bond-dimension, Dmax can be set accordingly.

The indvidual states of the MPS sites can be provided by setting state to a list of column vectors. Setting state=:Vacuum will produce an MPS in the vacuum state (where the state of each site is represented by a column vector with a 1 in the first row and zeros elsewhere). Setting state=:FullOccupy will produce an MPS in which each site is fully occupied (ie. a column vector with a 1 in the last row and zeros elsewhere).

The argument mpsorthog can be used to set the gauge of the resulting MPS.

Example

julia> ψ = unitcol(1,2); d = 6; N = 30; α = 0.1; Δ = 0.0; ω0 = 0.2; s = 1
 
 julia> cpars = chaincoeffs_ohmic(N, α, s)
 
 julia> H = spinbosonmpo(ω0, Δ, d, N, cpars)
 
-julia> A = productstatemps(physdims(H), state=[ψ, fill(unitcol(1,d), N)...]) # MPS representation of |ψ>|Vacuum>
source
MPSDynamics.productstatempsFunction
productstatemps(N::Int, d::Int, Dmax=1; state=:Vacuum, mpsorthog=:Right)

Return an N-site MPS with all local Hilbert space dimensions given by d.

source
MPSDynamics.randmpsFunction
randmps(N::Int, d::Int, Dmax::Int, T=Float64)

Construct a random, N-site, right-normalised MPS with all local Hilbert space dimensions given by d.

source
MPSDynamics.randmpsMethod
randmps(physdims::Dims{N}, Dmax::Int, T::Type{<:Number} = Float64) where {N}

Construct a random, right-normalised MPS with local Hilbert space dimensions given by physdims and max bond-dimension given by Dmax.

T specifies the element type, eg. use T=ComplexF64 for a complex valued MPS.

source
MPSDynamics.reversempo!Method
reversempo!(M)

Reverse the left and right dimensions of the MPO M. The resulting MPO M is the reversed MPO.

source
MPSDynamics.reversemps!Method
reversemps!(A)

Reverse the left and right dimensions of the MPS A. The resulting MPS A is the reversed MPS.

source
MPSDynamics.svdmpsMethod
svdmps(A)

For a right normalised mps A compute the full svd spectrum for a bipartition at every bond.

source
Base.reshapeMethod
Base.reshape(x::Number, dims...)

Reshape any matrix with dimensions "dims"

Example

julia> A = rand(2,3,2)
+julia> A = productstatemps(physdims(H), state=[ψ, fill(unitcol(1,d), N)...]) # MPS representation of |ψ>|Vacuum>
source
MPSDynamics.productstatempsFunction
productstatemps(N::Int, d::Int, Dmax=1; state=:Vacuum, mpsorthog=:Right)

Return an N-site MPS with all local Hilbert space dimensions given by d.

source
MPSDynamics.randmpsFunction
randmps(N::Int, d::Int, Dmax::Int, T=Float64)

Construct a random, N-site, right-normalised MPS with all local Hilbert space dimensions given by d.

source
MPSDynamics.randmpsMethod
randmps(physdims::Dims{N}, Dmax::Int, T::Type{<:Number} = Float64) where {N}

Construct a random, right-normalised MPS with local Hilbert space dimensions given by physdims and max bond-dimension given by Dmax.

T specifies the element type, eg. use T=ComplexF64 for a complex valued MPS.

source
MPSDynamics.reversempo!Method
reversempo!(M)

Reverse the left and right dimensions of the MPO M. The resulting MPO M is the reversed MPO.

source
MPSDynamics.reversemps!Method
reversemps!(A)

Reverse the left and right dimensions of the MPS A. The resulting MPS A is the reversed MPS.

source
MPSDynamics.svdmpsMethod
svdmps(A)

For a right normalised mps A compute the full svd spectrum for a bipartition at every bond.

source
Base.reshapeMethod
Base.reshape(x::Number, dims...)

Reshape any matrix with dimensions "dims"

Example

julia> A = rand(2,3,2)
 
 julia> B = reshape(A,4,3)
 
 julia> size(B) == (4,3) 
-
source
MPSDynamics.svdtruncMethod
U, S, Vd = svdtrunc(A; truncdim = max(size(A)...), truncerr = 0.)

Perform a truncated SVD, with maximum number of singular values to keep equal to truncdim or truncating any singular values smaller than truncerr. If both options are provided, the smallest number of singular values will be kept. Unlike the SVD in Julia, this returns matrix U, a diagonal matrix (not a vector) S, and Vt such that A ≈ U * S * Vt

source
MPSDynamics.chainpropMethod
chainprop(t, cparams...)

Propagate an excitation placed initially on the first site of a tight-binding chain with parameters given by cparams for a time t and return occupation expectation for each site.

source
MPSDynamics.svdtruncMethod
U, S, Vd = svdtrunc(A; truncdim = max(size(A)...), truncerr = 0.)

Perform a truncated SVD, with maximum number of singular values to keep equal to truncdim or truncating any singular values smaller than truncerr. If both options are provided, the smallest number of singular values will be kept. Unlike the SVD in Julia, this returns matrix U, a diagonal matrix (not a vector) S, and Vt such that A ≈ U * S * Vt

source
MPSDynamics.chainpropMethod
chainprop(t, cparams...)

Propagate an excitation placed initially on the first site of a tight-binding chain with parameters given by cparams for a time t and return occupation expectation for each site.

source
MPSDynamics.cosinehMethod
cosineh(omega, bet)
 
 Calculates the hyperbolic cosine function function based on the input parameters, 
 for the Bogoliubov transformation necessary for the thermofield transformation.
@@ -32,7 +32,7 @@
 - `bet::Float64`: The beta parameter.
 
 # Returns
-- `Float64`: The result of the modified cosine function.
source
MPSDynamics.dispMethod
function disp(d,ωvib,m)

Displacement operator $X = \frac{\sqrt{2}}{2\sqrt{m \omega_{vib}}}(a + a^{\dagger})$

source
MPSDynamics.dispMethod
function disp(d)

Mass and frequency-weighted displacement operator $X = \frac{1}{2}(a + a^{\dagger})$

source
MPSDynamics.dynamapMethod
dynamap(ps1,ps2,ps3,ps4)

Calculate complete dynamical map to time step at which ps1, ps2, ps3 and ps4 are specified.

source
MPSDynamics.findchainlengthMethod
findchainlength(T, cparams...; eps=10^-6)

Estimate length of chain required for a particular set of chain parameters by calculating how long an excitation on the first site takes to reach the end. The chain length is given as the length required for the excitation to have just reached the last site after time T. The initial number of sites in cparams has to be larger than the findchainlength result.

source
MPSDynamics.dispMethod
function disp(d,ωvib,m)

Displacement operator $X = \frac{\sqrt{2}}{2\sqrt{m \omega_{vib}}}(a + a^{\dagger})$

source
MPSDynamics.dispMethod
function disp(d)

Mass and frequency-weighted displacement operator $X = \frac{1}{2}(a + a^{\dagger})$

source
MPSDynamics.dynamapMethod
dynamap(ps1,ps2,ps3,ps4)

Calculate complete dynamical map to time step at which ps1, ps2, ps3 and ps4 are specified.

source
MPSDynamics.findchainlengthMethod
findchainlength(T, cparams...; eps=10^-6)

Estimate length of chain required for a particular set of chain parameters by calculating how long an excitation on the first site takes to reach the end. The chain length is given as the length required for the excitation to have just reached the last site after time T. The initial number of sites in cparams has to be larger than the findchainlength result.

source
MPSDynamics.measurecorrsMethod
measurecorrs(oper, , e::Vector, t::Vector)
 
 ### Parameters
 
@@ -51,7 +51,7 @@
 
 This function performs a basis transformation of the operator `oper`. Specifically, 
 this transformation reverses the unitary transformation that maps the extended bath
-Hamiltonian into the chain representation.
source
MPSDynamics.physical_occupMethod
physical_occup(corr_constr, corr_destr, omega, occup, b, M)
 
 Calculates the physical occupation based on correlation matrices, omega values, 
 and other parameters. The physical occupation in the original frequency environment
@@ -66,7 +66,7 @@
 - `M::Int`: The number of points for interpolation.
 
 # Returns
-- `Vector{Float64}`: The physical occupation values.
source
MPSDynamics.rmsdMethod
rmsd(dat1::Vector{Float64}, dat2::Vector{Float64})

Calculate the root mean squared difference between two measurements of an observable over the same time period.

source
MPSDynamics.rmsdMethod
rmsd(dat1::Vector{Float64}, dat2::Vector{Float64})

Calculate the root mean squared difference between two measurements of an observable over the same time period.

source
MPSDynamics.sinehMethod
sineh(omega, bet)
 
 Calculates the hyperbolic sine function function based on the input parameters, 
 for the Bogoliubov transformation necessary for the thermofield transformation.
@@ -76,17 +76,17 @@
 - `bet::Float64`: The beta parameter.
 
 # Returns
-- `Float64`: The result of the modified cosine function.
source
MPSDynamics.therHamMethod
 function therHam(psi, site1, site2)

Calculates Hβ such that ρ = e^(-βH) for some density matrix ρ obatined from tracing out everything outside the range [site1,site2] in the MPS psi

source

Tree Tensor Network (TTN)

MPSDynamics.findchildMethod
findchild(node::TreeNode, id::Int)

Return integer corresponding to the which number child site id is of node.

source
MPSDynamics.randtreeMethod
randtree(numnodes::Int, maxdegree::Int)

Construct a random tree with nummodes modes and max degree maxdegree.

source
MPSDynamics.measure1siteoperatorMethod
measure1siteoperator(net::TreeNetwork, O, sites::Tuple{Int,Int})

For a Tree, compute the local expectation value of a one-site operator O for the specified site range.

source
MPSDynamics.measure2siteoperatorMethod
measure2siteoperator(net::TreeNetwork, O1, O2, sites::Tuple{Int,Int})

For a Tree, compute the local expectation value of two one-site operators O1 and O2 for the specified site range.

source
MPSDynamics.mpsmoveoc!Method
mpsmoveoc!(A::TreeNetwork, id::Int)

Move the orthogonality centre of right normalised tree-MPS A to site id.

This function will be more efficient than using mpsmixednorm! if the tree-MPS is already right-normalised.

source
MPSDynamics.mpsshiftoc!Method
mpsshiftoc!(A::TreeNetwork, newhd::Int)

Shift the orthogonality centre by one site, setting new head-node newhd.

source
MPSDynamics.normmpsMethod
normmps(net::TreeNetwork; mpsorthog=:None)

When applied to a tree-MPS mpsorthog=:Left is not defined.

source
MPSDynamics.productstatempsFunction
productstatemps(tree_::Tree, physdims::Dims, Dmax::Int=1; state=:Vacuum)

Return a tree-MPS representing a product state with local Hilbert space dimensions given by physdims.

By default all bond-dimensions will be 1 since the state is a product state. However, to embed the product state in a manifold of greater bond-dimension, Dmax can be set accordingly.

The indvidual states of the MPS sites can be provided by setting state to a list of column vectors. Setting state=:Vacuum will produce an MPS in the vacuum state (where the state of each site is represented by a column vector with a 1 in the first row and zeros elsewhere). Setting state=:FullOccupy will produce an MPS in which each site is fully occupied (ie. a column vector with a 1 in the last row and zeros elsewhere).

Example

julia> ψ = unitcol(1,2); d = 6; N = 30; α = 0.1; Δ = 0.0; ω0 = 0.2; s = 1
+- `Float64`: The result of the modified cosine function.
source
MPSDynamics.therHamMethod
 function therHam(psi, site1, site2)

Calculates Hβ such that ρ = e^(-βH) for some density matrix ρ obatined from tracing out everything outside the range [site1,site2] in the MPS psi

source

Tree Tensor Network (TTN)

MPSDynamics.findchildMethod
findchild(node::TreeNode, id::Int)

Return integer corresponding to the which number child site id is of node.

source
MPSDynamics.randtreeMethod
randtree(numnodes::Int, maxdegree::Int)

Construct a random tree with nummodes modes and max degree maxdegree.

source
MPSDynamics.measure1siteoperatorMethod
measure1siteoperator(net::TreeNetwork, O, sites::Tuple{Int,Int})

For a Tree, compute the local expectation value of a one-site operator O for the specified site range.

source
MPSDynamics.measure2siteoperatorMethod
measure2siteoperator(net::TreeNetwork, O1, O2, sites::Tuple{Int,Int})

For a Tree, compute the local expectation value of two one-site operators O1 and O2 for the specified site range.

source
MPSDynamics.mpsmoveoc!Method
mpsmoveoc!(A::TreeNetwork, id::Int)

Move the orthogonality centre of right normalised tree-MPS A to site id.

This function will be more efficient than using mpsmixednorm! if the tree-MPS is already right-normalised.

source
MPSDynamics.mpsshiftoc!Method
mpsshiftoc!(A::TreeNetwork, newhd::Int)

Shift the orthogonality centre by one site, setting new head-node newhd.

source
MPSDynamics.normmpsMethod
normmps(net::TreeNetwork; mpsorthog=:None)

When applied to a tree-MPS mpsorthog=:Left is not defined.

source
MPSDynamics.productstatempsFunction
productstatemps(tree_::Tree, physdims::Dims, Dmax::Int=1; state=:Vacuum)

Return a tree-MPS representing a product state with local Hilbert space dimensions given by physdims.

By default all bond-dimensions will be 1 since the state is a product state. However, to embed the product state in a manifold of greater bond-dimension, Dmax can be set accordingly.

The indvidual states of the MPS sites can be provided by setting state to a list of column vectors. Setting state=:Vacuum will produce an MPS in the vacuum state (where the state of each site is represented by a column vector with a 1 in the first row and zeros elsewhere). Setting state=:FullOccupy will produce an MPS in which each site is fully occupied (ie. a column vector with a 1 in the last row and zeros elsewhere).

Example

julia> ψ = unitcol(1,2); d = 6; N = 30; α = 0.1; Δ = 0.0; ω0 = 0.2; s = 1
 
 julia> cpars = chaincoeffs_ohmic(N, α, s)
 
 julia> H = spinbosonmpo(ω0, Δ, d, N, cpars, tree=true)
 
-julia> A = productstatemps(H.tree, physdims(H), state=[ψ, fill(unitcol(1,d), N)...]) # tree-MPS representation of |ψ>|Vacuum>
source
MPSDynamics.randmpsFunction
randmps(tree::Tree, physdims, Dmax::Int, T::Type{<:Number} = Float64)

Construct a random, right-normalised, tree-MPS, with structure given by tree and max bond-dimension given by Dmax.

The local Hilbert space dimensions are specified by physdims which can either be of type Dims{length(tree)}, specifying the dimension of each site, or of type Int, in which case the same local dimension is used for every site.

source
MPSDynamics.tdvp1sweep!Method
tdvp1sweep!(dt, A::TreeNetwork, M::TreeNetwork, F::Vector, id::Int; verbose=false, kwargs...)

Propagates the tree-MPS A with the tree-MPO M following the 1-site TDVP method. The sweep is done back and forth with a time step dt/2. F represents the merged left and right parts of the site being propagated.

source

Measure and Obervables

MPSDynamics.OneSiteObservableMethod
OneSiteObservable(name,op,sites)

Computes the local expectation value of the one-site operator op on the specified sites. Used to define one-site observables that are obs and convobs parameters for the runsim function.

source
MPSDynamics.OneSiteObservableMethod
OneSiteObservable(name,op)

Computes the local expectation value of the one-site operator op on the every site. Used to define one-site observables that are obs and convobs parameters for the runsim function.

source
MPSDynamics.TwoSiteObservableType
TwoSiteObservable(name,op1,op2,sites1=nothing,sites2=nothing)

Computes the local expectation value of operators op1 and op2 where op1 acts on sites1 and op2 acts on sites2. Used to define several-site observables that are obs and convobs parameters for the runsim function.

source
MPSDynamics.measure1siteoperatorMethod
measure1siteoperator(A::Vector, O, site::Int)

For a list of tensors A representing a right orthonormalized MPS, compute the local expectation value of a one-site operator O for a single site.

source
MPSDynamics.measure1siteoperatorMethod
measure1siteoperator(A::Vector, O, chainsection::Tuple{Int64,Int64})

For a list of tensors A representing a right orthonormalized MPS, compute the local expectation value of a one-site operator O for a chainsection.

source
MPSDynamics.measure1siteoperatorMethod
measure1siteoperator(A::Vector, O, sites::Vector{Int})

For a list of tensors A representing a right orthonormalized MPS, compute the local expectation value of a one-site operator O for every site or just one if it is specified.

For calculating operators on single sites this will be more efficient if the site is on the left of the mps.

source
MPSDynamics.measure1siteoperatorMethod
measure1siteoperator(A::Vector, O)

For a list of tensors A representing a right orthonormalized MPS, compute the local expectation value of a one-site operator O for every site.

source
MPSDynamics.measure2siteoperatorMethod
 measure2siteoperator(A::Vector, M1, M2, j1, j2)

Caculate expectation of M1*M2 where M1 acts on site j1 and M2 acts on site j2, assumes A is right normalised.

source
MPSDynamics.measure2siteoperatorMethod
 measure2siteoperator(A::Vector, M1, M2, sites1::Vector{Int}, sites2::Vector{Int})

Caculate expectation of M1*M2 where M1 acts on sites1 and M2 acts on sites2, assumes A is right normalised.

source
MPSDynamics.measurempoMethod
measurempo(A::Vector, M::Vector, sites::Tuples{Int,Int})

For a list of tensors A representing a right orthonormalized MPS, compute the local expectation value of the MPO M on specified sites.

source
MPSDynamics.measurempoMethod
measurempo(A::Vector, M::Vector)

For a list of tensors A representing a right orthonormalized MPS, compute the local expectation value of the MPO M on every site.

source
MPSDynamics.rhoreduced_2sitesMethod
 rhoreduced_2sites(A::Vector, site::Tuple{Int, Int})

Caculate the reduced density matrix of the MPS A of two neigbour sites. The resulting dimensions will be the four physical dimensions in total, corresponding to the dimensions of the two sites

source
MPSDynamics.measureMethod
measure(A, obs::FockError; t=0, kwargs...)

Return the measure of the observable obs on the MPS A.

source

Models and Hamiltonians (MPO)

MPSDynamics.chaincoeffs_ohmicMethod
chaincoeffs_ohmic(N, α, s; ωc=1, soft=false)

Generate chain coefficients $[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$ for an Harmonic bath at zero temperature with a power law spectral density given by:

soft cutoff: $J(ω) = 2αω_c (\frac{ω}{ω_c})^s \exp(-ω/ω_c)$

hard cutoff: $J(ω) = 2αω_c (\frac{ω}{ω_c})^s θ(ω-ω_c)$

The coefficients parameterise the chain Hamiltonian

$H = H_S + c_0 A_S⊗B_0+\sum_{i=0}^{N-1}t_i (b_{i+1}^\dagger b_i +h.c.) + \sum_{i=0}^{N} ϵ_ib_i^\dagger b_i$

which is unitarily equivalent (before the truncation to N sites) to

$H = H_S + A_S⊗\int_0^∞dω\sqrt{J(ω)}B_ω + \int_0^∞dωωb_ω^\dagger b_ω$.

source
MPSDynamics.correlatedenvironmentmpoMethod
correlatedenvironmentmpo(R::Vector, Nm::Int, d::Int; chainparams, fnamecc::String, s=1, α=1, ωc=1, c_phonon=1, β="inf", issoft=false)

Generate a MPO for a one-dimensional bosonic bath spatially correlated to a multi-component system

$H_B + H_{int} = \int_{-∞}^{+∞} dk ω_k b_k^\dagger b_k + ∑_j \int_{-∞}^{+∞}dk \sqrt{J(k)}(A_j b_k e^{i k R_j} + h.c.)$.

The interactions between the system and the chain-mapped bath are long range, i.e. each site interacts with all the chain modes. The spectral density is assumed to be Ohmic $J(ω) = 2αωc(ω/ωc)^s$.

Arguments

  • R: List of system's components positions
  • Nm: Number of chain modes. The actual number of mode will be doubled to account for the left and right moving excitations.
  • d: Local Hilbert space dimension of the bath modes
  • chainparams: chain parameters, of the form chainparams=$[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$, can be chosen to represent any arbitrary spectral density $J(ω)$ at any temperature.
  • fnamecc: Path to a file containing pre-computed long-range coupling coefficient. If not provided, the coupling coefficients will be computed and stored.
  • s: Ohmicity
  • α: Kondo parameter
  • ωc: Bath cut-off frequency
  • c_phonon: Speed of sound in the bath
  • β: Inverse temperature
  • issoft: Is the cut-off of the Ohmic SD soft or hard?
source
MPSDynamics.hbathchainMethod
hbathchain(N::Int, d::Int, chainparams, longrangecc...; tree=false, reverse=false, coupletox=false)

Generate MPO representing a tight-binding chain of N oscillators with d Fock states each. Chain parameters are supplied in the standard form: chainparams $=[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$. The output does not itself represent a complete MPO but will possess an end which is open and should be attached to another tensor site, usually representing the system.

Arguments

  • reverse: If reverse=true create a chain were the last (i.e. Nth) site is the site which couples to the system
  • coupletox: Used to choose the form of the system coupling. coupletox=true gives a non-number conserving coupling of the form $H_{\text{I}}= A_{\text{S}}(b_{0}^\dagger + b_0)$ where $A_{\text{S}}$ is a system operator, while coupletox=false gives the number-converving coupling $H_{\text{I}}=(A_{\text{S}} b_{0}^\dagger + A_{\text{S}}^\dagger b_0)$
  • tree: If true the resulting chain will be of type TreeNetwork; useful for construcing tree-MPOs

Example

One can constuct a system site tensor to couple to a chain by using the function up to populate the tensor. For example, to construct a system site with Hamiltonian Hs and coupling operator As, the system tensor M is constructed as follows for a non-number conserving interaction:

u = one(Hs) # system identity
+julia> A = productstatemps(H.tree, physdims(H), state=[ψ, fill(unitcol(1,d), N)...]) # tree-MPS representation of |ψ>|Vacuum>
source
MPSDynamics.randmpsFunction
randmps(tree::Tree, physdims, Dmax::Int, T::Type{<:Number} = Float64)

Construct a random, right-normalised, tree-MPS, with structure given by tree and max bond-dimension given by Dmax.

The local Hilbert space dimensions are specified by physdims which can either be of type Dims{length(tree)}, specifying the dimension of each site, or of type Int, in which case the same local dimension is used for every site.

source
MPSDynamics.tdvp1sweep!Method
tdvp1sweep!(dt, A::TreeNetwork, M::TreeNetwork, F::Vector, id::Int; verbose=false, kwargs...)

Propagates the tree-MPS A with the tree-MPO M following the 1-site TDVP method. The sweep is done back and forth with a time step dt/2. F represents the merged left and right parts of the site being propagated.

source

Measure and Obervables

MPSDynamics.OneSiteObservableMethod
OneSiteObservable(name,op,sites)

Computes the local expectation value of the one-site operator op on the specified sites. Used to define one-site observables that are obs and convobs parameters for the runsim function.

source
MPSDynamics.OneSiteObservableMethod
OneSiteObservable(name,op)

Computes the local expectation value of the one-site operator op on the every site. Used to define one-site observables that are obs and convobs parameters for the runsim function.

source
MPSDynamics.TwoSiteObservableType
TwoSiteObservable(name,op1,op2,sites1=nothing,sites2=nothing)

Computes the local expectation value of operators op1 and op2 where op1 acts on sites1 and op2 acts on sites2. Used to define several-site observables that are obs and convobs parameters for the runsim function.

source
MPSDynamics.measure1siteoperatorMethod
measure1siteoperator(A::Vector, O, site::Int)

For a list of tensors A representing a right orthonormalized MPS, compute the local expectation value of a one-site operator O for a single site.

source
MPSDynamics.measure1siteoperatorMethod
measure1siteoperator(A::Vector, O, chainsection::Tuple{Int64,Int64})

For a list of tensors A representing a right orthonormalized MPS, compute the local expectation value of a one-site operator O for a chainsection.

source
MPSDynamics.measure1siteoperatorMethod
measure1siteoperator(A::Vector, O, sites::Vector{Int})

For a list of tensors A representing a right orthonormalized MPS, compute the local expectation value of a one-site operator O for every site or just one if it is specified.

For calculating operators on single sites this will be more efficient if the site is on the left of the mps.

source
MPSDynamics.measure1siteoperatorMethod
measure1siteoperator(A::Vector, O)

For a list of tensors A representing a right orthonormalized MPS, compute the local expectation value of a one-site operator O for every site.

source
MPSDynamics.measure2siteoperatorMethod
 measure2siteoperator(A::Vector, M1, M2, j1, j2)

Caculate expectation of M1*M2 where M1 acts on site j1 and M2 acts on site j2, assumes A is right normalised.

source
MPSDynamics.measure2siteoperatorMethod
 measure2siteoperator(A::Vector, M1, M2, sites1::Vector{Int}, sites2::Vector{Int})

Caculate expectation of M1*M2 where M1 acts on sites1 and M2 acts on sites2, assumes A is right normalised.

source
MPSDynamics.measurempoMethod
measurempo(A::Vector, M::Vector, sites::Tuples{Int,Int})

For a list of tensors A representing a right orthonormalized MPS, compute the local expectation value of the MPO M on specified sites.

source
MPSDynamics.measurempoMethod
measurempo(A::Vector, M::Vector)

For a list of tensors A representing a right orthonormalized MPS, compute the local expectation value of the MPO M on every site.

source
MPSDynamics.rhoreduced_2sitesMethod
 rhoreduced_2sites(A::Vector, site::Tuple{Int, Int})

Caculate the reduced density matrix of the MPS A of two neigbour sites. The resulting dimensions will be the four physical dimensions in total, corresponding to the dimensions of the two sites

source
MPSDynamics.measureMethod
measure(A, obs::FockError; t=0, kwargs...)

Return the measure of the observable obs on the MPS A.

source

Models and Hamiltonians (MPO)

MPSDynamics.chaincoeffs_ohmicMethod
chaincoeffs_ohmic(N, α, s; ωc=1, soft=false)

Generate chain coefficients $[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$ for an Harmonic bath at zero temperature with a power law spectral density given by:

soft cutoff: $J(ω) = 2αω_c (\frac{ω}{ω_c})^s \exp(-ω/ω_c)$

hard cutoff: $J(ω) = 2αω_c (\frac{ω}{ω_c})^s θ(ω-ω_c)$

The coefficients parameterise the chain Hamiltonian

$H = H_S + c_0 A_S⊗B_0+\sum_{i=0}^{N-1}t_i (b_{i+1}^\dagger b_i +h.c.) + \sum_{i=0}^{N} ϵ_ib_i^\dagger b_i$

which is unitarily equivalent (before the truncation to N sites) to

$H = H_S + A_S⊗\int_0^∞dω\sqrt{J(ω)}B_ω + \int_0^∞dωωb_ω^\dagger b_ω$.

source
MPSDynamics.correlatedenvironmentmpoMethod
correlatedenvironmentmpo(R::Vector, Nm::Int, d::Int; chainparams, fnamecc::String, s=1, α=1, ωc=1, c_phonon=1, β="inf", issoft=false)

Generate a MPO for a one-dimensional bosonic bath spatially correlated to a multi-component system

$H_B + H_{int} = \int_{-∞}^{+∞} dk ω_k b_k^\dagger b_k + ∑_j \int_{-∞}^{+∞}dk \sqrt{J(k)}(A_j b_k e^{i k R_j} + h.c.)$.

The interactions between the system and the chain-mapped bath are long range, i.e. each site interacts with all the chain modes. The spectral density is assumed to be Ohmic $J(ω) = 2αωc(ω/ωc)^s$.

Arguments

  • R: List of system's components positions
  • Nm: Number of chain modes. The actual number of mode will be doubled to account for the left and right moving excitations.
  • d: Local Hilbert space dimension of the bath modes
  • chainparams: chain parameters, of the form chainparams=$[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$, can be chosen to represent any arbitrary spectral density $J(ω)$ at any temperature.
  • fnamecc: Path to a file containing pre-computed long-range coupling coefficient. If not provided, the coupling coefficients will be computed and stored.
  • s: Ohmicity
  • α: Kondo parameter
  • ωc: Bath cut-off frequency
  • c_phonon: Speed of sound in the bath
  • β: Inverse temperature
  • issoft: Is the cut-off of the Ohmic SD soft or hard?
source
MPSDynamics.hbathchainMethod
hbathchain(N::Int, d::Int, chainparams, longrangecc...; tree=false, reverse=false, coupletox=false)

Generate MPO representing a tight-binding chain of N oscillators with d Fock states each. Chain parameters are supplied in the standard form: chainparams $=[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$. The output does not itself represent a complete MPO but will possess an end which is open and should be attached to another tensor site, usually representing the system.

Arguments

  • reverse: If reverse=true create a chain were the last (i.e. Nth) site is the site which couples to the system
  • coupletox: Used to choose the form of the system coupling. coupletox=true gives a non-number conserving coupling of the form $H_{\text{I}}= A_{\text{S}}(b_{0}^\dagger + b_0)$ where $A_{\text{S}}$ is a system operator, while coupletox=false gives the number-converving coupling $H_{\text{I}}=(A_{\text{S}} b_{0}^\dagger + A_{\text{S}}^\dagger b_0)$
  • tree: If true the resulting chain will be of type TreeNetwork; useful for construcing tree-MPOs

Example

One can constuct a system site tensor to couple to a chain by using the function up to populate the tensor. For example, to construct a system site with Hamiltonian Hs and coupling operator As, the system tensor M is constructed as follows for a non-number conserving interaction:

u = one(Hs) # system identity
 M = zeros(1,3,2,2)
 M[1, :, :, :] = up(Hs, As, u)

The full MPO can then be constructed with:

Hmpo = [M, hbathchain(N, d, chainparams, coupletox=true)...]

Similarly for a number conserving interaction the site tensor would look like:

u = one(Hs) # system identity
 M = zeros(1,4,2,2)
-M[1, :, :, :] = up(Hs, As, As', u)

And the full MPO would be

Hmpo = [M, hbathchain(N, d, chainparams; coupletox=false)...]
source
MPSDynamics.heisenbergmpoFunction
heisenbergmpo(N::Int, J=1.0) = xyzmpo(N; Jx=J)

Generate MPO for the N-spin Heisenberg XXX model, defined by the Hamiltonian

$H = \sum_{n=1}^{N-1} -J σ_x^{n} σ_x^{n+1} - J σ_y^{n} σ_y^{n+1} - J σ_z^{n} σ_z^{n+1}$

with $σ_x^{n}, σ_y^{n}, σ_z^{n}$ the Pauli spin-1/2 matrices of the $n^\text{th}$ site.

source
MPSDynamics.ibmmpoMethod
ibmmpo(ω0, d, N, chainparams; tree=false)

Generate MPO for a spin-1/2 coupled to a chain of harmonic oscillators with the interacting boson model (IBM), defined by the Hamiltonian

$H = \frac{ω_0}{2}σ_z + c_0σ_z(b_0^\dagger+b_0) + \sum_{i=0}^{N-1} t_i (b_{i+1}^\dagger b_i +h.c.) + \sum_{i=0}^{N} ϵ_ib_i^\dagger b_i$.

The spin is on site 1 of the MPS and the bath modes are to the right.

This Hamiltonain is unitarily equivalent (before the truncation to N sites) to the spin-boson Hamiltonian defined by

$H = \frac{ω_0}{2}σ_z + σ_z\int_0^∞ dω\sqrt{J(ω)}(b_ω^\dagger+b_ω) + \int_0^∞ dω ωb_ω^\dagger b_ω$.

The chain parameters, supplied by chainparams=$[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$, can be chosen to represent any arbitrary spectral density $J(ω)$ at any temperature.

source
MPSDynamics.interleaved_tightbinding_mpoMethod
interleaved_tightbinding_mpo(N, ϵd, chainparams1, chainparams2)
+M[1, :, :, :] = up(Hs, As, As', u)

And the full MPO would be

Hmpo = [M, hbathchain(N, d, chainparams; coupletox=false)...]
source
MPSDynamics.heisenbergmpoFunction
heisenbergmpo(N::Int, J=1.0) = xyzmpo(N; Jx=J)

Generate MPO for the N-spin Heisenberg XXX model, defined by the Hamiltonian

$H = \sum_{n=1}^{N-1} -J σ_x^{n} σ_x^{n+1} - J σ_y^{n} σ_y^{n+1} - J σ_z^{n} σ_z^{n+1}$

with $σ_x^{n}, σ_y^{n}, σ_z^{n}$ the Pauli spin-1/2 matrices of the $n^\text{th}$ site.

source
MPSDynamics.ibmmpoMethod
ibmmpo(ω0, d, N, chainparams; tree=false)

Generate MPO for a spin-1/2 coupled to a chain of harmonic oscillators with the interacting boson model (IBM), defined by the Hamiltonian

$H = \frac{ω_0}{2}σ_z + c_0σ_z(b_0^\dagger+b_0) + \sum_{i=0}^{N-1} t_i (b_{i+1}^\dagger b_i +h.c.) + \sum_{i=0}^{N} ϵ_ib_i^\dagger b_i$.

The spin is on site 1 of the MPS and the bath modes are to the right.

This Hamiltonain is unitarily equivalent (before the truncation to N sites) to the spin-boson Hamiltonian defined by

$H = \frac{ω_0}{2}σ_z + σ_z\int_0^∞ dω\sqrt{J(ω)}(b_ω^\dagger+b_ω) + \int_0^∞ dω ωb_ω^\dagger b_ω$.

The chain parameters, supplied by chainparams=$[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$, can be chosen to represent any arbitrary spectral density $J(ω)$ at any temperature.

source
MPSDynamics.interleaved_tightbinding_mpoMethod
interleaved_tightbinding_mpo(N, ϵd, chainparams1, chainparams2)
 
 Generate MPO for a tight-binding chain of N fermionic sites with a single impurity site (fermionic as well)
 of energy ϵd. The impurity is coupled to two leads, each described by a set of chain parameters. 
@@ -100,14 +100,14 @@
 * chainparams1::Array{Real,1}: chain parameters for the first lead
 * chainparams2::Array{Real,1}: chain parameters for the second lead
 
-The chain parameters are given in the standard form: `chainparams` ``=[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]``.
source
MPSDynamics.isingmpoMethod
isingmpo(N; J=1.0, h=1.0)

Generate MPO for the N-spin 1D Ising model with external field $\vec{h} = (0,0,h)$, defined by the Hamiltonian

$H = \sum_{n=1}^{N-1} -J_x σ_x^{n} σ_x^{n+1} + \sum_{n=1}^{N}(- h_z σ_z^{n})$

with $σ_x^{n}, σ_y^{n}, σ_z^{n}$ the Pauli spin-1/2 matrices of the $n^\text{th}$ site.

source
MPSDynamics.longrange_xyzmpoFunction
longrange_xyzmpo(N::Int, α::Float64=0.; Jx=1.0, Jy=Jx, Jz=Jx, hx=0., hz=0.)

Gennerate MPO for the N-spin long-range XYZ model with external field $\vec{h}=(h_x, 0, h_z)$, , defined by the Hamiltonian

source
MPSDynamics.protontransfermpoMethod
protontransfermpo(ω0e,ω0k,x0e,x0k, Δ, dRC, d, N, chainparams, RCparams, λreorg)

Generate a MPO for a system described in space with a reaction coordinate (RC) tensor. The RC tensor is coupled to a bosonic bath, taking into account the induced reorganization energy.

$H_S + H_{RC} + H_{int}^{S-RC} = \omega^0_{e} |e\rangle \langle e| + \omega^0_{k} |k\rangle \langle k| + \Delta (|e\rangle \langle k| + |k\rangle \langle e|) + \omega_{RC} (d^{\dagger}d + \frac{1}{2}) + g_{e} |e\rangle \langle e|( d + d^{\dagger})+ g_{k} |k \rangle \langle k|( d + d^{\dagger})$ $H_B + H_{int}^{RC-B} = \int_{-∞}^{+∞} dk ω_k b_k^\dagger b_k - (d + d^{\dagger})\int_0^∞ dω\sqrt{J(ω)}(b_ω^\dagger+b_ω) + \lambda_{reorg}(d + d^{\dagger})^2$. $\lambda_{reorg} = \int \frac{J(\omega)}{\omega}d\omega$.

Arguments

  • ω0e: enol energy at x=0
  • ω0k: keto energy at x=0
  • x0e: enol equilibrium displacement
  • x0k: keto equilibrium displacement
  • Δ: direct coupling between enol and keto
  • dRC: fock space of the RC tensor
  • d: number of Fock states of the chain modes
  • N: length of the chain
  • chainparams: chain parameters, of the form chainparams=$[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$, can be chosen to represent any arbitrary spectral density $J(ω)$ at any temperature.
  • RCparams: RC tensor parameter, of the form RCparams=$[ωRC,-g/x]$
  • λreorg: reorganization energy
source
MPSDynamics.puredephasingmpoMethod
puredephasingmpo(ΔE, dchain, Nchain, chainparams; tree=false)

Generate MPO for a pure dephasing model, defined by the Hamiltonian $H = \frac{ΔE}{2} σ_z + \frac{σ_z}{2} c_0 (b_0^\dagger + b_0) + \sum_{i=0}^{N-1} t_i (b_{i+1}^\dagger b_i +h.c.) + \sum_{i=0}^{N-1} ϵ_i b_i^\dagger b_i$

The spin is on site 1 of the MPS and the bath modes are to the right.

Arguments

* `ΔE::Real`: energy splitting of the spin
+The chain parameters are given in the standard form: `chainparams` ``=[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]``.
source
MPSDynamics.isingmpoMethod
isingmpo(N; J=1.0, h=1.0)

Generate MPO for the N-spin 1D Ising model with external field $\vec{h} = (0,0,h)$, defined by the Hamiltonian

$H = \sum_{n=1}^{N-1} -J_x σ_x^{n} σ_x^{n+1} + \sum_{n=1}^{N}(- h_z σ_z^{n})$

with $σ_x^{n}, σ_y^{n}, σ_z^{n}$ the Pauli spin-1/2 matrices of the $n^\text{th}$ site.

source
MPSDynamics.longrange_xyzmpoFunction
longrange_xyzmpo(N::Int, α::Float64=0.; Jx=1.0, Jy=Jx, Jz=Jx, hx=0., hz=0.)

Gennerate MPO for the N-spin long-range XYZ model with external field $\vec{h}=(h_x, 0, h_z)$, , defined by the Hamiltonian

source
MPSDynamics.protontransfermpoMethod
protontransfermpo(ω0e,ω0k,x0e,x0k, Δ, dRC, d, N, chainparams, RCparams, λreorg)

Generate a MPO for a system described in space with a reaction coordinate (RC) tensor. The RC tensor is coupled to a bosonic bath, taking into account the induced reorganization energy.

$H_S + H_{RC} + H_{int}^{S-RC} = \omega^0_{e} |e\rangle \langle e| + \omega^0_{k} |k\rangle \langle k| + \Delta (|e\rangle \langle k| + |k\rangle \langle e|) + \omega_{RC} (d^{\dagger}d + \frac{1}{2}) + g_{e} |e\rangle \langle e|( d + d^{\dagger})+ g_{k} |k \rangle \langle k|( d + d^{\dagger})$ $H_B + H_{int}^{RC-B} = \int_{-∞}^{+∞} dk ω_k b_k^\dagger b_k - (d + d^{\dagger})\int_0^∞ dω\sqrt{J(ω)}(b_ω^\dagger+b_ω) + \lambda_{reorg}(d + d^{\dagger})^2$. $\lambda_{reorg} = \int \frac{J(\omega)}{\omega}d\omega$.

Arguments

  • ω0e: enol energy at x=0
  • ω0k: keto energy at x=0
  • x0e: enol equilibrium displacement
  • x0k: keto equilibrium displacement
  • Δ: direct coupling between enol and keto
  • dRC: fock space of the RC tensor
  • d: number of Fock states of the chain modes
  • N: length of the chain
  • chainparams: chain parameters, of the form chainparams=$[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$, can be chosen to represent any arbitrary spectral density $J(ω)$ at any temperature.
  • RCparams: RC tensor parameter, of the form RCparams=$[ωRC,-g/x]$
  • λreorg: reorganization energy
source
MPSDynamics.puredephasingmpoMethod
puredephasingmpo(ΔE, dchain, Nchain, chainparams; tree=false)

Generate MPO for a pure dephasing model, defined by the Hamiltonian $H = \frac{ΔE}{2} σ_z + \frac{σ_z}{2} c_0 (b_0^\dagger + b_0) + \sum_{i=0}^{N-1} t_i (b_{i+1}^\dagger b_i +h.c.) + \sum_{i=0}^{N-1} ϵ_i b_i^\dagger b_i$

The spin is on site 1 of the MPS and the bath modes are to the right.

Arguments

* `ΔE::Real`: energy splitting of the spin
 * `dchain::Int`: physical dimension of the chain sites truncated Hilbert spaces
 * `Nchain::Int`: number of sites in the chain
 * `chainparams::Array{Real,1}`: chain parameters for the bath chain. The chain parameters are given in the standard form: `chainparams` ``=[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]``.
-* `tree::Bool`: if true, return a `TreeNetwork` object, otherwise return a vector of MPO tensors
source
MPSDynamics.spinbosonmpoMethod
spinbosonmpo(ω0, Δ, d, N, chainparams; rwa=false, tree=false)

Generate MPO for a spin-1/2 coupled to a chain of harmonic oscillators, defined by the Hamiltonian

$H = \frac{ω_0}{2}σ_z + Δσ_x + c_0σ_x(b_0^\dagger+b_0) + \sum_{i=0}^{N-1} t_i (b_{i+1}^\dagger b_i +h.c.) + \sum_{i=0}^{N} ϵ_ib_i^\dagger b_i$.

The spin is on site 1 of the MPS and the bath modes are to the right.

This Hamiltonain is unitarily equivalent (before the truncation to N sites) to the spin-boson Hamiltonian defined by

$H = \frac{ω_0}{2}σ_z + Δσ_x + σ_x\int_0^∞ dω\sqrt{J(ω)}(b_ω^\dagger+b_ω) + \int_0^∞ dω ωb_ω^\dagger b_ω$.

The chain parameters, supplied by chainparams=$[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$, can be chosen to represent any arbitrary spectral density $J(ω)$ at any temperature.

The rotating wave approximation can be made by setting rwa=true.

source
MPSDynamics.tightbinding_mpoMethod
tightbinding_mpo(N, ϵd, chainparams1, chainparams2)

Generate MPO for a tight-binding chain of N fermionic sites with a single impurity site (fermionic as well) of energy ϵd at the center. The impurity is coupled to two leads, each described by a set of chain parameters. The interactions are nearest-neighbour, with the first N/2-1 sites corresponding to the first lead, the Nth site corresponding to the impurity, and the rest of the sites corresponding to the second lead.

Arguments

* `N::Int`: number of sites in the chain
+* `tree::Bool`: if true, return a `TreeNetwork` object, otherwise return a vector of MPO tensors
source
MPSDynamics.spinbosonmpoMethod
spinbosonmpo(ω0, Δ, d, N, chainparams; rwa=false, tree=false)

Generate MPO for a spin-1/2 coupled to a chain of harmonic oscillators, defined by the Hamiltonian

$H = \frac{ω_0}{2}σ_z + Δσ_x + c_0σ_x(b_0^\dagger+b_0) + \sum_{i=0}^{N-1} t_i (b_{i+1}^\dagger b_i +h.c.) + \sum_{i=0}^{N} ϵ_ib_i^\dagger b_i$.

The spin is on site 1 of the MPS and the bath modes are to the right.

This Hamiltonain is unitarily equivalent (before the truncation to N sites) to the spin-boson Hamiltonian defined by

$H = \frac{ω_0}{2}σ_z + Δσ_x + σ_x\int_0^∞ dω\sqrt{J(ω)}(b_ω^\dagger+b_ω) + \int_0^∞ dω ωb_ω^\dagger b_ω$.

The chain parameters, supplied by chainparams=$[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$, can be chosen to represent any arbitrary spectral density $J(ω)$ at any temperature.

The rotating wave approximation can be made by setting rwa=true.

source
MPSDynamics.tightbinding_mpoMethod
tightbinding_mpo(N, ϵd, chainparams1, chainparams2)

Generate MPO for a tight-binding chain of N fermionic sites with a single impurity site (fermionic as well) of energy ϵd at the center. The impurity is coupled to two leads, each described by a set of chain parameters. The interactions are nearest-neighbour, with the first N/2-1 sites corresponding to the first lead, the Nth site corresponding to the impurity, and the rest of the sites corresponding to the second lead.

Arguments

* `N::Int`: number of sites in the chain
 * `ϵd::Real`: energy of the impurity site at the center, as Ed - μ, where μ is the chemical potential
 * chainparams1::Array{Real,1}: chain parameters for the first lead
-* chainparams2::Array{Real,1}: chain parameters for the second lead

The chain parameters are given in the standard form: chainparams $=[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$.

source
MPSDynamics.twobathspinmpoFunction
twobathspinmpo(ω0, Δ, Nl, Nr, dl, dr, chainparamsl=[fill(1.0,N),fill(1.0,N-1), 1.0], chainparamsr=chainparamsl; tree=false)

Generate MPO for a spin-1/2 coupled to two chains of harmonic oscillators, defined by the Hamiltonian

$H = \frac{ω_0}{2}σ_z + Δσ_x + c_0^rσ_x(b_0^\dagger+b_0) + \sum_{i=0}^{N_r-1} t_i^r (b_{i+1}^\dagger b_i +h.c.) + \sum_{i=0}^{N_r} ϵ_i^rb_i^\dagger b_i + c_0^lσ_x(d_0^\dagger+d_0) + \sum_{i=0}^{N_l-1} t_i^l (d_{i+1}^\dagger d_i +h.c.) + \sum_{i=0}^{N_l} ϵ_i^l d_i^\dagger d_i$.

The spin is on site $N_l + 1$ of the MPS, surrounded by the left chain modes and the right chain modes.

This Hamiltonain is unitarily equivalent (before the truncation to N sites) to the spin-boson Hamiltonian defined by

$H = \frac{ω_0}{2}σ_z + Δσ_x + σ_x\int_0^∞ dω\sqrt{J(ω)}(b_ω^\dagger+b_ω) + \int_0^∞ dω ωb_ω^\dagger b_ωi + σ_x\int_0^∞ dω\sqrt{J^l(ω)}(d_ω^\dagger+d_ω) + \int_0^∞ dω ωd_ω^\dagger d_ω$.

The chain parameters, supplied by chainparams=$[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$, can be chosen to represent any arbitrary spectral density $J(ω)$ at any temperature. The two chains can have a different spectral density.

source
MPSDynamics.xxzmpoFunction
xxzmpo(N::Int, Δ = 1.0, J=1.0) = xyzmpo(N; Jx=J, Jy=J, Jz=J*Δ)

Generate MPO for the N-spin XXZ model, defined by the Hamiltonian

$H = \sum_{n=1}^{N-1} -J σ_x^{n} σ_x^{n+1} - J σ_y^{n} σ_y^{n+1} - \Delta J σ_z^{n} σ_z^{n+1}$

with $σ_x^{n}, σ_y^{n}, σ_z^{n}$ the Pauli spin-1/2 matrices of the $n^\text{th}$ site.

source
MPSDynamics.xyzmpoMethod
xyzmpo(N::Int; Jx=1.0, Jy=Jx, Jz=Jx, hx=0., hz=0.)

Generate MPO for the N-spin XYZ model with external field $\vec{h}=(h_x, 0, h_z)$, , defined by the Hamiltonian

$H = \sum_{n=1}^{N-1} -J_x σ_x^{n} σ_x^{n+1} - J_y σ_y^{n} σ_y^{n+1} - J_z σ_z^{n} σ_z^{n+1} + \sum_{n=1}^{N}(- h_x σ_x^{n} - h_z σ_z^{n})$

with $σ_x^{n}, σ_y^{n}, σ_z^{n}$ the Pauli spin-1/2 matrices of the $n^\text{th}$ site.

source

Chain-Mapping

MPSDynamics.chaincoeffs_fermionicMethod
chaincoeffs_fermionic(nummodes, β, chain; ϵ=x, ωc=1, mc=4, mp=0, AB=nothing, iq=1, idelta=2, procedure=:Lanczos, Mmax=5000, save=true)

Generate chain coefficients $[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$ for a fermionic bath at the inverse temperature β.

Arguments

  • nummodes: Number of bath modes
  • β: inverse temperature
  • chain: 1 if the chain modes are empty, 2 if the chain modes are filled
  • ϵ: user-provided dispersion relation. Should be a function f(x) where x is the wavenumber
  • J: user-provided spectral density. Should be a function f(x) where x is the wavenumber
  • ωc: the maximum frequency allowwed in the spectral density
  • mc: the number of component intervals
  • mp: the number of points in the discrete part of the measure (mp=0 if there is none)
  • iq: a parameter to be set equal to 1, if the user provides his or her own quadrature routine, and different from 1 otherwise
  • idelta: a parameter whose default value is 1, but is preferably set equal to 2, if iq=1 and the user provides Gauss-type quadrature routines
  • procedure: choice between the Stieltjes and the Lanczos procedure
  • AB: component intervals
  • Mmax: maximum number of integration points
  • save: if true the coefficients are saved
source
MPSDynamics.chaincoeffs_finiteTFunction
chaincoeffs_finiteT(nummodes, β, ohmic=true; α, s, J, ωc=1, mc=4, mp=0, AB=nothing, iq=1, idelta=2, procedure=:Lanczos, Mmax=5000, save=true)

Generate chain coefficients $[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$ for a harmonic bath at the inverse temperature β.

By default a Ohmic spectral density $J(ω) = 2αω_c (\frac{ω}{ω_c})^s θ(ω-ω_c)$ is considered. Users can provide their own spectral density.

Arguments

  • nummodes: Number of bath modes
  • β: inverse temperature
  • ohmic: true if the spectral density is Ohmic, false if the user provides its own spectral density
  • α: Kondo parameter of the Ohmic spectral density
  • s: ohmicity
  • J: user-provided spectral density. Should be a function f(x,i) where x is the frequency and i ∈ {1,...,mc} labels the intervals on which the SD is defined
  • ωc: the maximum frequency of the Ohmic spectral density
  • mc: the number of component intervals
  • mp: the number of points in the discrete part of the measure (mp=0 if there is none)
  • iq: a parameter to be set equal to 1, if the user provides his or her own quadrature routine, and different from 1 otherwise
  • idelta: a parameter whose default value is 1, but is preferably set equal to 2, if iq=1 and the user provides Gauss-type quadrature routines
  • procedure: choice between the Stieltjes and the Lanczos procedure
  • AB: component intervals
  • Mmax: maximum number of integration points
  • save: if true the coefficients are saved
source
MPSDynamics.gaussMethod
gauss(N,ab)

Gauss quadrature rule for N sites on an interval ab. Given a weight function w encoded by the Nx2 array ab of the first N recurrence coefficients for the associated orthogonal polynomials, the first column of ab containing the N alpha-coefficients and the second column the N beta-coefficients, the call xw = gauss(N,ab) generates the nodes and weights xw of the N-point Gauss quadrature rule for the weight function w. The nodes, in increasing order, are stored in the first column, the n corresponding weights in the second column, of the Nx2 array xw.

source
MPSDynamics.lanczosMethod
lanczos(N,xw)

Given the discrete inner product whose nodes are contained in the first column, and whose weights are contained in the second column, of the Nx2 array xw, the call ab=lanczos(N,xw) generates the first N recurrence coefficients ab of the corresponding discrete orthogonal polynomials. The N alpha-coefficients are stored in the first column, the N beta-coefficients in the second column, of the Nx2 array ab.

The script is adapted from the routine RKPW in W.B. Gragg and W.J. Harrod, ``The numerically stable reconstruction of Jacobi matrices from spectral data'', Numer. Math. 44 (1984), 317-335.

source
MPSDynamics.stieltjesMethod
stieltjes(N,xw)

Discretized Stieltjes procedure. Given the discrete inner product whose nodes are contained in the first column, and whose weights are contained in the second column, of the Nx2 array xw, the call ab=stieltjes(N,xw) generates the first N recurrence coefficients ab of the corresponding discrete orthogonal polynomials. The N alpha- coefficients are stored in the first column, the N beta-coefficients in the second column, of the Nx2 array ab.

source

Dynamics propagation function

MPSDynamics.runsimMethod
runsim(dt, tmax, A, H; 
+* chainparams2::Array{Real,1}: chain parameters for the second lead

The chain parameters are given in the standard form: chainparams $=[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$.

source
MPSDynamics.twobathspinmpoFunction
twobathspinmpo(ω0, Δ, Nl, Nr, dl, dr, chainparamsl=[fill(1.0,N),fill(1.0,N-1), 1.0], chainparamsr=chainparamsl; tree=false)

Generate MPO for a spin-1/2 coupled to two chains of harmonic oscillators, defined by the Hamiltonian

$H = \frac{ω_0}{2}σ_z + Δσ_x + c_0^rσ_x(b_0^\dagger+b_0) + \sum_{i=0}^{N_r-1} t_i^r (b_{i+1}^\dagger b_i +h.c.) + \sum_{i=0}^{N_r} ϵ_i^rb_i^\dagger b_i + c_0^lσ_x(d_0^\dagger+d_0) + \sum_{i=0}^{N_l-1} t_i^l (d_{i+1}^\dagger d_i +h.c.) + \sum_{i=0}^{N_l} ϵ_i^l d_i^\dagger d_i$.

The spin is on site $N_l + 1$ of the MPS, surrounded by the left chain modes and the right chain modes.

This Hamiltonain is unitarily equivalent (before the truncation to N sites) to the spin-boson Hamiltonian defined by

$H = \frac{ω_0}{2}σ_z + Δσ_x + σ_x\int_0^∞ dω\sqrt{J(ω)}(b_ω^\dagger+b_ω) + \int_0^∞ dω ωb_ω^\dagger b_ωi + σ_x\int_0^∞ dω\sqrt{J^l(ω)}(d_ω^\dagger+d_ω) + \int_0^∞ dω ωd_ω^\dagger d_ω$.

The chain parameters, supplied by chainparams=$[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$, can be chosen to represent any arbitrary spectral density $J(ω)$ at any temperature. The two chains can have a different spectral density.

source
MPSDynamics.xxzmpoFunction
xxzmpo(N::Int, Δ = 1.0, J=1.0) = xyzmpo(N; Jx=J, Jy=J, Jz=J*Δ)

Generate MPO for the N-spin XXZ model, defined by the Hamiltonian

$H = \sum_{n=1}^{N-1} -J σ_x^{n} σ_x^{n+1} - J σ_y^{n} σ_y^{n+1} - \Delta J σ_z^{n} σ_z^{n+1}$

with $σ_x^{n}, σ_y^{n}, σ_z^{n}$ the Pauli spin-1/2 matrices of the $n^\text{th}$ site.

source
MPSDynamics.xyzmpoMethod
xyzmpo(N::Int; Jx=1.0, Jy=Jx, Jz=Jx, hx=0., hz=0.)

Generate MPO for the N-spin XYZ model with external field $\vec{h}=(h_x, 0, h_z)$, , defined by the Hamiltonian

$H = \sum_{n=1}^{N-1} -J_x σ_x^{n} σ_x^{n+1} - J_y σ_y^{n} σ_y^{n+1} - J_z σ_z^{n} σ_z^{n+1} + \sum_{n=1}^{N}(- h_x σ_x^{n} - h_z σ_z^{n})$

with $σ_x^{n}, σ_y^{n}, σ_z^{n}$ the Pauli spin-1/2 matrices of the $n^\text{th}$ site.

source

Chain-Mapping

MPSDynamics.chaincoeffs_fermionicMethod
chaincoeffs_fermionic(nummodes, β, chain; ϵ=x, ωc=1, mc=4, mp=0, AB=nothing, iq=1, idelta=2, procedure=:Lanczos, Mmax=5000, save=true)

Generate chain coefficients $[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$ for a fermionic bath at the inverse temperature β.

Arguments

  • nummodes: Number of bath modes
  • β: inverse temperature
  • chain: 1 if the chain modes are empty, 2 if the chain modes are filled
  • ϵ: user-provided dispersion relation. Should be a function f(x) where x is the wavenumber
  • J: user-provided spectral density. Should be a function f(x) where x is the wavenumber
  • ωc: the maximum frequency allowwed in the spectral density
  • mc: the number of component intervals
  • mp: the number of points in the discrete part of the measure (mp=0 if there is none)
  • iq: a parameter to be set equal to 1, if the user provides his or her own quadrature routine, and different from 1 otherwise
  • idelta: a parameter whose default value is 1, but is preferably set equal to 2, if iq=1 and the user provides Gauss-type quadrature routines
  • procedure: choice between the Stieltjes and the Lanczos procedure
  • AB: component intervals
  • Mmax: maximum number of integration points
  • save: if true the coefficients are saved
source
MPSDynamics.chaincoeffs_finiteTFunction
chaincoeffs_finiteT(nummodes, β, ohmic=true; α, s, J, ωc=1, mc=4, mp=0, AB=nothing, iq=1, idelta=2, procedure=:Lanczos, Mmax=5000, save=true)

Generate chain coefficients $[[ϵ_0,ϵ_1,...],[t_0,t_1,...],c_0]$ for a harmonic bath at the inverse temperature β.

By default a Ohmic spectral density $J(ω) = 2αω_c (\frac{ω}{ω_c})^s θ(ω-ω_c)$ is considered. Users can provide their own spectral density.

Arguments

  • nummodes: Number of bath modes
  • β: inverse temperature
  • ohmic: true if the spectral density is Ohmic, false if the user provides its own spectral density
  • α: Kondo parameter of the Ohmic spectral density
  • s: ohmicity
  • J: user-provided spectral density. Should be a function f(x,i) where x is the frequency and i ∈ {1,...,mc} labels the intervals on which the SD is defined
  • ωc: the maximum frequency of the Ohmic spectral density
  • mc: the number of component intervals
  • mp: the number of points in the discrete part of the measure (mp=0 if there is none)
  • iq: a parameter to be set equal to 1, if the user provides his or her own quadrature routine, and different from 1 otherwise
  • idelta: a parameter whose default value is 1, but is preferably set equal to 2, if iq=1 and the user provides Gauss-type quadrature routines
  • procedure: choice between the Stieltjes and the Lanczos procedure
  • AB: component intervals
  • Mmax: maximum number of integration points
  • save: if true the coefficients are saved
source
MPSDynamics.gaussMethod
gauss(N,ab)

Gauss quadrature rule for N sites on an interval ab. Given a weight function w encoded by the Nx2 array ab of the first N recurrence coefficients for the associated orthogonal polynomials, the first column of ab containing the N alpha-coefficients and the second column the N beta-coefficients, the call xw = gauss(N,ab) generates the nodes and weights xw of the N-point Gauss quadrature rule for the weight function w. The nodes, in increasing order, are stored in the first column, the n corresponding weights in the second column, of the Nx2 array xw.

source
MPSDynamics.lanczosMethod
lanczos(N,xw)

Given the discrete inner product whose nodes are contained in the first column, and whose weights are contained in the second column, of the Nx2 array xw, the call ab=lanczos(N,xw) generates the first N recurrence coefficients ab of the corresponding discrete orthogonal polynomials. The N alpha-coefficients are stored in the first column, the N beta-coefficients in the second column, of the Nx2 array ab.

The script is adapted from the routine RKPW in W.B. Gragg and W.J. Harrod, ``The numerically stable reconstruction of Jacobi matrices from spectral data'', Numer. Math. 44 (1984), 317-335.

source
MPSDynamics.stieltjesMethod
stieltjes(N,xw)

Discretized Stieltjes procedure. Given the discrete inner product whose nodes are contained in the first column, and whose weights are contained in the second column, of the Nx2 array xw, the call ab=stieltjes(N,xw) generates the first N recurrence coefficients ab of the corresponding discrete orthogonal polynomials. The N alpha- coefficients are stored in the first column, the N beta-coefficients in the second column, of the Nx2 array ab.

source

Dynamics propagation function

MPSDynamics.runsimMethod
runsim(dt, tmax, A, H; 
 	method=:TDVP1, 
 	machine=LocalMachine(), 
 	params=[], 
@@ -120,4 +120,4 @@
             unid=randstring(5),
             name=nothing,
 	kwargs...
-	)

Propagate the MPS A with the MPO H up to time tmax in time steps of dt. The final MPS is returned to A and the measurement data is returned to dat

Arguments

  • method: Several methods are implemented in MPSDynamics. :TDVP1 refers to 1-site TDVP on tree and chain MPS, :TDVP2 refers to 2-site TDVP on chain MPS, :DTDVP refers to a variant of 1-site TDVP with dynamics bond-dimensions on chain MPS
  • machine: LocalMachine() points local ressources, RemoteMachine() points distant ressources
  • params: list of parameters written in the log.txt file to describe the dynamics. Can be listed with @LogParams().
  • obs: list of observables that will be measured at every time step for the most accurate convergence parameter supplied to convparams
  • convobs: list of observables that will be measure at every time step for every convergence parameter supplied to convparams
  • convparams: list of convergence parameter with which the propagation will be calculated for every parameter. At each parameter, convobs are measured while obs are measured only for the most accurate dynamics
  • save: Used to choose whether the data will also be saved to a file
  • plot: Used to choose whether plots for 1D observables will be automatically generated and saved along with the data
  • savedir: Used to specify the path where resulting files are stored
  • unid: Used to specify the name of the directory containing the resulting files
  • name: Used to describe the calculation. This name will appear in the log.txt file
source

Advanced

+ )

Propagate the MPS A with the MPO H up to time tmax in time steps of dt. The final MPS is returned to A and the measurement data is returned to dat

Arguments

  • method: Several methods are implemented in MPSDynamics. :TDVP1 refers to 1-site TDVP on tree and chain MPS, :TDVP2 refers to 2-site TDVP on chain MPS, :DTDVP refers to a variant of 1-site TDVP with dynamics bond-dimensions on chain MPS
  • machine: LocalMachine() points local ressources, RemoteMachine() points distant ressources
  • params: list of parameters written in the log.txt file to describe the dynamics. Can be listed with @LogParams().
  • obs: list of observables that will be measured at every time step for the most accurate convergence parameter supplied to convparams
  • convobs: list of observables that will be measure at every time step for every convergence parameter supplied to convparams
  • convparams: list of convergence parameter with which the propagation will be calculated for every parameter. At each parameter, convobs are measured while obs are measured only for the most accurate dynamics
  • save: Used to choose whether the data will also be saved to a file
  • plot: Used to choose whether plots for 1D observables will be automatically generated and saved along with the data
  • savedir: Used to specify the path where resulting files are stored
  • unid: Used to specify the name of the directory containing the resulting files
  • name: Used to describe the calculation. This name will appear in the log.txt file
source

Advanced

diff --git a/docs/nutshell/index.html b/docs/nutshell/index.html index a7d7221..fc08204 100644 --- a/docs/nutshell/index.html +++ b/docs/nutshell/index.html @@ -1,2 +1,2 @@ -In a nutshell: MPSDynamics.jl for open quantum systems · MPSDynamics.jl

In a nutshell: MPSDynamics.jl for open quantum systems

MPSDynamics.jl was originally developed to perform tensor network simulations of open quantum systems by solving the Schrödinger equation for the closed {System + Environment}. The key idea to construct the simulations is to reformulate the open quantum system Hamiltonian as a one-dimensional many-body problem with nearest-neighbor interactions. The dynamics are then efficiently simulated with Tensor Networks methods.

Sketch of the different ingredients behind MPSDynamics

The starting point is a system linearly coupled to a bosonic environment, where the coupling between system and environment is specified by the spectral density function $J(\omega)$: the prototypical example being The Spin-Boson Model. At finite temperature, the initial state of the environment will be a thermal state (mixed), requiring density matrix formalism and thus making the problem more complex. To circumvent this issue, we consider instead an extended environment, with coupling to the system characterized by a thermalized spectral density function $J(\omega,\beta)$. The two environments induce the same reduced dynamics on the system, enabling us to deal with pure states only[1]. The vacuum state (pure) of the extended environment corresponds to the thermal state of the original environment.

To exploit the computational efficiency of the matrix product states (MPS) description of pure states, we apply the so called Chain-Mapping of bosonic environments —a unitary transformation dependent on $J(\omega,\beta)$— to the Spin-Boson Hamiltonian, mapping it on a chain Hamiltonian with nearest-neighbor interactions. This enables efficient representation of the full {System + Environment} state and its time evolution using the Time-Dependent Variational Principle.

To go further, you will find in this documentation:

If this package was useful in your work, do not forget Citation. And if you would like to get involved in its development, you can find out How to Contribute.

+In a nutshell: MPSDynamics.jl for open quantum systems · MPSDynamics.jl

In a nutshell: MPSDynamics.jl for open quantum systems

MPSDynamics.jl was originally developed to perform tensor network simulations of open quantum systems by solving the Schrödinger equation for the closed {System + Environment}. The key idea to construct the simulations is to reformulate the open quantum system Hamiltonian as a one-dimensional many-body problem with nearest-neighbor interactions. The dynamics are then efficiently simulated with Tensor Networks methods.

Sketch of the different ingredients behind MPSDynamics

The starting point is a system linearly coupled to a bosonic environment, where the coupling between system and environment is specified by the spectral density function $J(\omega)$: the prototypical example being The Spin-Boson Model. At finite temperature, the initial state of the environment will be a thermal state (mixed), requiring density matrix formalism and thus making the problem more complex. To circumvent this issue, we consider instead an extended environment, with coupling to the system characterized by a thermalized spectral density function $J(\omega,\beta)$. The two environments induce the same reduced dynamics on the system, enabling us to deal with pure states only[1]. The vacuum state (pure) of the extended environment corresponds to the thermal state of the original environment.

To exploit the computational efficiency of the matrix product states (MPS) description of pure states, we apply the so called Chain-Mapping of bosonic environments —a unitary transformation dependent on $J(\omega,\beta)$— to the Spin-Boson Hamiltonian, mapping it on a chain Hamiltonian with nearest-neighbor interactions. This enables efficient representation of the full {System + Environment} state and its time evolution using the Time-Dependent Variational Principle.

To go further, you will find in this documentation:

If this package was useful in your work, do not forget Citation. And if you would like to get involved in its development, you can find out How to Contribute.

diff --git a/docs/search/index.html b/docs/search/index.html index f7ef879..1bdc713 100644 --- a/docs/search/index.html +++ b/docs/search/index.html @@ -1,2 +1,2 @@ -Search · MPSDynamics.jl

Loading search...

    +Search · MPSDynamics.jl

    Loading search...

      diff --git a/docs/theory/index.html b/docs/theory/index.html index c0f6f55..7b5a9ea 100644 --- a/docs/theory/index.html +++ b/docs/theory/index.html @@ -4,4 +4,4 @@ \end{aligned}\]

      where $\hat a_\omega$ ($\hat a^\dagger_\omega$) is a bosonic annihilation (creation) operator for a normal mode of the environment of energy $\hbar\omega$, $\hat{A}_S$ is a system operator, and $J(\omega) = \sum_k |g_k|^2\delta(\omega - \omega_k)$ is the bath spectral density (SD), defined with the microscopic system-environment coupling strength $g_k$. The SD quantifies the coupling strengths of the different normal modes of the environment with the system. Any SD that is not flat corresponds to a non-Markovian environment.

      Zero Temperature

      Let us consider the Hamiltonian presented in Eq.(1). To investigate its rich phenomenology, using the powerful tools provided by tensor network techniques, it is convenient to map the system and its environment from a star-like to a chain-like configuration, with local interactions. To do so, we introduce a unitary transformation of the continuous normal modes $\hat{a}_\omega$ to an infinite discrete set of interacting modes $\hat{b}_n$[chin_exact_2010].

      \[ \hat{a}_\omega = \sum_{n=0}^{+\infty} U_n(\omega)\hat{b}_n = \sum_{n=0}^{+\infty} \sqrt{J(\omega)}P_n(\omega)\hat{b}_n\ ,\]

      where $P_n(\omega)$ are orthonormal polynomials such that

      \[ \int_{0}^{+\infty}P_n(\omega)P_m(\omega)J(\omega)\mathrm{d}\omega = \delta_{n,m}\ ;\]

      and the inverse transformation is

      \[ \hat{b}_n = \int_0^{+\infty} U^*_n(\omega)\hat{a}_\omega\mathrm{d}\omega\ .\]

      Note that the orthonormality of the polynomials ensures the unitarity of the transformation defined in Eq.(2). The mapping from a continuous set of modes to a (still infinite) discrete set might seem counter-intuitive, however it is a direct consequence of the separability of the underlying Hilbert space.

      Under this transformation, the Hamiltonian in Eq.(1) becomes

      \[ \hat{H}= \hat{H}_S + \sum_{n=0}^{+\infty}\varepsilon_n\hat{b}_n^\dagger\hat{b}_n + t_n(\hat{b}_{n+1}^\dagger\hat{b}_n + \mathrm{h.c.}) + c_0 \hat{A}_S(\hat{b}_0 + \hat{b}_0^\dagger)\ .\]

      Hence, this mapping transforms the normal bath Hamiltonian into a tight-binding Hamiltonian with on-site energies $\varepsilon_n$ and hopping energies $t_n$. Another important consequence of this mapping is that now the system only interacts with the first mode $n = 0$ of the chain-mapped environment. The chain coefficients $\varepsilon_n$, $t_n$, and the coupling $c_0$ depend solely on the SD.

      This makes chain mapping a tool of choice for describing systems coupled to environment with highly structured SD (e.g. experimentally measured or calculated ab initio)[chin_role_2013][alvertis_nonequilibrium_2019][dunnett_influence_2021][caycedosoler_exact_2022]. In this new representation, the Hamiltonian in Eq.(5) has naturally a 1D chain topology. This makes its representation as a Matrix Product Operator (MPO) and the representation of the joint {System + Environment} wave-function as a Matrix Product State (MPS) suited [orus_practical_2014][paeckel_timeevolution_2019].

      The orthogonal polynomial-based chain mapping and the subsequent representation of the joint wave-function as a MPS (and the operators as MPO) are the building blocks of the Time-dependent Density operator with Orthonormal Polynomials Algorithm (TEDOPA) one of the state-of-the-art numerically exact method to simulate the dynamics of open quantum systems especially in the non-Markovian, non-perturbative regimes both at zero and finite temperatures [prior_efficient_2010][woods_simulating_2015][tamascelli_efficient_2019][dunnett_simulating_2021][lacroix_unveiling_2021].

      Finite Temperature with T-TEDOPA

      Assuming a unitary evolution for both the system and environment, the system's dynamics can be isolated by tracing out the environmental degrees of freedom. The density operator for the system at time $t$ is described as

      \[\hat{\rho}_S(t) = \text{T}r_E\left\{\hat{U}(t) \hat{\rho}_S(0) \otimes \hat{\rho}_E(0) \hat{U}^\dagger(t)\right\}.\]

      Initially, the system state, $\hat{\rho}_S(0)$, can be pure or mixed, and the environment is in a thermal state defined by the inverse temperature $\beta = (k_B T)^{-1}$. This state is represented by a product of Gaussian states

      \[\hat{\rho}_E(0) = \bigotimes_\omega \frac{e^{-\beta \omega \hat{a}_\omega^\dagger \hat{a}_\omega}}{Z_\omega(\beta)} .\]

      The system's evolution is dictated by the environment's two-time correlation function $S(t)$, which in turn is determined by the spectral density function $J$ and the temperature $\beta$ via the Bose-Einstein distribution $n_\omega(\beta)$

      \[S(t) = \int_0^\infty d\omega J(\omega)\left[e^{-i\omega t}(1 + n_\omega(\beta)) + e^{i\omega t} n_\omega(\beta)\right] .\]

      To simulate finite temperature effects using a zero-temperature model with the T-TEDOPA method [tamascelli_efficient_2019], we extend the spectral density function to cover both positive and negative frequencies, allowing us to use a pure state description for the environment. This is achieved by defining a new spectral density function $J(\omega, \beta)$ that incorporates the Boltzmann factors, supporting the entire real axis

      \[J(\omega, \beta) = \frac{\text{sign}(\omega)J(\left|\omega\right|)}{2} \Big(1 + \coth\Big(\frac{\beta \omega}{2}\Big)\Big).\]

      This modified bath has the same correlation function $S(t)$ and thus allows us to maintain a pure state description of the environment, represented as a vacuum state, and avoid the computational complexities of density matrices

      \[\left|\text{vac}\right\rangle = \bigotimes_\omega \left|0_\omega\right\rangle .\]

      The Hamiltonian of the system interacting with this extended bath now includes temperature-dependent interactions:

      \[\hat{H} = \hat{H}_S + \int_{-\infty}^{+\infty} \mathrm{d}\omega \omega \hat{a}_\omega^\dagger \hat{a}_\omega + \hat{A}_S \otimes \int_{-\infty}^{+\infty} \mathrm{d}\omega \sqrt{J(\omega,\beta)}\left(\hat{a}_\omega^\dagger+\hat{a}_\omega\right),\]

      This method simplifies the simulation of finite temperature effects by treating them within an effective zero-temperature framework, thereby keeping the computational advantages of using pure states. In conclusion: the dynamics of the system resulting from the interaction with the original bath, starting in a thermal state at finite temperature, is exactly the same as the one resulting from the interaction with the extended environment, starting in the vacuum state at zero temperature. Once computed the chain coefficients at a given inverse temperature $\beta$, the time evolution of the vacuum state interacting with the extended environment can be efficiently simulated using MPS time evolution methods.

      Finite temperature with the thermofield transformation

      Finite temperature initial states of the system are challenging: in the previous section we have seen that a very efficient solution is to reabsorb the effect of the temperature inside of the spectral density function that characterizes the environment. De Vega and Bañuls present[devega_thermo_2015] another suggestive approach based on the idea of the thermofield transformation. The idea is to double the environmental degrees of freedom and then to apply a Bogoliubov transformation: the real environment in a thermal state is transformed into two virtual environments in the vacuum state, defined as the thermofield vacuum. For any operator of the real environment, the expectation values in the thermal state are equivalent to those calculated in the thermofield vacuum. Behind the thermofield approach there is the concept of purification: the initial mixed state of the environment can be represented as the partial trace of a pure state (the thermofield vacuum) defined on the larger Hilbert space of the modes of the two virtual environments at zero temperature. The interaction of the system and each one of the two environments is then mapped on two separate chains, using the TEDOPA chain mapping to define a unitary transformation that can be applied to the bath modes, in order to define new modes for the environment, mapping it from a star-like to a one dimensional chain-like configuration, which is very well suited for the application of tensor network techniques.

      In the thermofield approach, the first step is to introduce the auxiliary environment $E^{\text{aux}}$ of non-interacting bosonic modes of negative frequencies:

      \[ \hat H^\text{aux} = \hat H - \sum_k \omega_k \hat c_k^\dagger \hat c_k,\]

      where the Hamiltonian $\hat H$ is the bosonic Hamiltonian defined in Eq. \ref{eq:bosonic_ham}. The two environments, of positive and negative frequencies, are assumed to be in a thermal environment at inverse temperature $\beta$; the second step is to apply a thermal Bogoliubov transformation to change the basis. The applied transformation produces two-modes squeezed states:

      \[ \hat a_{1k}=e^{-iG} \hat b_k e^{iG}= \cosh(\theta_k) \hat b_k -\sinh(\theta_k) \hat c_k^\dagger \\ \hat a_{2k}=e^{-iG} \hat c_k e^{iG}= \cosh(\theta_k) \hat c_k -\sinh(\theta_k) \hat b_k^\dagger,\]

      where the exponent of the squeeze operator is $G = i \sum_k \theta_k(\hat b_k^\dagger \hat c_k^\dagger-\hat c_k \hat b_k)$, and $\theta_k$ is dependent on the temperature as in the following relations, where the number of excitations in the $k$-th mode is $n_k = 1/(e^{\beta \omega_k}-1)$:

      \[ \cosh(\theta_k) = \sqrt{1+n_k} = \sqrt{\frac{1}{1-e^{-\beta \omega_k}}} \\ \sinh(\theta_k) =\quad\sqrt{n_k}\quad= \sqrt{\frac{1}{e^{\beta \omega_k}-1}}.\]

      The Bogoliubov transformation defines a new squeezed vacuum state, which we write in terms of the vacuum state $\ket{\Omega_0}$ of the operators $\hat b_k$, $\hat c_k$:

      \[ |\Omega\rangle = e^{iG} |\Omega_0\rangle, \quad \text{such that: }\quad \hat a_{1k} |\Omega\rangle = 0, \hat a_{2k} |\Omega\rangle = 0.\]

      From the vacuum state, we can obtain the thermal state of the original environment:

      \[ \hat \rho_E = \text{Tr}_{\text{aux}}\{ |\Omega\rangle\langle\Omega| \},\]

      and it can be now used as pure an initial state for both of the environments. Moreover, the expectation value on $\ket{\Omega}$ of the number of physical modes $\hat n_k$ does not vanish:

      \[ n_k= \langle\Omega| \hat b_k^\dagger \hat b_k |\Omega\rangle = \sinh^2(\theta_k).\]

      Therefore, solving the dynamics given by the original Hamiltonian $\hat H$, starting from the initial condition $\hat \rho_S(0) \otimes \hat \rho_E(\beta)$, is equivalent to solving the dynamics given by the following Hamiltonian:

      \[ \hat H = \hat H_S +\hat H_E +\hat H_I = \\ - = \overbrace{\hat A_S}^{\hat H_S} + \overbrace{\sum_k \omega_k \big(\hat a_{1k}^\dagger \hat a_{1k} - \hat a_{2k}^\dagger \hat a_{2k} \big)}^{\hat H_E} + \overbrace{\hat L_S \otimes \sum_k g_{1k}(\hat a_{1k}^\dagger + \hat a_{1k})+\hat L_S \otimes \sum_k g_{2k}(\hat a_{2k}^\dagger + \hat a_{2k})}^{\hat H_I}.\]

      where $\hat L_S = \hat L_S^\dagger$, considering $\hat \rho_S(0) \otimes \ket{\Omega}\bra{\Omega}$ as the initial state of system and environment. It is this Hamiltonian that is mapped on two chains with TEDOPA, to be able to perform the time evolution using tensor network techniques.

      Computation of the chain coefficients

      A useful property of the orthonormal polynomials is that they obey a recurrence relation

      \[ P_n(\omega) = (C_{n-1}\omega - A_{n-1})P_{n-1}(\omega) + B_{n-1}P_{n-2}(\omega)\ ,\]

      where $A_n$ is related to the first moment of $P_n$, $B_n$ and $C_n$ to the norms of $P_n$ and $P_{n-1}$[appel_mathematics_2007]. This recurrence relation can be used to construct the polynomials with the conditions that $P_0(\omega) = ||p_0||^{-1} = \left(\int_{\mathbb{R}^{+}} J(\omega)\mathrm{d}\omega \right)^{-\frac{1}{2}}$ and $P_{-1}(\omega) = 0$, with $||\bullet||$ the norm of $\bullet$ with respect to the measure $J(\omega)$, and $P_n(\omega) = p_n(\omega)||p_n||^{-1}$ ; where the polynomials $\{p_n\}_{n\in\mathbb{N}}$ are the so called monic polynomials where the factor $a_n$ in front of $\omega^{n}$ is equal to 1.

      The energy of the chain mode $n$ is given by $\varepsilon_n = A_n C_n^{-1}$ and $t_n=C_n^{-1}$ is the coupling between mode $n$ and $n+1$[chin_exact_2010].

      The system couples only to the first mode with the coupling strength $c_0 = ||p_0||$.

      Explain that for some weight function/SD they are known analytically and that for others we can use the build-in routines inspired by Gautschi or the PolyChaos.jl package.

      Tensor Networks

      A multipartite quantum state $|\psi\rangle$, e.g. a $N$-site system where the sites can each be in a state $|\phi_i\rangle$ belonging to a $d$-dimensional Hilbert space, can be written as follows

      \[ |\psi\rangle = \sum_{\{i_k\}}c_{i_1\ldots i_N}|\phi_{i_1}\rangle\otimes\ldots\otimes|\phi_{i_N}\rangle\ ,\]

      where the complex numbers $c_{i_1\ldots i_N}$ are the amplitudes of each state $|\phi_{i_1}\rangle\otimes\ldots\otimes|\phi_{i_N}\rangle$ whose superpositions form in full generality the state $|\psi\rangle$. Thus the state $|\psi\rangle$ can be completely represented by a rank-$N$ tensor $c$ that is the collection of all possible amplitudes $c_{i_1\ldots i_N}$. Here by the rank of a tensor, we simply mean the number of indices it has.

      MPS

      The tensor $c$ of a quantum state $|\psi\rangle$ corresponding to a one-dimensional system can be decomposed into a product of $N$ smaller rank-3 tensors $T_{k}$ (except for the first and last sites where the tensors will have a rank-2)

      \[ c_{i_1\ldots i_N} = \sum_{\{\alpha\}} T^{\alpha_1}_{i_1}T^{\alpha_1\alpha_2\ }_{i_2}T^{\alpha_2\alpha_3\ }_{i_3}\ldots T^{\alpha_{N-1}}_{i_N} \ .\]

      In this form, the local tensor $T_k$ contains the information on the quantum state on site $k$ and its relation (especially the entanglement) with the neighbouring sites.

      The decomposition of the tensor of the amplitudes of a quantum state into a product of smaller rank tensors is called a Matrix Product State decomposition.

      The contracted indices $\alpha_k$ between the tensors are called virtual indices and carry information about the correlations between bi-partitions of the state at bond $k$. The number of different values a virtual index can take is called the bond dimension and is denoted $D$. The free indices $i_k$ associated with local quantum states are called physical indices. Thus, they can take $d$ values (with $d$ the dimension of the local Hilbert space).

      Any state in the Hilbert space of a one-dimensional many-body system can in principle be represented by a MPS by choosing a sufficiently large value for the bond dimension $D$ [Orus]. On top of this intellectually satisfying property of MPSs being a dense set of states for a 1d-system, they can also be used as a practical Ansätze for a many-body quantum states by setting a maximal allowed value $\chi$ for the bond dimension $D$. In doing so, we restrict ourselves to a corner of the total Hilbert space. The rationale behind this Ansatz is the following: if the initial quantum state of a many-body system has a low bond dimension (typically if the initial state is a product state with $D = 1$), then in a finite time it will only be able to explore a region of the Hilbert space that is not to far away from its starting point. Thus, the bond dimension will not have the time to diverge exponentially [poulin_quantum_2011]. However, depending on the physical system at hand, this sub-manifold of the Hilbert space could still be "too large". There is an additional reason that explains why MPSs are good Ansätze for 1d physical systems. Most many-body Hamiltonians we (physicists) are interested in are local, meaning that the interactions they describe involve objects that are "neighbours". For such Hamiltonians, the ground states (outside of potential critical phases) follow the so called area law for the entanglement entropy [srednicki_entropy_1993][vidal_entanglement_2003][wolf_area_2008]. This law states that the entanglement entropy $S_{vN}$ of a bi-partition of the system is proportional, not to the volume of the partition as one might expect, but to the hyper-surface of the partition's boundary; hence the name "area law". For a 3d system this corresponds to an actual surface area $A$, $S_{vN} \sim A$; for a 2d system it corresponds to the length $L$ of the partition's boundary, $S_{vN} \sim L$; and in 1d the boundary reduces to a point, thus the entropy will be independent of the size of the system $S_{vN} \sim \text{constant}$. The MPSs are states that satisfy this area law.

      An application of the Singular Value Decomposition is to create efficient approximations of quantum states to perform computations. The main idea is to reduce the content of the MPS to keep only the parts that contain the physics of interest. One method to realise this approximation is to do a SVD on each of the tensors of the MPS after each time step of the state time-evolution and to trim the smallest singular values in order to decrease the bond dimension of the MPS down to a chosen maximal value $\chi$. The corresponding columns and rows of the unitary matrices $U$ and $V^\dagger$ are also removed. Then, the trimmed matrices $\tilde{U}$, $\tilde{S}$ and $\tilde{V}^\dagger$ are contracted back to give an approximated tensor $T$ with a smaller bond dimension. Another way to apply the restricted rank approximation is to restrict oneself into working in a manifold of fixed bond dimension $D$ and to use methods that can enforce this constraint.

      MPO

      In order to compute expectation values of observables or apply unitary transformations to a quantum state, we need a TN representation of operators. In the same fashion as a one-dimensional quantum state can be represented as a MPS, operators acting on those states can be represented as Matrix Product Operators (MPO). For an operator $\hat{O}$, its MPO can be defined as follows

      \[ \hat{O} = \sum_{\{i_k\}\{i_k^{'}\} \{w\}} W^{i_1\ i^{'}_1}_{1\ w_0w_1}\ldots W^{i_N\ i^{'}_N}_{N\ w_{N-1}w_N} |\phi_{i_1^{'}}\ldots \phi_{i_N^{'}}\rangle\langle\phi_{i_1}\ldots \phi_{i_N}| \]

      The contracted indices between the tensors are called virtual indices. The free indices are called physical indices and correspond to the different input and output local quantum states. They can take $d$ values (with $d$ the dimension of the local Hilbert space).

      TTN

      A natural extension to the MPS is the (loop-free) tree tensor network. A TTN is a generalisation of the MPS wherein each site, instead of being connected to only one other site to its right, may be connected to any arbitrary number of child sites. Provided the tree does not contain any loops, everything that one can do to an MPS/MPO can be extended straight-forwardly to TTN states and TTN operators. The generalisation to trees introduces no new conceptual complexity (only implementational complexity). The sites of a TTN are usually referred to as nodes. For our purposes, every node of a TTN state and operator has one parent leg, and any number (including zero) of child legs. The first node is known as the head-node and has a dummy parent leg with dimension 1.

      Time-Dependent Variational Principle

      The original idea behind TDVP goes back to Dirac [dirac_note_1930] and Frenkel [frenkel_wave_1934]. The main point, in the modern tensor networks formulation, is that instead of solving the Schrödinger equation and then truncating the MPS representation of the quantum state, one can solve the equations of motion projected into a space of restricted bond dimension [haegeman_timedependent_2011][haegeman_unifying_2016].

      The general formulation of the Dirac-Frenkel Variational Principle [raab_diracfrenkelmclachlan_2000] is that one looks for a solution $|\varphi\rangle \in \mathcal{M}$ of the Schrödinger equation where $\mathcal{M} \subset \mathcal{H}$ is a manifold of the total Hilbert space $\mathcal{H}$ in which we think that the relevant physical states `live'.

      We define $T_{|\varphi\rangle}\mathcal{M}$ the tangent space of $\mathcal{M}$ around the state $|\varphi\rangle$. The criterion to find $|\varphi\rangle$ is that for every state $|\chi\rangle \in T_{|\varphi\rangle}\mathcal{M}$

      \[ \langle\chi|\left(\frac{\mathrm{d}}{\mathrm{d}t} - \frac{1}{\mathrm{i}\hbar}\hat{H}\right)|\varphi\rangle =0\ ,\]

      which can be interpreted as saying that the time evolution procedure should keep $|\varphi\rangle$ inside of the manifold $\mathcal{M}$.

      The term variational in the name of the method comes from the fact that in practice one aims at minimising the right-hand side of the hereinabove Eq. to find $|\varphi\rangle$.

      Introducing $\hat{P}_{T_{|\varphi\rangle}\mathcal{M}}$ the projector onto the tangent space $T_{|\varphi\rangle}\mathcal{M}$, we can write the state $|\chi\rangle = \hat{P}_{T_{|\varphi\rangle}\mathcal{M}}|\phi\rangle$ with $|\phi\rangle$ a state in $\mathcal{H}$. Leading to

      \[ \forall |\phi\rangle \in \mathcal{H}, \ \langle\phi|\hat{P}_{T_{|\varphi\rangle}\mathcal{M}}\left(\frac{\mathrm{d}}{\mathrm{d}t} - \frac{1}{\mathrm{i}\hbar}\hat{H}\right)|\varphi\rangle =0\ .\]

      Because the time derivation and the projector commute, we have

      \[ \forall |\phi\rangle \in \mathcal{H}, \ \langle\phi|\left(\frac{\mathrm{d}}{\mathrm{d}t} - \frac{1}{\mathrm{i}\hbar}\hat{P}_{T_{|\varphi\rangle}\mathcal{M}}\hat{H}\right)|\varphi\rangle =0\ .\]

      This equation must be true for any $|\phi\rangle \in \mathcal{H}$, Eq.~(\ref{eq:DiracFrenkel1}) can thus be written

      \[ \left(\frac{\mathrm{d}}{\mathrm{d}t} - \frac{1}{\mathrm{i}\hbar}\hat{P}_{T_{|\varphi\rangle}\mathcal{M}}\hat{H}\right)|\varphi\rangle =0\ .\]

      In the context of MPS, the manifold $\mathcal{M}$ will correspond to the space of full-ranked MPS of a given bond dimension $D$, and the tangent space will be the space spanned by variations of single MPS tensors. The projector defines an effective Hamiltonian under which the dynamics are constrained on $\mathcal{M}$. Constraining the dynamics on a manifold, introduces a projection error: the time evolution will obey to an effective Hamiltonian different from the starting one. After the introduction of TDVP as a time evolution method for MPS, Haegeman et al. pointed out [haegeman_unifying_2016] that there exist an analytical decomposition for the projector operator $\hat{\mathcal{P}}$ that simplifies the resolution of the equation, turning the problem into one where each matrix $A_i$ can be updated with an effective on site Hamiltonian $\hat H_\text{eff}$ via a Schroedinger like equation. The effective Hamiltonian $\hat H_\text{eff}$ is a contraction of the Hamiltonian MPO and the current state of the other matrices composing the MPS. This allows to do a sequential update.

      There exist different versions of the TDVP algorithm. In MPSDynamics.jl three methods have been so far implemented:

      The main advantage of the one-site 1TDVP algorithm is that it preserves the unitarity of the MPS during the time evolution. Its main problem, conversely, is that the time evolution is constrained to happen on a manifold constituted by tensors of fixed bond dimension, a quantity closely related to the amount of entanglement in the MPS, and such a bond dimension has therefore to be fixed before the beginning of the time evolution. This strategy will necessarily be non optimal: the growth of the bond dimensions required to describe the quantum state should ideally mirror the entanglement growth induced by the time evolution. 2TDVP allows for such a dynamical growth of the bond dimensions, and therefore better describes the entanglement in the MPS. It suffers however of other drawbacks: first of all, a truncation error is introduced (by the means of an SVD decomposition), which entails a loss of unitarity of the time-evolved MPS. Moreover, 2TDVP has bad scaling properties with the size of the local dimensions of the MPS: this is a major issue when dealing with bosons. The DTDVP algorithm combines the best features of 1TDVP and 2TDVP: it preserves unitarity, it has the same scaling properties of 1TDVP, and it adapts the bond dimensions to the entanglement evolution at each site and at each time-step. DTDVP does not suffer from a truncation error, but introduces only a projection error.

      ________________

      Bibliography

      + = \overbrace{\hat A_S}^{\hat H_S} + \overbrace{\sum_k \omega_k \big(\hat a_{1k}^\dagger \hat a_{1k} - \hat a_{2k}^\dagger \hat a_{2k} \big)}^{\hat H_E} + \overbrace{\hat L_S \otimes \sum_k g_{1k}(\hat a_{1k}^\dagger + \hat a_{1k})+\hat L_S \otimes \sum_k g_{2k}(\hat a_{2k}^\dagger + \hat a_{2k})}^{\hat H_I}.\]

      where $\hat L_S = \hat L_S^\dagger$, considering $\hat \rho_S(0) \otimes \ket{\Omega}\bra{\Omega}$ as the initial state of system and environment. It is this Hamiltonian that is mapped on two chains with TEDOPA, to be able to perform the time evolution using tensor network techniques.

      Computation of the chain coefficients

      A useful property of the orthonormal polynomials is that they obey a recurrence relation

      \[ P_n(\omega) = (C_{n-1}\omega - A_{n-1})P_{n-1}(\omega) + B_{n-1}P_{n-2}(\omega)\ ,\]

      where $A_n$ is related to the first moment of $P_n$, $B_n$ and $C_n$ to the norms of $P_n$ and $P_{n-1}$[appel_mathematics_2007]. This recurrence relation can be used to construct the polynomials with the conditions that $P_0(\omega) = ||p_0||^{-1} = \left(\int_{\mathbb{R}^{+}} J(\omega)\mathrm{d}\omega \right)^{-\frac{1}{2}}$ and $P_{-1}(\omega) = 0$, with $||\bullet||$ the norm of $\bullet$ with respect to the measure $J(\omega)$, and $P_n(\omega) = p_n(\omega)||p_n||^{-1}$ ; where the polynomials $\{p_n\}_{n\in\mathbb{N}}$ are the so called monic polynomials where the factor $a_n$ in front of $\omega^{n}$ is equal to 1.

      The energy of the chain mode $n$ is given by $\varepsilon_n = A_n C_n^{-1}$ and $t_n=C_n^{-1}$ is the coupling between mode $n$ and $n+1$[chin_exact_2010].

      The system couples only to the first mode with the coupling strength $c_0 = ||p_0||$.

      Explain that for some weight function/SD they are known analytically and that for others we can use the build-in routines inspired by Gautschi or the PolyChaos.jl package.

      Tensor Networks

      A multipartite quantum state $|\psi\rangle$, e.g. a $N$-site system where the sites can each be in a state $|\phi_i\rangle$ belonging to a $d$-dimensional Hilbert space, can be written as follows

      \[ |\psi\rangle = \sum_{\{i_k\}}c_{i_1\ldots i_N}|\phi_{i_1}\rangle\otimes\ldots\otimes|\phi_{i_N}\rangle\ ,\]

      where the complex numbers $c_{i_1\ldots i_N}$ are the amplitudes of each state $|\phi_{i_1}\rangle\otimes\ldots\otimes|\phi_{i_N}\rangle$ whose superpositions form in full generality the state $|\psi\rangle$. Thus the state $|\psi\rangle$ can be completely represented by a rank-$N$ tensor $c$ that is the collection of all possible amplitudes $c_{i_1\ldots i_N}$. Here by the rank of a tensor, we simply mean the number of indices it has.

      MPS

      The tensor $c$ of a quantum state $|\psi\rangle$ corresponding to a one-dimensional system can be decomposed into a product of $N$ smaller rank-3 tensors $T_{k}$ (except for the first and last sites where the tensors will have a rank-2)

      \[ c_{i_1\ldots i_N} = \sum_{\{\alpha\}} T^{\alpha_1}_{i_1}T^{\alpha_1\alpha_2\ }_{i_2}T^{\alpha_2\alpha_3\ }_{i_3}\ldots T^{\alpha_{N-1}}_{i_N} \ .\]

      In this form, the local tensor $T_k$ contains the information on the quantum state on site $k$ and its relation (especially the entanglement) with the neighbouring sites.

      The decomposition of the tensor of the amplitudes of a quantum state into a product of smaller rank tensors is called a Matrix Product State decomposition.

      The contracted indices $\alpha_k$ between the tensors are called virtual indices and carry information about the correlations between bi-partitions of the state at bond $k$. The number of different values a virtual index can take is called the bond dimension and is denoted $D$. The free indices $i_k$ associated with local quantum states are called physical indices. Thus, they can take $d$ values (with $d$ the dimension of the local Hilbert space).

      Any state in the Hilbert space of a one-dimensional many-body system can in principle be represented by a MPS by choosing a sufficiently large value for the bond dimension $D$ [Orus]. On top of this intellectually satisfying property of MPSs being a dense set of states for a 1d-system, they can also be used as a practical Ansätze for a many-body quantum states by setting a maximal allowed value $\chi$ for the bond dimension $D$. In doing so, we restrict ourselves to a corner of the total Hilbert space. The rationale behind this Ansatz is the following: if the initial quantum state of a many-body system has a low bond dimension (typically if the initial state is a product state with $D = 1$), then in a finite time it will only be able to explore a region of the Hilbert space that is not to far away from its starting point. Thus, the bond dimension will not have the time to diverge exponentially [poulin_quantum_2011]. However, depending on the physical system at hand, this sub-manifold of the Hilbert space could still be "too large". There is an additional reason that explains why MPSs are good Ansätze for 1d physical systems. Most many-body Hamiltonians we (physicists) are interested in are local, meaning that the interactions they describe involve objects that are "neighbours". For such Hamiltonians, the ground states (outside of potential critical phases) follow the so called area law for the entanglement entropy [srednicki_entropy_1993][vidal_entanglement_2003][wolf_area_2008]. This law states that the entanglement entropy $S_{vN}$ of a bi-partition of the system is proportional, not to the volume of the partition as one might expect, but to the hyper-surface of the partition's boundary; hence the name "area law". For a 3d system this corresponds to an actual surface area $A$, $S_{vN} \sim A$; for a 2d system it corresponds to the length $L$ of the partition's boundary, $S_{vN} \sim L$; and in 1d the boundary reduces to a point, thus the entropy will be independent of the size of the system $S_{vN} \sim \text{constant}$. The MPSs are states that satisfy this area law.

      An application of the Singular Value Decomposition is to create efficient approximations of quantum states to perform computations. The main idea is to reduce the content of the MPS to keep only the parts that contain the physics of interest. One method to realise this approximation is to do a SVD on each of the tensors of the MPS after each time step of the state time-evolution and to trim the smallest singular values in order to decrease the bond dimension of the MPS down to a chosen maximal value $\chi$. The corresponding columns and rows of the unitary matrices $U$ and $V^\dagger$ are also removed. Then, the trimmed matrices $\tilde{U}$, $\tilde{S}$ and $\tilde{V}^\dagger$ are contracted back to give an approximated tensor $T$ with a smaller bond dimension. Another way to apply the restricted rank approximation is to restrict oneself into working in a manifold of fixed bond dimension $D$ and to use methods that can enforce this constraint.

      MPO

      In order to compute expectation values of observables or apply unitary transformations to a quantum state, we need a TN representation of operators. In the same fashion as a one-dimensional quantum state can be represented as a MPS, operators acting on those states can be represented as Matrix Product Operators (MPO). For an operator $\hat{O}$, its MPO can be defined as follows

      \[ \hat{O} = \sum_{\{i_k\}\{i_k^{'}\} \{w\}} W^{i_1\ i^{'}_1}_{1\ w_0w_1}\ldots W^{i_N\ i^{'}_N}_{N\ w_{N-1}w_N} |\phi_{i_1^{'}}\ldots \phi_{i_N^{'}}\rangle\langle\phi_{i_1}\ldots \phi_{i_N}| \]

      The contracted indices between the tensors are called virtual indices. The free indices are called physical indices and correspond to the different input and output local quantum states. They can take $d$ values (with $d$ the dimension of the local Hilbert space).

      TTN

      A natural extension to the MPS is the (loop-free) tree tensor network. A TTN is a generalisation of the MPS wherein each site, instead of being connected to only one other site to its right, may be connected to any arbitrary number of child sites. Provided the tree does not contain any loops, everything that one can do to an MPS/MPO can be extended straight-forwardly to TTN states and TTN operators. The generalisation to trees introduces no new conceptual complexity (only implementational complexity). The sites of a TTN are usually referred to as nodes. For our purposes, every node of a TTN state and operator has one parent leg, and any number (including zero) of child legs. The first node is known as the head-node and has a dummy parent leg with dimension 1.

      Time-Dependent Variational Principle

      The original idea behind TDVP goes back to Dirac [dirac_note_1930] and Frenkel [frenkel_wave_1934]. The main point, in the modern tensor networks formulation, is that instead of solving the Schrödinger equation and then truncating the MPS representation of the quantum state, one can solve the equations of motion projected into a space of restricted bond dimension [haegeman_timedependent_2011][haegeman_unifying_2016].

      The general formulation of the Dirac-Frenkel Variational Principle [raab_diracfrenkelmclachlan_2000] is that one looks for a solution $|\varphi\rangle \in \mathcal{M}$ of the Schrödinger equation where $\mathcal{M} \subset \mathcal{H}$ is a manifold of the total Hilbert space $\mathcal{H}$ in which we think that the relevant physical states `live'.

      We define $T_{|\varphi\rangle}\mathcal{M}$ the tangent space of $\mathcal{M}$ around the state $|\varphi\rangle$. The criterion to find $|\varphi\rangle$ is that for every state $|\chi\rangle \in T_{|\varphi\rangle}\mathcal{M}$

      \[ \langle\chi|\left(\frac{\mathrm{d}}{\mathrm{d}t} - \frac{1}{\mathrm{i}\hbar}\hat{H}\right)|\varphi\rangle =0\ ,\]

      which can be interpreted as saying that the time evolution procedure should keep $|\varphi\rangle$ inside of the manifold $\mathcal{M}$.

      The term variational in the name of the method comes from the fact that in practice one aims at minimising the right-hand side of the hereinabove Eq. to find $|\varphi\rangle$.

      Introducing $\hat{P}_{T_{|\varphi\rangle}\mathcal{M}}$ the projector onto the tangent space $T_{|\varphi\rangle}\mathcal{M}$, we can write the state $|\chi\rangle = \hat{P}_{T_{|\varphi\rangle}\mathcal{M}}|\phi\rangle$ with $|\phi\rangle$ a state in $\mathcal{H}$. Leading to

      \[ \forall |\phi\rangle \in \mathcal{H}, \ \langle\phi|\hat{P}_{T_{|\varphi\rangle}\mathcal{M}}\left(\frac{\mathrm{d}}{\mathrm{d}t} - \frac{1}{\mathrm{i}\hbar}\hat{H}\right)|\varphi\rangle =0\ .\]

      Because the time derivation and the projector commute, we have

      \[ \forall |\phi\rangle \in \mathcal{H}, \ \langle\phi|\left(\frac{\mathrm{d}}{\mathrm{d}t} - \frac{1}{\mathrm{i}\hbar}\hat{P}_{T_{|\varphi\rangle}\mathcal{M}}\hat{H}\right)|\varphi\rangle =0\ .\]

      This equation must be true for any $|\phi\rangle \in \mathcal{H}$, Eq.~(\ref{eq:DiracFrenkel1}) can thus be written

      \[ \left(\frac{\mathrm{d}}{\mathrm{d}t} - \frac{1}{\mathrm{i}\hbar}\hat{P}_{T_{|\varphi\rangle}\mathcal{M}}\hat{H}\right)|\varphi\rangle =0\ .\]

      In the context of MPS, the manifold $\mathcal{M}$ will correspond to the space of full-ranked MPS of a given bond dimension $D$, and the tangent space will be the space spanned by variations of single MPS tensors. The projector defines an effective Hamiltonian under which the dynamics are constrained on $\mathcal{M}$. Constraining the dynamics on a manifold, introduces a projection error: the time evolution will obey to an effective Hamiltonian different from the starting one. After the introduction of TDVP as a time evolution method for MPS, Haegeman et al. pointed out [haegeman_unifying_2016] that there exist an analytical decomposition for the projector operator $\hat{\mathcal{P}}$ that simplifies the resolution of the equation, turning the problem into one where each matrix $A_i$ can be updated with an effective on site Hamiltonian $\hat H_\text{eff}$ via a Schroedinger like equation. The effective Hamiltonian $\hat H_\text{eff}$ is a contraction of the Hamiltonian MPO and the current state of the other matrices composing the MPS. This allows to do a sequential update.

      There exist different versions of the TDVP algorithm. In MPSDynamics.jl three methods have been so far implemented:

      The main advantage of the one-site 1TDVP algorithm is that it preserves the unitarity of the MPS during the time evolution. Its main problem, conversely, is that the time evolution is constrained to happen on a manifold constituted by tensors of fixed bond dimension, a quantity closely related to the amount of entanglement in the MPS, and such a bond dimension has therefore to be fixed before the beginning of the time evolution. This strategy will necessarily be non optimal: the growth of the bond dimensions required to describe the quantum state should ideally mirror the entanglement growth induced by the time evolution. 2TDVP allows for such a dynamical growth of the bond dimensions, and therefore better describes the entanglement in the MPS. It suffers however of other drawbacks: first of all, a truncation error is introduced (by the means of an SVD decomposition), which entails a loss of unitarity of the time-evolved MPS. Moreover, 2TDVP has bad scaling properties with the size of the local dimensions of the MPS: this is a major issue when dealing with bosons. The DTDVP algorithm combines the best features of 1TDVP and 2TDVP: it preserves unitarity, it has the same scaling properties of 1TDVP, and it adapts the bond dimensions to the entanglement evolution at each site and at each time-step. DTDVP does not suffer from a truncation error, but introduces only a projection error.

      ________________

      Bibliography

      diff --git a/docs/user-guide/index.html b/docs/user-guide/index.html index 96dfd07..4c530c3 100644 --- a/docs/user-guide/index.html +++ b/docs/user-guide/index.html @@ -34,4 +34,4 @@ "nchain" => [0.0 0.23466 … 1.84319 1.76098; 0.0 0.00231507 … 0.83105 0.9033… "sy" => [0.0, -0.0133489, -0.0588887, -0.0858181, -0.0759996, -0.048539… "times" => [0.0, 0.0005, 0.001, 0.0015, 0.002, 0.0025, 0.003, 0.0035, 0.00… -
      +