network_contractor

  • full name: tenpy.algorithms.network_contractor

  • parent module: tenpy.algorithms

  • type: module

Functions

contract(tensor_list[, tensor_names, …])

Contract a network of tensors.

ncon(tensor_list, leg_links, sequence)

Implementation of ncon.m for TeNPy Arrays.

Module description

Network Contractor.

A tool to contract a network of multiple tensors.

This is an implementation of ‘NCON: A tensor network contractor for MATLAB’ by Robert N. C. Pfeifer, Glen Evenbly, Sukhwinder Singh, Guifre Vidal, see arXiv:1402.0939

tenpy.algorithms.network_contractor.outer_product = -66666666

a constant that represents an outer product in the sequence of ncon

Todo

  • implement or wrap netcon.m, a function to find optimal contractionn sequences

    (arXiv:1304.6112)

  • improve helpfulness of Warnings

  • _do_trace: trace over all pairs of legs at once. need the corresponding npc function first.