MPSGeometry
full name: tenpy.networks.mps.MPSGeometry
parent module:
tenpy.networks.mpstype: class
Inheritance Diagram

Methods
|
|
Get the i-th site. |
|
|
Shift an Array by an integer multiple of unit cells. |
|
Shift a site by an integer multiple of unit cells. |
Shift charges by an integer multiple of unit cells. |
|
|
Class Attributes and Properties
Number of physical sites; for an iMPS the len of the MPS unit cell. |
|
Number of sites per horizontal lattice spacing. |
|
List of local physical dimensions. |
|
Distinguish MPS vs iMPS. |
|
Slice of the non-trivial bond indices, depending on |
- class tenpy.networks.mps.MPSGeometry(sites, bc, unit_cell_width=None)[source]
Bases:
objectBase class providing methods regarding the 1D geometry of MPS-like tensornetworks.
- Parameters:
sites (list of
Site) – Defines the local Hilbert space for each site.bc (
'finite' | 'segment' | 'infinite') – Boundary conditions as described in the table of the module doc-string.unit_cell_width (int) – See
mps_unit_cell_width.
- chinfo
The nature of the charge.
- Type:
ChargeInfo
- sites
Defines the local Hilbert space for each site.
- Type:
list of
Site
- bc
Boundary conditions as described in the table of the module doc-string.
- Type:
'finite' | 'segment' | 'infinite'
- unit_cell_width
The width (i.e. length along the first dimension) of an MPS unit cell, in units of the lattice spacing. It is given by
mps_unit_cell_width. For aChain, this is just the length of the chain. Is used for Dipole Conservation orMPS.correlation_length2().- Type:
- property L
Number of physical sites; for an iMPS the len of the MPS unit cell.
- property dim
List of local physical dimensions.
- property finite
Distinguish MPS vs iMPS.
True for an MPS (
bc='finite', 'segment'), False for an iMPS (bc='infinite').
- property nontrivial_bonds
Slice of the non-trivial bond indices, depending on
self.bc.
- property N_sites_per_hor_spacing
Number of sites per horizontal lattice spacing.
This is the number of MPS sites one has to traverse to travel one lattice spacing in the first dimension, such that
self.unit_cell_width * N_sites_per_hor_spacing == self.L.
- shift_charges_unit_cells(charges, num_unit_cells)[source]
Shift charges by an integer multiple of unit cells.
See the notes on Dipole Conservation.
A unit cell has length
Land a shift by one unit cell is purely horizontal and shifts byunit_cell_widthlattice spacings.Essentially, this is a convenience wrapper around \(tenpy.linalg.charges.ChargeInfo.shift_charges_horizontal\).
- Parameters:
charges (2D ndarray of dtype QTYPE) – The charges to shift.
num_unit_cells (int) – The number of unit cells.
- Returns:
The shifted charges.
- Return type:
2D ndarray of dtype QTYPE
- shift_Site_unit_cells(site, num_unit_cells)[source]
Shift a site by an integer multiple of unit cells.
See the notes on Dipole Conservation.
A unit cell has length
Land a shift by one unit cell is purely horizontal and shifts byunit_cell_widthlattice spacings.
- shift_Array_unit_cells(arr, num_unit_cells, inplace: bool = False)[source]
Shift an Array by an integer multiple of unit cells.
See the notes on Dipole Conservation.
A unit cell has length
Land a shift by one unit cell is purely horizontal and shifts byunit_cell_widthlattice spacings.