compute the HOMFLY polynomial for knot and links

Input format

gauss notation or Cartesian coordinates

Cartesian coordinates

xyz format and second line for ends information.

10
5   
1   0   0   0
2   0   0   1   
3   0   0   2
4   0   0   3
5   0   0   4
6   1   0   0
7   1   0   1
8   1   0   2  
9   1   0   3
10  1   0   4

其中第二行表示在哪个点做一个分割

requirments

examples