Skip to content

Latest commit

 

History

History
72 lines (68 loc) · 5.4 KB

v0.5.0.rst

File metadata and controls

72 lines (68 loc) · 5.4 KB

[0.5.0] - 2019-12-18

Backwards incompatible changes

  • Major rewriting of the DMRG Engines, see 39 and 85 for details. The ~tenpy.algorithms.dmrg.EngineCombine and ~tenpy.algorithms.dmrg.EngineFracture have been combined into a single ~tenpy.algorithms.dmrg.TwoSiteDMRGEngine with an The ~tenpy.algorithms.dmrg.run function works as before. In case you have directly used the ~tenpy.algorithms.dmrg.EngineCombine or ~tenpy.algorithms.dmrg.EngineFracture, you should update your code and use the ~tenpy.algorithms.dmrg.TwoSiteEngine instead.
  • Moved init_LP and init_RP method from ~tenpy.networks.mps.MPS into ~tenpy.networks.mps.MPSEnvironment and ~tenpy.networks.mpo.MPOEnvironment.

Changed

  • Addition/subtraction of ~tenpy.linalg.np_conserved.Array: check whether the both arrays have the same labels in differnt order, and in that case raise a warning that we will transpose in the future.
  • Made tenpy.linalg.np_conserved.Array.get_block public (previously tenpy.linalg.np_conserved.Array._get_block).
  • ~tenpy.algorithms.exact_diag.ExactDiag.groundstate now returns a tuple (E0, psi0) instead of just psi0. Moreover, the argument charge_sector was added.
  • Simplification in the ~tenpy.models.lattice.Lattice: Instead of having separate arguments/attributes/functions for 'nearest_neighbors', 'next_nearest_neighbors', 'next_next_nearest_neighbors' and possibly (Honeycomb) even 'fourth_nearest_neighbors', 'fifth_nearest_neighbors', collect them in a dictionary called pairs. Old call structures still allowed, but deprecated.
  • 94: Array addition and ~tenpy.linalg.np_conserved.inner should reflect the order of the labels, if they coincided. Will change the default behaviour in the future, raising FutureWarning for now.
  • Default parameter for DMRG params: increased precision by setting P_tol_min down to the maximum of 1.e-30, lanczos_params['svd_min']**2 * P_tol_to_trunc, lanczos_params['trunc_cut']**2 * P_tol_to_trunc by default.

Added

  • tenpy.algorithms.mps_common with the ~tenpy.algorithms.mps_common.Sweep class and ~tenpy.algorithms.mps_common.EffectiveH to be a ~tenpy.algorithms.mps_common.OneSiteH or ~tenpy.algorithms.mps_common.TwoSiteH.
  • Single-Site DMRG with the ~tenpy.algorithms.dmrg.SingleSiteDMRG.
  • Example function in examples/c_tebd.py how to run TEBD with a model originally having next-nearest neighbors.
  • ~tenpy.networks.mps.MPS.increase_L to allow increasing the unit cell of an MPS.
  • Additional option order='folded' for the ~tenpy.models.lattice.Chain.
  • tenpy.algorithms.exact_diag.ExactDiag.from_H_mpo wrapper as replacement for tenpy.networks.mpo.MPO.get_full_hamiltonian and tenpy.networks.mpo.MPO.get_grouped_mpo. The latter are now deprecated.
  • Argument max_size to limit the matrix dimension in ~tenpy.algorithms.exact_diag.ExactDiag.
  • tenpy.linalg.sparse.FlatLinearOperator.from_guess_with_pipe to allow quickly converting matvec functions acting on multi-dimensional arrays to a FlatLinearOperator by combining the legs into a LegPipe.
  • tenpy.tools.math.speigsh for hermitian variant of ~tenpy.tools.math.speigs
  • Allow for arguments 'LA', 'SA' in ~tenpy.tools.misc.argsort.
  • tenpy.linalg.lanczos.lanczos_arpack as possiple replacement of the self-implemented lanczos function.
  • tenpy.algorithms.dmrg.full_diag_effH as another replacement of ~tenpy.linalg.lanczos.lanczos.
  • The new DMRG parameter 'diag_method' allows to select a method for the diagonalization of the effective Hamiltonian. See tenpy.algorithms.dmrg.DMRGEngine.diag for details.
  • dtype attribute in ~tenpy.algorithms.mps_common.EffectiveH.
  • tenpy.linalg.charges.LegCharge.get_qindex_of_charges to allow selecting a block of an Array from the charges.
  • tenpy.algorithms.mps_common.EffectiveH.to_matrix to allow contracting an EffectiveH to a matrix, as well as metadata tenpy.linalg.sparse.NpcLinearOperator.acts_on and tenpy.algorithms.mps_common.EffectiveH.N.
  • argument only_physical_legs in tenpy.networks.mps.MPS.get_total_charge

Fixed

  • MPO ~tenpy.networks.mpo.MPO.expectation_value did not work for finite systems.
  • Calling ~tenpy.networks.mps.MPS.compute_K repeatedly with default parameters but on states with different chi would use the chi of the very first call for the truncation parameters.
  • allow ~tenpy.network.mps.MPSEnvironment and ~tenpy.network.mpo.MPOEnvironment to have MPS/MPO with different length
  • ~tenpy.models.model.NearestNeighborModel.group_sites didn't work correctly in some situations.
  • ~tenpy.tools.math.matvec_to_array returned the transposed of A.
  • tenpy.networks.mps.MPS.from_full messed up the form of the first array.
  • 95: blowup of errors in DMRG with update_env > 0. Turns out to be a problem in the precision of the truncation error: TruncationError.eps was set to 0 if it would be smaller than machine precision. To fix it, I added ~tenpy.algorithms.truncation.TruncationError.from_S.