Wolfram Language Paclet Repository

Community-contributed installable additions to the Wolfram Language

Primary Navigation

    • Cloud & Deployment
    • Core Language & Structure
    • Data Manipulation & Analysis
    • Engineering Data & Computation
    • External Interfaces & Connections
    • Financial Data & Computation
    • Geographic Data & Computation
    • Geometry
    • Graphs & Networks
    • Higher Mathematical Computation
    • Images
    • Knowledge Representation & Natural Language
    • Machine Learning
    • Notebook Documents & Presentation
    • Scientific and Medical Data & Computation
    • Social, Cultural & Linguistic Data
    • Strings & Text
    • Symbolic & Numeric Computation
    • System Operation & Setup
    • Time-Related Computation
    • User Interface Construction
    • Visualization & Graphics
    • Random Paclet
    • Alphabetical List
  • Using Paclets
    • Get Started
    • Download Definition Notebook
  • Learn More about Wolfram Language

TensorNetworks

Tutorials

  • Index conventions and contraction path

Guides

  • TensorNetworks

Tech Notes

  • Building Tensor Networks
  • Contraction Paths and Execution
  • Named Indices and Metrics
  • Matrix Product States
  • A Working Tour of the Symmetry Functions
  • Tensor Networks Overview
  • Young Tableaux and Tensor Symmetries

Symbols

  • ActivateTensors
  • ArraySymmetry
  • BinaryTensorNetwork
  • BinaryTensorNetworkQ
  • CanonicalPath
  • CanonicalPathQ
  • ContractIndices
  • ContractionTree
  • Dimension
  • DimensionQ
  • EinsteinSummation
  • GreedyContractionPath
  • HookFactor
  • HookLength
  • HookLengths
  • IndexArray
  • IndexArrayQ
  • IndexContract
  • IndexedMultiply
  • IndexJuggling
  • IndexPart
  • IndexTensor
  • IndexTensorQ
  • InitializeTensorNetwork
  • MetricTensor
  • MetricTensorQ
  • MPSCanonicalForm
  • MPSCanonicalQ
  • MPSEntanglementEntropy
  • MPSNormalize
  • MPSNorm
  • MPSOverlap
  • MPSSchmidtValues
  • MPSTruncate
  • OptimalContractionPath
  • PartitionQ
  • PathIndexContractions
  • PathQ
  • PathToTreePath
  • RandomTensorNetwork
  • SchurDimension
  • Shape
  • ShapeQ
  • SparseTensorNetwork
  • TableauColumns
  • TableauDimension
  • TableauRows
  • TableauShape
  • TableauSize
  • TableauWeylDimension
  • TensorNetworkAdd
  • TensorNetworkContraction
  • TensorNetworkContractions
  • TensorNetworkContract
  • TensorNetworkData
  • TensorNetworkDelete
  • TensorNetworkFindContractionPath
  • TensorNetworkFreeIndices
  • TensorNetworkGraphData
  • TensorNetworkGraphQ
  • TensorNetworkIndexDimensions
  • TensorNetworkIndexGraph
  • TensorNetworkIndices
  • TensorNetwork
  • TensorNetworkQ
  • TensorNetworkRemoveCycles
  • TensorNetworkReplaceIndices
  • TensorNetworkSize
  • TensorNetworkTensors
  • TensorNetworkToNetGraph
  • ToTensorNetworkGraph
  • TransposePartition
  • TreePathQ
  • TreePathToPath
  • YoungProject
  • YoungSymmetrize
  • YoungTableau
  • YoungTableauQ
  • $TensorNetworkContractionMethods
Wolfram`TensorNetworks`
TensorNetworkFindContractionPath
​
TensorNetworkFindContractionPath
[tn]
is deprecated; forwards to OptimalContractionPath. •
​
​
TensorNetworkFindContractionPath
[tn,
Method
m]
selects the path-finder by Method m. •
​
​
TensorNetworkFindContractionPath
[tn,"ReturnParameters"True]
returns the internal parameter-extraction result instead of a path.
​
Details and Options
▪
TensorNetworkFindContractionPath
is deprecated. New code should call
OptimalContractionPath
or
GreedyContractionPath
directly.
▪
The function issues
General::deprec
on every call. The tag is the system-wide
General::deprec
, not a symbol-specific message, so
Off
[General::deprec]
suppresses it.
▪
The default
Method
"Optimal"
forwards to
OptimalContractionPath
[tn,
Method
"size"]
, matching OptimalContractionPath's own documented default.
▪
Method values "flops", "max", "size", "write", "combo", and "limit" forward to
OptimalContractionPath
with that Method. Any other value, including "Greedy", forwards to
GreedyContractionPath
.
▪
With "ReturnParameters" -> True the function returns the result of an internal parameter-extraction helper instead of a path. This option is intended for inspecting what the path-finder receives and is not part of the supported public API.
▪
The following options can be given:
"ReturnParameters"
False
return the internal parameter-extraction result instead of a path
Method
"Optimal"
path-finding backend; "Optimal", "flops", "max", "size", "write", "combo", or "limit" forwards to OptimalContractionPath; any other value forwards to GreedyContractionPath
​
Examples  
(11)
Basic Examples  
(1)
Find an optimized contraction path for a tensor network. TensorNetworkFindContractionPath is deprecated; its call issues General::deprec and forwards to OptimalContractionPath or GreedyContractionPath:
In[1]:=
Holdtn=
RandomTensorNetwork
["MPS"[10,5,4]]/.Hold[x_]x
In[2]:=
TensorNetworkFindContractionPath
[tn]
Out[2]=
{{1,2},{7,8},{6,8},{5,7},{4,6},{3,5},{2,4},{1,3},{1,2}}
Use greedy optimization:
In[3]:=
TensorNetworkFindContractionPath
[tn,Method"Greedy"]
Out[3]=
{{1,2},{1,9},{1,2},{6,7},{4,5},{3,5},{1,2},{2,3},{1,2}}
Find the optimal path (the default):
In[4]:=
TensorNetworkFindContractionPath
[tn,Method"Optimal"]
Out[4]=
{{1,2},{7,8},{6,8},{5,7},{4,6},{3,5},{2,4},{1,3},{1,2}}
Scope  
(4)

Options  
(2)

Applications  
(2)

Properties & Relations  
(2)

SeeAlso
OptimalContractionPath
 
▪
GreedyContractionPath
 
▪
TensorNetworkContract
 
▪
TensorNetworkContraction
TechNotes
▪
Contraction Paths and Execution
RelatedGuides
▪
Tensor Networks
""

© 2026 Wolfram. All rights reserved.

  • Legal & Privacy Policy
  • Contact Us
  • WolframAlpha.com
  • WolframCloud.com