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

Hypergraph

Guides

  • Hypergraph Functionality

Tech Notes

  • Hypergraph Rewriting

Symbols

  • AdjacencyHypergraph
  • AdjacencyTensor
  • CanonicalHypergraph
  • CanonicalHypergraphRule
  • ConnectedHypergraphQ
  • CyclicEdge
  • EdgeListTagged
  • EdgeMultiplicity
  • EdgeSymmetry
  • EnumerateHypergraphRules
  • EnumerateHypergraphs
  • EnumerateOrderedHypergraphs
  • EnumerateWolframModelRules
  • HighlightRule
  • HyperedgeList
  • Hyperedge
  • Hyperedges
  • HyperedgesQ
  • Hypergraph3D
  • HypergraphArityReduce
  • HypergraphDraw
  • HypergraphEmbedding
  • HypergraphHadamardProduct
  • HypergraphIncidenceMatrix
  • HypergraphIncidence
  • HypergraphInsertionBracketDegree
  • HypergraphInsertionBracket
  • HypergraphInsertion
  • HypergraphLargeQ
  • Hypergraph
  • HypergraphQ
  • HypergraphRuleDraw
  • HypergraphRule
  • HypergraphRuleQ
  • HypergraphToGraph
  • HypergraphTransitionMatrix
  • HypergraphUnion
  • HypermatrixGraph
  • Hypermatrix
  • HypermatrixQ
  • IncidenceHypergraph
  • IsomorphicHypergraphQ
  • KoszulSign
  • LinkedHypergraph
  • OrderedHypergraphToGraph
  • RandomAllHypergraph
  • RandomConnectedHypergraph
  • RandomHypergraph
  • RandomHypergraphRule
  • SetHypergraphSummaryThresholds
  • SimpleHypergraph
  • SimpleHypergraphPlot3D
  • SimpleHypergraphPlot
  • SimpleHypergraphQ
  • ToLabeledEdges
  • ToLabeledPatternEdges
  • ToOrderedHypergraph
  • ToPatternRules
WolframInstitute`Hypergraph`
CanonicalHypergraph
​
CanonicalHypergraph
[hg]
gives a canonical form of the hypergraph hg, with vertices relabeled by consecutive integers.
​
​
CanonicalHypergraph
[args]
gives the canonical form of
Hypergraph
[args]
.
​
Details and Options
▪
The canonical form is a
Hypergraph
whose vertices are the consecutive integers 1, 2, …, with hyperedges rewritten accordingly and sorted into a canonical order.
▪
Isomorphic hypergraphs, in the sense of
IsomorphicHypergraphQ
, have identical canonical forms.
▪
The edge symmetry of hg is preserved in the canonical form; by default, all other annotations and styling options are dropped.
▪
The following options can be given:
option
default
effect
Method
Automatic
the method used to find the canonical vertex relabeling
"Annotations"
False
whether to transfer vertex and edge annotations to the canonical form
▪
Possible settings for
Method
include:
▪
|
Automatic
| canonicalize a graph encoding of the hypergraph with
CanonicalGraph
| |
"Graph"
| same as
Automatic
| |
"MultiGraph"
| reduce repeated edges of the graph encoding before canonicalizing | |
"Combinatorial"
| exhaustive combinatorial search |
▪
The
Automatic
method falls back to the combinatorial search when
CanonicalGraph
cannot handle the graph encoding; the
"Combinatorial"
method uses the resource function
FindCanonicalHypergraphIsomorphism
directly.
▪
Canonical forms computed with different
Method
settings are always isomorphic, but need not be identical.
▪
With
"Annotations"
True
, vertex and edge annotations, including styles, are transferred to the relabeled vertices and hyperedges of the canonical form.
​
Examples  
(12)
Basic Examples  
(2)
Find the canonical form of a hypergraph:
In[1]:=
chg=
CanonicalHypergraph

Hypergraph
[{{a,b},{b,c},{c,a,d}}]
Out[1]=
Its vertices are relabeled by consecutive integers:
In[2]:=
EdgeList[chg]
Out[2]=
{{1,3},{1,4},{2,3,4}}
_________________________________________________________________________________________________________________
Isomorphic hypergraphs have identical canonical forms:
In[1]:=
CanonicalHypergraph

Hypergraph
[{{a,b},{b,c}}]===
CanonicalHypergraph

Hypergraph
[{{2,3},{1,2}}]
Out[1]=
True
Scope  
(4)

Options  
(2)

Properties & Relations  
(3)

Possible Issues  
(1)

SeeAlso
IsomorphicHypergraphQ
 
▪
Hypergraph
 
▪
EnumerateHypergraphs
 
▪
RandomHypergraph
 
▪
HypergraphInsertionBracket
RelatedGuides
▪
HypergraphFunctionality
""

© 2026 Wolfram. All rights reserved.

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