quimb.tensor.tn2dinf.tebd¶
Local Hamiltonians and imaginary-time simple update for infinite,
translation-invariant 2D tensor networks (tn2dinf).
Classes¶
A local Hamiltonian on an infinite 2D lattice, defined per |
|
Imaginary-time simple update for an infinite 2D PEPS. |
Module Contents¶
- class quimb.tensor.tn2dinf.tebd.LocalHamInfinite2D(geometry_or_edges, H2, H1=None)[source]¶
Bases:
quimb.tensor.tnag.tebd.LocalHamGenA local Hamiltonian on an infinite 2D lattice, defined per
bond_typeandsite_type(translation classes) rather than per concrete bond/site. Single-site terms are absorbed evenly into the covering two-site terms and operations on the terms (matrix exponential, etc.) are cached.The Hamiltonian carries its own
GeometryInfinite2Dwhich may differ from a wavefunction’s geometry as long as thesite_typesmatch (e.g. a longer-range Hamiltonian on a nearest-neighbor PEPS).- Parameters:
geometry_or_edges (GeometryInfinite2D or sequence of edges) – The Hamiltonian’s geometry (or edges to build one from).
H2 (array_like or dict[bond_type, array_like]) – The two-site interaction terms. A single array is used as the default term for every
bond_type. A dict gives per-bond_typeterms, withNoneas an optional default. Keys may be given in either orientation (canonicalized viageometry.get_bond_type, flipping the operator if needed).H1 (array_like or dict[site_type, array_like], optional) – The one-site term(s), absorbed evenly into the covering two-site terms. A single array is the default for every
site_type. A dict gives per-site_typeterms, withNoneas an optional default.
- geometry¶
The Hamiltonian’s geometry.
- Type:
- _op_cache¶
- terms¶
- _site_type_to_covering¶
- property site_types¶
The unique site_types in the unit cell.
- property bond_types¶
The unique bond_types in the unit cell.
- property nsites¶
The number of site_types in the unit cell.
- class quimb.tensor.tn2dinf.tebd.SimpleUpdateInfinite2D(psi0, ham, *args, compute_energy_per_site=True, **kwargs)[source]¶
Bases:
quimb.tensor.tnag.tebd.SimpleUpdateGenImaginary-time simple update for an infinite 2D PEPS.
Drives a
PEPSInfinite2Dstate under aLocalHamInfinite2D, reusing quimb’sSimpleUpdateGenfor all loop logic (tau schedule, gate ordering, periodic gauge equilibration, energy history and convergence). The state provides the simple-update surface the driver calls into (gate_simple_,gauge_all_simple_,normalize_simple,gauge_simple_insert,compute_local_expectation_cluster), keyed by translation class so updates are shared across the lattice.Parameters mirror
quimb.tensor.tnag.tebd.SimpleUpdateGen, e.g.:su = SimpleUpdateInfinite2D(psi, ham, D=4) su.evolve(100, tau=0.3) su.evolve(100, tau=0.1) psi_final, gauges = su.get_state(absorb_gauges="return")
Notes
The loop energy is the
max_distance=0cluster estimate;PEPSInfinite2Dalso offers larger clusters (more accurate) and generalized-loop expansions (cheaper than the equivalent-size cluster, but less accurate) for measuring the final state.Only
update="sequential"is reliable: the inherited sweep groups gates into layers by literal site, whereas the translation-invariant conflict rule is bysite_type, soupdate="parallel"(and per-layer equilibration) are not supported yet.
- compute_local_expectation_cluster(terms=None, **kwargs)[source]¶
Cluster expectation of
termson the current state, inserting the driver’s current gauges as the environment.termsdefaults to the Hamiltonian andgaugestoself.gauges, so a baresu.compute_local_expectation_cluster()measures the energy per unit cell. Forwards toPEPSInfinite2D.compute_local_expectation_cluster(), somax_distance,return_all, etc. pass straight through.Returns the summed (per unit cell) value, not per-site; divide by
self.ham.nsitesto compare withenergy.For a meaningful estimate the gauges should be equilibrated with the current tensors, with no pending imaginary-time gate, e.g. straight after
evolve()or viaequilibrate().
- compute_local_expectation_gloop_expand(terms=None, gloops=None, **kwargs)[source]¶
Generalized-loop-expansion expectation of
termson the current state, inserting the driver’s current gauges.termsdefaults to the Hamiltonian andgaugestoself.gauges. Forwards toPEPSInfinite2D.compute_local_expectation_gloop_expand().See
compute_local_expectation_cluster()for the per-cell return convention and the equilibration note.