Is there an algorithm to translate Dowker-Thistlethwaite notation into braid notation? I am interested in translating DT-codes into braid words. As an example for the trefoil knot: $\{4,6,2\}$ into $\{1,1,1\}$, where the latter stands for the braid word in the braid group of two strands.
Is there an algorithm for this? The low-dimensional topology computation programs like SnapPy or SageMath can do this indirectly but I could not figure out how.
 A: Sage allows to do this using the hidden method
_braid_word_components_vector of knots and links.
Example:
sage: Kn = Knots()
sage: dt = [4, 6, 2]
sage: K = Kn.from_dowker_code(dt)
sage: braid_word = K._braid_word_components_vector()
sage: braid_word
[1, 1, 1]

The above few lines can be turned into a function:
def braid_word_from_dt(dt):
    r"""
    Return the braid word corresponding to this DT code.

    A DT code is a Dowker-Thistlethwaite code.

    INPUT:

    - ``dt`` -- a dt code, as a list

    OUTPUT: the braid word for the corresponding knot.

    EXAMPLES::

        sage: dt = [4, 6, 2]
        sage: braid_word_from_dt(dt)
        [1, 1, 1]
    """
    return Knots().from_dowker_code(dt)._braid_word_components_vector()

Usage:
sage: braid_word_from_dt([4, 6, 2])
[1, 1, 1]

A: I have somehow overlook the function braid_word() in snapPy which also does the job. Although the input is a bit more complicated.
Example as a python script:
import snappy

def dt_to_braid(dt):
    return snappy.Link(dt).braid_word()

#The input dt has to be a string of the form: 'DT: [(i1,...,in)]'
#The output is [b1,...,bk]
#
#Example for the trefoil knot:
#dt_to_braid('DT: [(4,6,2)]') yields
#[1,1,1]

