Try it

Select a move and choose “Do move”, or edit the oriented knot with the arrow keys.

0 moves

Move Names and Arguments

Moves use the current diagram's labels. Commands, prefixes and over/under are case insensitive. X3 and 3 both mean crossing 3; S1 and 1 both mean strand 1. Crossings and faces start at zero. Strand numbers are the actual PD labels.

Command (alias)MeaningJSON object
DoR1 S1 over + (r1)Add a curl on S1; choose over/under and +/− sign.{"move":"DoR1","strand":1,"level":"over","sign":"+"}
UndoR1 X3 (u1)Remove a curl at X3.{"move":"UndoR1","crossing":3}
DoR2 F4 S1 over S2 (r2)Add two crossings in F4, S1 over S2.{"move":"DoR2","face":4,"over":1,"under":2}
UndoR2 F4 (u2)Remove the cancelling pair bounding F4.{"move":"UndoR2","face":4}
DoR3 S1 X3 (r3)Slide S1 over or under the opposite crossing X3 in a triangular face.{"move":"DoR3","strand":1,"crossing":3}

DoR2 F4 S2 under S1 and DoR2 4 1 2 mean the same as DoR2 F4 S1 over S2. Omit the face (DoR2 1 over 2, or omit the object's face) only when the two strands have exactly one common face. An ambiguous request returns the candidate face IDs.

PD labels and face numbering

A crossing is [under-in, over-90, under-out, over-270], in counterclockwise cyclic order. Crossings X0, X1, … follow the order in the PD array. Strand labels are preserved; new labels start above the current maximum. Removing crossings closes the gaps in crossing indices.

Faces are recomputed after every move using KnotSharp's deterministic rule:

  1. Visit crossings in PD order and their four slots in the order above. From each slot, cross the strand and turn left at the next crossing, following the boundary until the starting strand is reached again.
  2. Rotate each boundary list so that its first occurrence of the smallest numerical strand label comes first. Preserve the direction of the boundary walk.
  3. Deduplicate boundaries by their set of strand labels, keeping the first encountered boundary.
  4. Sort the remaining boundary lists lexicographically by integer values (a shorter prefix comes first), and number them F0, F1, ….

There is no special exterior-face number. For example, the trefoil PD [[1,5,2,4],[3,1,4,6],[5,3,6,2]] has boundaries F0 = [1,3,5], F1 = [1,4], F2 = [2,5], F3 = [2,6,4], F4 = [3,6]. Replay output gives these boundaries at every step.

These tools currently accept single oriented knots. [] represents the crossingless unknot, with an implicit strand S0 on which R1 can add a curl. It has no PD-derived face IDs. The implementation uses KnotSharp's Reidmeister move definitions.

Drawing and PD info

Click a grid square, then draw with the arrow keys; hold Shift to pass under. Right-drag erases, left-drag pans, and scrolling zooms. Close the curve to refresh the available moves. S labels identify strands, X labels crossings, and F labels faces. Face IDs use the rule below. Executing a move may redraw the layout; the knot's orientation and the resulting PD labels are preserved.

Editing the drawing recomputes its PD labels in grid order. Selecting and executing a move uses the labels currently shown on the canvas. PD info mode is enabled here and remains off on other drawing pages.

API

POST {"start_pd":[...],"moves":[]} to /api/reidemeister-moves/list. The response contains state (PD, face boundaries and strand IDs), moves (JSON move objects), and count. The list follows KnotSharp's available move definitions, including both R2 over/under orders in each face.

POST {"start_pd":[...],"moves":[...]} to /api/reidemeister-moves/execute to replay moves and return the resulting state, next move list, and an oriented grid drawing. This preserves the resulting PD's strand labels and crossing order. A layout failure leaves the current canvas unchanged.

The interactive diagram is limited to 200 crossings. Each request, including move computation and layout generation, has a five-second computation timeout. Replay limits and error codes are documented on Reidemeister Certificate Replay.