make_reidemeister_move#
- make_reidemeister_move(k: PlanarDiagram, location, inplace=False)#
Makes a Reidemeister move of the specified type on the given planar diagram.
The function identifies the type of Reidemeister move based on the input location. The type of move can include Reidemeister 1 (adding or removing a kink), Reidemeister 2 (poke or unpoke), or Reidemeister 3. The operation is performed on the input planar diagram k. The modification can be either in-place or return a new modified diagram based on the value of the inplace parameter.
- Args:
- k (PlanarDiagram): The planar diagram on which the Reidemeister move
is to be executed.
- location (Union[set, tuple, Endpoint]): Information specifying the
type and location of the Reidemeister move. Can be: - A set of length 3 for R3 moves. - A set of length 2 for R2 unpoke moves. - An Endpoint for R1 unkink moves. - A tuple of length 2 containing Endpoint objects for R2 poke
moves.
A tuple containing an Endpoint and an int for R1 make kink moves.
- inplace (bool): Indicates whether the operation should modify the input
diagram k in-place. If False, a new modified diagram is returned.
- Returns:
- PlanarDiagram: The modified planar diagram after the specified
Reidemeister move. If inplace is True, the same input diagram instance is returned.
- Raises:
- ValueError: If the location input does not correspond to a known type
of Reidemeister move.