Skip to content

Commit

Permalink
Merge pull request #12 from shareloqs/angelariva-patch-1
Browse files Browse the repository at this point in the history
Update convergence.md
  • Loading branch information
tfmlaX authored Nov 25, 2024
2 parents 4f41325 + 1e89842 commit 74f322f
Showing 1 changed file with 24 additions and 4 deletions.
28 changes: 24 additions & 4 deletions docs/src/convergence.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,22 @@

In this section, we analyze the numerical accuracy of our simulations by outlining the necessary approximations and providing practical guidelines to ensure convergence of results.

## Approximations

### Chain length $N$
During a numerical simulation, a truncation on the number of chain modes (and therefore chain length) will be introduced, in order to work with a chain of finite length instead of a semi-infinite one. This truncation on chain modes, let us say $N$, corresponds to a sampling on the modes in the original environment.
In numerical simulations, a truncation on the number of chain modes (and therefore the chain length) is introduced to handle a finite chain instead of a semi-infinite one. This truncation, denoted as NN, corresponds to a sampling of the modes in the original environment.

The chain length $N$ is directly connected to the simulation time as follows: excitations injected into the chain propagate as a wavefront traveling along the chain. Perturbations to the initial state outside this wavefront are exponentially suppressed. Therefore, truncating the chain basis beyond the expanding wavefront ensures that the resulting sampling error is also exponentially small [^woods_simulating_2015][^DeVega_howto_2015].

The length chain is connected to the simulation time in the following way: excitations injected from the system form a wave-front that travels along the chain. Any perturbation to the initial state outside of this wave-front are exponentially suppressed. It is thus natural to truncate in the chain basis, making sure that this truncation happens **beyond** the expanding wave-front, as in this way the sampling error is also exponentially small [^woods_simulating_2015][^DeVega_howto_2015].
To optimize the chain length for a given simulation time and set of chain coefficients, the following procedure can be used:

To make sure that, for a given simulation time, and for a given set of chain coefficients, the chain-length is the optimal one, we can do as follows. We set the total simulation time, and we compute the chain coefficients for a non-optimal chain, much longer than needed.
1. Set the total simulation time and compute the chain coefficients for an intentionally oversized chain (longer than needed):
```
T = 100
N_huge = 1000
cpars = chaincoeffs_flat(N_huge, αchain; ωc = 1.0)
```
We can then use the built-in function `findchainlength`, that computes the required chain length `N_opt` from the propagation speed on the chain sites (given by the hopping coefficients $t_n$):
2. Use the built-in function `findchainlength` to determine the optimal chain length $N_opt$ based on the propagation speed of the wavefront (given by the hopping coefficients $t_n$):
```
N_opt = findchainlength(T, cpars; eps=10^-4, verbose=false)
```
Expand All @@ -22,6 +26,22 @@ N_opt = findchainlength(T, cpars; eps=10^-4, verbose=false)
Another critical truncation is imposed on the local dimension $d$ of each tensor in the MPS that undergoes dynamic evolution. The local dimension $d$ corresponds to the number of Fock states retained in the Hilbert space of each chain mode. Since harmonic oscillators are, in principle, infinite-dimensional systems, truncating their Hilbert space to a finite $d$ is necessary for numerical computations. The choice of $d$ determines the maximum number of excitations per site in the MPS and must be carefully tuned to capture the relevant physics while ensuring numerical convergence.
For a bath that initially contains only a finite number of particles, i.e. any bath in practice, the error originating from the local Hilbert space truncation vanishes exponentially as $d$ increases[^woods_simulating_2015].

A practical guideline for choosing $d$ can be derived by considering the physical states being simulated. For example, for coherent states, the occupation number follows a Poisson distribution. In such cases, the average occupation number is given by the mean $\langle n \rangle$, and the probability of observing a state with occupation number $n$ decreases exponentially for $n \gg \langle n \rangle$. Thus, the truncation $d$ should be chosen such that the cumulative probability of truncation error is negligible.

### Time-step error
Different time-evolution algorithms are implemented in MPSDynamics, and can be selected as options in the function `runsim`. Detailed descriptions of these algorithms are provided in the *Theoretical Background* section of the documentation. The key parameter for ensuring convergence in these methods is controlled via the `convparams` option, which accepts arrays of multiple parameter values to test until convergence is achieved.

Below are the main time-evolution algorithms and their corresponding convergence parameters:
- One-Site Time-Dependent Variational Principle (1TDVP):
- Selected using: `method = :1TDVP`.
- The convergence parameter is the bond dimension of the MPS, which defines the manifold on which the time evolution is constrained. To ensure convergence, multiple bond dimensions can be tested: `convparams = [bond1, bond2, bond3]`.
- Two-Sites Time-Dependent Variational Principle (2TDVP):
- Selected using: `method = :2TDVP`.
- The convergence parameter is the SVD singular value truncation threshold, which determines the precision of the truncation during simulations. Multiple truncation thresholds can be tested: `convparams = [trunc1, trunc2, trunc3]`
- Adaptive Time-Dependent Variational Principle (DTDVP):
- Selected using: `method = :DTDVP`.
- The convergence parameter is the target precision for the adaptive algorithm. Multiple precision values can be provided to test convergence: `convparams = [prec1, prec2, prec3]`
=======
###


Expand Down

0 comments on commit 74f322f

Please sign in to comment.