Vogel’s algorithm continued …

Hello everyone,
Last week we implemented the Vogel’s algorithm Part – 1, which would check for the bad regions and remove them. This week started off  tweaking the last week’s code. I was thinking that instead of performing a move and then looking for the bad regions, why not perform all the moves necessary to correct the bad regions in a single go. But this turned out to be a wrong approach as the seifert circles expected were not matching with the results we got. So we choose a bad region, perform a move and again see if there are bad regions, basically a while loop which captures this was implemented. If there are no bad regions we move onto the next part which is detecting the braidword of the knot. In the part 2, we use the following information from part 1 of the algorithm, the PD Code, seifert circles, regions with respect to the final knot after we have removed the necessary regions by performing the moves.  Now there are exactly two seifert circles which match with the regions, we select one of them and see with what seifert circle it shares a crossing and number the second seifert circle as 2 and so on and so forth.
For example here are the results we get :
sage: L = link.Link(oriented_gauss_code = [[-1, +2, -3, 4, +5, +1, -2, +6, +7, 3, -4, -7, -6,-5],[‘-‘,’-‘,’-‘,’-‘,’+’,’-‘,’+’]])

Final method gives out the final seifert circles, regions and the planar code of the modified knot. We see exactly two regions coincide with the seifert circles.
sage: L.final()

seifert circles
[[[18, 4],
[21, 15],
[9, 3, 19, 11, 17, 5, 13, 7, 1],
[10, 20, 16, 12, 6, 14, 22, 8, 2]]

regions,
[[-15, -21],
[6, -13],
[2, -9],
[8, -1],
[18, 4],
[-3, 10, -19],
[12, -5, -17],
[20, 16, -11],
[14, 22, -7],
[19, 11, 17, -4],
[21, -14, -6, -12, -16],
[15, -20, -10, -2, -8, -22],
[5, 13, 7, 1, 9, 3, -18]]

PD_code,
[[1, 9, 2, 8],
[9, 3, 10, 2],
[5, 13, 6, 12],
[13, 7, 14, 6],
[22, 7, 1, 8],
[19, 11, 20, 10],
[16, 11, 17, 12],
[18, 4, 19, 3],
[17, 4, 18, 5],
[21, 14, 22, 15],
[20, 16, 21, 15]]]

#this is still a method in development
sage: L.seifert_to_braid()
here we have numbered the seifert circles which form the strands in the braidword
{1: [18, 4], 2: [9, 3, 19, 11, 17, 5, 13, 7, 1], 3: [10, 20, 16, 12, 6, 14, 22, 8, 2], 4: [21, 15]}

#this is other information required for the ordering of the crossings
{1: [[18, 4, 19, 3], [17, 4, 18, 5]], 2: [[1, 9, 2, 8], [9, 3, 10, 2], [5, 13, 6, 12], [13, 7, 14, 6], [22, 7, 1, 8], [19, 11, 20, 10], [16, 11, 17, 12], [18, 4, 19, 3], [17, 4, 18, 5]], 3: [[1, 9, 2, 8], [9, 3, 10, 2], [5, 13, 6, 12], [13, 7, 14, 6], [22, 7, 1, 8], [19, 11, 20, 10], [16, 11, 17, 12], [21, 14, 22, 15], [20, 16, 21, 15]], 4: [[21, 14, 22, 15], [20, 16, 21, 15]]}
{1: [‘-‘, ‘+’], 2: [‘-‘, ‘-‘, ‘-‘, ‘-‘, ‘+’, ‘-‘, ‘+’, ‘-‘, ‘+’], 3: [‘-‘, ‘-‘, ‘-‘, ‘-‘, ‘+’, ‘-‘, ‘+’, ‘+’, ‘-‘], 4: [‘+’, ‘-‘]}
{1: [[4, 19], [18, 5]], 2: [[9, 2], [3, 10], [13, 6], [7, 14], [1, 8], [11, 20], [17, 12], [4, 19], [18, 5]], 3: [[9, 2], [3, 10], [13, 6], [7, 14], [1, 8], [11, 20], [17, 12], [22, 15], [16, 21]], 4: [[22, 15], [16, 21]]}
{1: [[18, 3], [17, 4]], 2: [[1, 8], [9, 2], [5, 12], [13, 6], [22, 7], [19, 10], [16, 11], [18, 3], [17, 4]], 3: [[1, 8], [9, 2], [5, 12], [13, 6], [22, 7], [19, 10], [16, 11], [21, 14], [20, 15]], 4: [[21, 14], [20, 15]]}

So the next and the final part is to trace through the ordering of the crossings and assign them with a braid generator and that generates the braidword.
The last part of ordering has been a tough part to generalize and code. It is like we have all the information but the dots are yet to be connected to get the final picture. I would like to leave you with two examples which we start from the first.

#so we start with the oriented gauss code
sage: L = link.Link(oriented_gauss_code = [[-1, +2, -3, 4, +5, +1, -2, +6, +7, 3, -4, -7, -6,-5],[‘-‘,’-‘,’-‘,’-‘,’+’,’-‘,’+’]])
#get the pd_code
sage: L.PD_code()
[[1, 7, 2, 6],
[7, 3, 8, 2],
[3, 11, 4, 10],
[11, 5, 12, 4],
[14, 5, 1, 6],
[13, 9, 14, 8],
[12, 9, 13, 10]]
#compute the regions
sage: L.regions()
[[4, -11],
[2, -7],
[6, -1],
[13, 9],
[-4, -10, -12],
[-8, -2, -6, -14],
[10, -3, 8, -13],
[14, -5, 12, -9],
[7, 3, 11, 5, 1]]
#compute the seifert circles
sage: L.seifert_circles()
[[13, 9], [12, 10, 4], [8, 14, 6, 2], [7, 3, 11, 5, 1]]
#remove the bad regions … this is just a method showing how the remove_regions works
#it returns a pd_code after the move has been made
sage: L.remove_regions()
[[1, 9, 2, 8],
[9, 3, 10, 2],
[5, 13, 6, 12],
[13, 7, 14, 6],
[18, 7, 1, 8],
[17, 11, 18, 10],
[14, 11, 15, 12],
[16, 4, 17, 3],
[15, 4, 16, 5]]

#the below method returns the seifert circles, regions and pd_code after the correction (we run the above method until we end up with these results)
sage: L.final()
[[[18, 4],
[21, 15],
[9, 3, 19, 11, 17, 5, 13, 7, 1],
[10, 20, 16, 12, 6, 14, 22, 8, 2]],
[[-15, -21],
[6, -13],
[2, -9],
[8, -1],
[18, 4],
[-3, 10, -19],
[12, -5, -17],
[20, 16, -11],
[14, 22, -7],
[19, 11, 17, -4],
[21, -14, -6, -12, -16],
[15, -20, -10, -2, -8, -22],
[5, 13, 7, 1, 9, 3, -18]],
[[1, 9, 2, 8],
[9, 3, 10, 2],
[5, 13, 6, 12],
[13, 7, 14, 6],
[22, 7, 1, 8],
[19, 11, 20, 10],
[16, 11, 17, 12],
[18, 4, 19, 3],
[17, 4, 18, 5],
[21, 14, 22, 15],
[20, 16, 21, 15]]]

#here we have numbered the seifert circles which form the strands in the braidword
sage: L.seifert_to_braid()
{1: [18, 4], 2: [9, 3, 19, 11, 17, 5, 13, 7, 1], 3: [10, 20, 16, 12, 6, 14, 22, 8, 2], 4: [21, 15]}

The ordering of the crossing remain …. which would complete the algorithm

Another example :

sage: L = link.Link(oriented_gauss_code = [[-1, +2, 3, -4, 5, -6, 7, 8, -2, -5, +6, +1, -8, -3, -4, -7],[‘-‘,’-‘,’-‘,’-‘,’+’,’+’,’-‘,’+’]])

sage: L.PD_code()
[[1, 13, 2, 12],
[9, 3, 10, 2],
[14, 4, 15, 3],
[4, 16, 5, 15],
[10, 5, 11, 6],
[6, 11, 7, 12],
[16, 8, 1, 7],
[13, 8, 14, 9]]
sage: L.regions()
[[6, -11],
[15, -4],
[9, 3, -14],
[2, -9, -13],
[1, 13, -8],
[12, -1, -7],
[5, 11, 7, -16],
[-3, 10, -5, -15],
[-6, -10, -2, -12],
[16, 8, 14, 4]]

sage: L.seifert_circles()
[[10, 6, 12, 2], [16, 8, 14, 4], [13, 9, 3, 15, 5, 11, 7, 1]]

sage: L.remove_regions()
‘No move required’
sage: L.final()
[[[10, 6, 12, 2], [16, 8, 14, 4], [13, 9, 3, 15, 5, 11, 7, 1]],
[[6, -11],
[15, -4],
[9, 3, -14],
[2, -9, -13],
[1, 13, -8],
[12, -1, -7],
[5, 11, 7, -16],
[-3, 10, -5, -15],
[-6, -10, -2, -12],
[16, 8, 14, 4]],

[[1, 13, 2, 12],

[9, 3, 10, 2],
[14, 4, 15, 3],
[4, 16, 5, 15],
[10, 5, 11, 6],
[6, 11, 7, 12],
[16, 8, 1, 7],
[13, 8, 14, 9]]]

sage: L.seifert_to_braid()
#we number the strands
{1: [10, 6, 12, 2], 2: [13, 9, 3, 15, 5, 11, 7, 1], 3: [16, 8, 14, 4]}

Other information for extracting the braidword
{1: [[1, 13, 2, 12], [9, 3, 10, 2], [10, 5, 11, 6], [6, 11, 7, 12]], 2: [[1, 13, 2, 12], [9, 3, 10, 2], [14, 4, 15, 3], [4, 16, 5, 15], [10, 5, 11, 6], [6, 11, 7, 12], [16, 8, 1, 7], [13, 8, 14, 9]], 3: [[14, 4, 15, 3], [4, 16, 5, 15], [16, 8, 1, 7], [13, 8, 14, 9]]}
{1: [‘-‘, ‘-‘, ‘+’, ‘+’], 2: [‘-‘, ‘-‘, ‘-‘, ‘-‘, ‘+’, ‘+’, ‘-‘, ‘+’], 3: [‘-‘, ‘-‘, ‘-‘, ‘+’]}
{1: [[13, 2], [3, 10], [11, 6], [7, 12]], 2: [[13, 2], [3, 10], [4, 15], [16, 5], [11, 6], [7, 12], [8, 1], [14, 9]], 3: [[4, 15], [16, 5], [8, 1], [14, 9]]}
{1: [[1, 12], [9, 2], [10, 5], [6, 11]], 2: [[1, 12], [9, 2], [14, 3], [4, 15], [10, 5], [6, 11], [16, 7], [13, 8]], 3: [[14, 3], [4, 15], [16, 7], [13, 8]]}
{1: [[9, 3, 10, 2], [10, 5, 11, 6], [6, 11, 7, 12]], 2: [[1, 13, 2, 12], [9, 3, 10, 2], [14, 4, 15, 3], [4, 16, 5, 15], [10, 5, 11, 6], [6, 11, 7, 12], [16, 8, 1, 7], [13, 8, 14, 9]], 3: [[14, 4, 15, 3], [4, 16, 5, 15], [16, 8, 1, 7], [13, 8, 14, 9]]}
[[13, 2], [3, 10], None]

So to conclude, I hope I can say we are almost able to see the result and almost there but as said the dots are yet to be connected. The implementation of the last part remains.

Advertisements