# R-Matrix Invariants

KnotTheory can compute knot and link invariants associated with matrix solutions of the Yang-Baxter equation, using the program REngine:

(For In see Setup)

 In:= ?REngine REngine[K, Rp, Rn, Mcupl, Mcupr, Mcapl Mcapr] returns the invariant associated with the given R-matrices (Rp for positive crossings, Rn for negative crossings) and oriented creation and annihilation M matrices, of the oriented knot or link K. See the Manual for details of convention. Note that REngine does not verify that the given matrices actually define an invariant, use TestRMatrix[..] for this purpose.
 In:= REngine::about REngine was written by Siddarth Sankaran at the University of Toronto, in the summer of 2005

In more detail, let $V$ be a free module of finite rank over a commutative ring, and let $R, \bar{R} \in End(V \otimes V)$ be invertible. Further, let there be invertible endomorphisms $M_\leftarrow, M_\rightarrow, M^\leftarrow, M^\rightarrow \in End(V)$; these correspond to McupL, McupR, McapL, and McapR respectively. Fixing a basis of V, we can regard all of these endomorphisms as matrices.

The following notation is useful: for $n = dim(V)$, $R_{ab}^{cd}$ refers to the element of R in row $n(c-1)+d$ and column $n(a-1) + b$.

For an oriented knot or link $K$, REngine returns the product $\tau(K)$, which is computed as follows:

1. Find a Morse link presentation of $K$ such that it is composed only of crossings of the X[k, Over/Under, Down, Down] variety; this is accomplished by adding caps and cups where necessary.
2. Label the edges in between events in the Morse link presentation of $K$.
3. Associate each event with one of the matrices as shown, with the indices given by the labelling:
4. Define $\tau(K)$ as the result of taking the product of the matrices associated with the elements of K, and summing over repeated indices; each sum runs from 1 to $n=dim(V)$.

As an example, let K be the trefoil as shown, with the chosen axis upwards, and the strands going down through all the crossings. Then $\tau(K) = \sum {M_\leftarrow}_{ab} {M_\rightarrow}_{cd} R_{bc}^{ef} R_{ef}^{gh} R_{gh}^{ij} {M^\rightarrow}_{ai}{M^\leftarrow}_{jd}$

where the summation is carried out on all the indices a through i, each ranging from 1 to n.

Determining that $\tau(K)$ is actually an invariant is simply a matter of checking the equality of the outcomes of Reidemeister moves in various configurations and orientations, as well as a few 'topological' moves. Note that REngine does not perform any checks, while the utility TestRMatrix performs the tests required to determine regular isotopy.

Let's use the REngine to find the Jones polynomial of the trefoil. The R and M matrices for the Jones polynomial, in the indeterminate t, are as follows: $R = \begin{pmatrix} t^{1/2} & 0&0&0 \\ 0&0&t&0 \\ 0&t&t^{1/2} - t^{3/2}&0\\0&0&0&t^{1/2} \end{pmatrix} , \bar{R} = R^{-1}$ $M^\leftarrow = M^\rightarrow = M_\leftarrow = M_\rightarrow = \begin{pmatrix} 0&t^{-1/4} \\ t^{1/4}&0 \end{pmatrix}$

Putting these definitions into Mathematica, we run the REngine on the trefoil. Note that the Jones polynomial is usually normalized so that the polynomial of the unknot 0_1 is 1, hence the term on the denominator.

 In:= r={{Sqrt[t], 0, 0, 0},{0, 0, t, 0},{0,t, Sqrt[t] - t^(3/2), 0}, {0,0,0,Sqrt[t]}}; rb = Inverse[r]; mcupl=mcapl=mcupr=mcapr={{0, t^(-1/4)},{t^(1/4), 0}};
 In:= jones = REngine[Knot[3,1], r, rb, mcupl, mcapl, mcupr, mcapr] / REngine[Knot[0,1], r, rb, mcupl, mcapr, mcupr, mcapr] //Apart Out=  -4 -3 1 -t + t + - t