File: links.py

package info (click to toggle)
snappea 3.0d3-23
  • links: PTS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 5,900 kB
  • ctags: 3,582
  • sloc: ansic: 33,469; sh: 8,565; python: 7,623; makefile: 242
file content (25 lines) | stat: -rw-r--r-- 754 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#	links.py

#	Search for link complements in the 5-tetrahedron census.

#	Note:  The pound sign (#) introduces comments.

from SnapPea import *

#	Examine each Triangulation in the 5-tetrahedron census.
for t in CuspedCensus():

	#	For each cusp, do a Dehn filling on the shortest
	#	curve, which, by SnapPea's convention, is the
	#	meridional filling (1,0).
	for i in range(t.get_num_cusps()):
		t.set_cusp(i, 1, 0)
		
	#	We now have a closed manifold.
	#	Look at its fundamental group, and if the
	#	number of generators is zero (meaning the
	#	group is trivial), print the name of
	#	the original Triangulation, which we have shown
	#	to be a link complement in a homotopy sphere.
	if t.fundamental_group().num_generators() == 0:
		print t.get_name()