native#

Default (native) KnotPy notation with all diagram information stored. It is similar to EM notation.

Notation example (without attributes):

SpatialGraph Crossing a [(‘b’,0),(‘b’,2),(‘b’,1),(‘v’,0)] Crossing b [(‘a’,0),(‘a’,2),(‘a’,1),(‘u’,0)] Vertex u [(‘b’,3)] Vertex v [(‘a’,3)]

Notation example (with attributes):

SpatialGraph {‘name’:’x1’,’color’:’red’} Crossing a [(‘b’,0,{‘color’:’Orange’}),(‘b’,2,{‘color’:’Orange’}),(‘b’,1,{‘color’:’Orange’}),(‘v’,0,{‘color’:’Orange’})] {‘color’:’blue’} Crossing b [(‘a’,0,{‘color’:’Orange’}),(‘a’,2,{‘color’:’Orange’}),(‘a’,1,{‘color’:’Orange’}),(‘u’,0,{‘color’:’Orange’})] {‘color’:’blue’} Vertex u [(‘b’,3,{‘color’:’Orange’})] {} Vertex v [(‘a’,3,{‘color’:’Orange’})] {}

See “Ewing, B. & Millett, K. C. in The mathematical heritage of CF Gauss 225–266 (World Scientific, 1991)”.

Functions

from_knotpy_notation(notation)

Convert notation string into a PlanarDiagram.

to_knotpy_notation(k)

Return KnotPy notation of planar diagram.

to_knotpy_notation(k)#

Return KnotPy notation of planar diagram.

Parameters:

k (PlanarDiagram) – Planar diagram.

Returns:

KnotPy notation string.

Return type:

str

from_knotpy_notation(notation)#

Convert notation string into a PlanarDiagram.

Parameters:

notation (str)

Return type:

PlanarDiagram | OrientedPlanarDiagram