regina 7.4.1__cp314-cp314-macosx_10_13_x86_64.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (186) hide show
  1. regina/.dylibs/libgmp.10.dylib +0 -0
  2. regina/.dylibs/libgmpxx.4.dylib +0 -0
  3. regina/__init__.py +192 -0
  4. regina/engine.cpython-314-darwin.so +0 -0
  5. regina/plainCompleter.py +221 -0
  6. regina/pyCensus/__init__.py +14 -0
  7. regina/pyCensus/christy-knots-links.tdb +0 -0
  8. regina/pyCensus/closed-hyp-census-full.tdb +0 -0
  9. regina/pyCensus/closed-nor-census-11.tdb +0 -0
  10. regina/pyCensus/closed-or-census-11.tdb +0 -0
  11. regina/pyCensus/cusped-hyp-nor-census-9.tdb +0 -0
  12. regina/pyCensus/cusped-hyp-or-census-9.tdb +0 -0
  13. regina/sageRegina/__init__.py +2 -0
  14. regina/sageRegina/config.py +9 -0
  15. regina/sageRegina/test.py +131 -0
  16. regina/sageRegina/testsuite/CMakeLists.txt +64 -0
  17. regina/sageRegina/testsuite/O2_1.rga +15 -0
  18. regina/sageRegina/testsuite/O2_1.tri +28 -0
  19. regina/sageRegina/testsuite/README.txt +21 -0
  20. regina/sageRegina/testsuite/alltypes-exc.out +698 -0
  21. regina/sageRegina/testsuite/alltypes-exc.test +92 -0
  22. regina/sageRegina/testsuite/alltypes-noexc.out +698 -0
  23. regina/sageRegina/testsuite/alltypes-noexc.test +85 -0
  24. regina/sageRegina/testsuite/alltypes.out +698 -0
  25. regina/sageRegina/testsuite/alltypes.test +85 -0
  26. regina/sageRegina/testsuite/angles.out +102 -0
  27. regina/sageRegina/testsuite/angles.test +70 -0
  28. regina/sageRegina/testsuite/arrow.out +86 -0
  29. regina/sageRegina/testsuite/arrow.test +224 -0
  30. regina/sageRegina/testsuite/base64.out +2 -0
  31. regina/sageRegina/testsuite/base64.test +37 -0
  32. regina/sageRegina/testsuite/basic_callback.out +124 -0
  33. regina/sageRegina/testsuite/basic_sub.out +7 -0
  34. regina/sageRegina/testsuite/binom.out +14 -0
  35. regina/sageRegina/testsuite/binom.test +69 -0
  36. regina/sageRegina/testsuite/bool.out +6 -0
  37. regina/sageRegina/testsuite/bool.test +62 -0
  38. regina/sageRegina/testsuite/bytes.out +17 -0
  39. regina/sageRegina/testsuite/bytes.test +76 -0
  40. regina/sageRegina/testsuite/callbacks.out +515 -0
  41. regina/sageRegina/testsuite/callbacks.test +279 -0
  42. regina/sageRegina/testsuite/census.out +120 -0
  43. regina/sageRegina/testsuite/census.test +156 -0
  44. regina/sageRegina/testsuite/clone.out +18 -0
  45. regina/sageRegina/testsuite/clone.test +99 -0
  46. regina/sageRegina/testsuite/comparison.out +41 -0
  47. regina/sageRegina/testsuite/comparison.test +47 -0
  48. regina/sageRegina/testsuite/construction.out +120 -0
  49. regina/sageRegina/testsuite/construction.test +63 -0
  50. regina/sageRegina/testsuite/constructors.out +14 -0
  51. regina/sageRegina/testsuite/constructors.test +95 -0
  52. regina/sageRegina/testsuite/cube.orb +87 -0
  53. regina/sageRegina/testsuite/discs.out +3 -0
  54. regina/sageRegina/testsuite/discs.test +38 -0
  55. regina/sageRegina/testsuite/docstrings.filter +22 -0
  56. regina/sageRegina/testsuite/docstrings.out +802 -0
  57. regina/sageRegina/testsuite/docstrings.out.v2 +799 -0
  58. regina/sageRegina/testsuite/docstrings.test +55 -0
  59. regina/sageRegina/testsuite/dodec.orb +309 -0
  60. regina/sageRegina/testsuite/embeddings.out +23 -0
  61. regina/sageRegina/testsuite/embeddings.test +87 -0
  62. regina/sageRegina/testsuite/enumerate.out +62 -0
  63. regina/sageRegina/testsuite/enumerate.test +80 -0
  64. regina/sageRegina/testsuite/equality.out +112 -0
  65. regina/sageRegina/testsuite/equality.test +308 -0
  66. regina/sageRegina/testsuite/euler.out +15 -0
  67. regina/sageRegina/testsuite/euler.test +93 -0
  68. regina/sageRegina/testsuite/exception.out +7 -0
  69. regina/sageRegina/testsuite/exception.test +98 -0
  70. regina/sageRegina/testsuite/facenumbering.out +546 -0
  71. regina/sageRegina/testsuite/facenumbering.test +72 -0
  72. regina/sageRegina/testsuite/faces.out +40 -0
  73. regina/sageRegina/testsuite/faces.test +70 -0
  74. regina/sageRegina/testsuite/file.out +1229 -0
  75. regina/sageRegina/testsuite/file.test +68 -0
  76. regina/sageRegina/testsuite/file1.rga +0 -0
  77. regina/sageRegina/testsuite/file2.rga +0 -0
  78. regina/sageRegina/testsuite/file3.rga +119 -0
  79. regina/sageRegina/testsuite/flags.out +38 -0
  80. regina/sageRegina/testsuite/flags.out.v2 +38 -0
  81. regina/sageRegina/testsuite/flags.test +81 -0
  82. regina/sageRegina/testsuite/flype.out +37 -0
  83. regina/sageRegina/testsuite/flype.test +48 -0
  84. regina/sageRegina/testsuite/generic.out +116 -0
  85. regina/sageRegina/testsuite/generic.test +74 -0
  86. regina/sageRegina/testsuite/groups.out +70 -0
  87. regina/sageRegina/testsuite/groups.test +115 -0
  88. regina/sageRegina/testsuite/hash.out +66 -0
  89. regina/sageRegina/testsuite/hash.test +84 -0
  90. regina/sageRegina/testsuite/hypersurfaces.out +681 -0
  91. regina/sageRegina/testsuite/hypersurfaces.test +89 -0
  92. regina/sageRegina/testsuite/i18n-latin1.rga +8 -0
  93. regina/sageRegina/testsuite/i18n-utf8.rga +8 -0
  94. regina/sageRegina/testsuite/i18n.out +6 -0
  95. regina/sageRegina/testsuite/i18n.test +89 -0
  96. regina/sageRegina/testsuite/id.out +2 -0
  97. regina/sageRegina/testsuite/id.test +45 -0
  98. regina/sageRegina/testsuite/index.out +2 -0
  99. regina/sageRegina/testsuite/index.test +41 -0
  100. regina/sageRegina/testsuite/integer.out +74 -0
  101. regina/sageRegina/testsuite/integer.test +54 -0
  102. regina/sageRegina/testsuite/italian.orb +90 -0
  103. regina/sageRegina/testsuite/iterators.out +118 -0
  104. regina/sageRegina/testsuite/iterators.test +126 -0
  105. regina/sageRegina/testsuite/knotted-Y.orb +47 -0
  106. regina/sageRegina/testsuite/listener.out +43 -0
  107. regina/sageRegina/testsuite/listener.test +99 -0
  108. regina/sageRegina/testsuite/listview.out +416 -0
  109. regina/sageRegina/testsuite/listview.test +251 -0
  110. regina/sageRegina/testsuite/lookup.out +13 -0
  111. regina/sageRegina/testsuite/lookup.test +42 -0
  112. regina/sageRegina/testsuite/lst.out +844 -0
  113. regina/sageRegina/testsuite/lst.test +195 -0
  114. regina/sageRegina/testsuite/memory1.out +62 -0
  115. regina/sageRegina/testsuite/memory1.test +152 -0
  116. regina/sageRegina/testsuite/memory2.out +62 -0
  117. regina/sageRegina/testsuite/memory2.test +122 -0
  118. regina/sageRegina/testsuite/memory3.out +92 -0
  119. regina/sageRegina/testsuite/memory3.test +214 -0
  120. regina/sageRegina/testsuite/misc.out +7 -0
  121. regina/sageRegina/testsuite/misc.test +54 -0
  122. regina/sageRegina/testsuite/operators.out +129 -0
  123. regina/sageRegina/testsuite/operators.test +59 -0
  124. regina/sageRegina/testsuite/orb.out +441 -0
  125. regina/sageRegina/testsuite/orb.test +47 -0
  126. regina/sageRegina/testsuite/pdf.out +4 -0
  127. regina/sageRegina/testsuite/pdf.test +47 -0
  128. regina/sageRegina/testsuite/perm.out +36 -0
  129. regina/sageRegina/testsuite/perm.test +74 -0
  130. regina/sageRegina/testsuite/plantri.out +12 -0
  131. regina/sageRegina/testsuite/plantri.test +58 -0
  132. regina/sageRegina/testsuite/poincare.tri +55 -0
  133. regina/sageRegina/testsuite/presentations.out +11 -0
  134. regina/sageRegina/testsuite/presentations.test +59 -0
  135. regina/sageRegina/testsuite/refs.out +51 -0
  136. regina/sageRegina/testsuite/refs.test +126 -0
  137. regina/sageRegina/testsuite/repr.out +951 -0
  138. regina/sageRegina/testsuite/repr.out.v2 +951 -0
  139. regina/sageRegina/testsuite/repr.test +546 -0
  140. regina/sageRegina/testsuite/runbasic.in +75 -0
  141. regina/sageRegina/testsuite/safeheldtype_basic.out +17 -0
  142. regina/sageRegina/testsuite/safeheldtype_basic.test +111 -0
  143. regina/sageRegina/testsuite/safeheldtype_packet.out +58 -0
  144. regina/sageRegina/testsuite/safeheldtype_packet.test +179 -0
  145. regina/sageRegina/testsuite/sample.pdf +0 -0
  146. regina/sageRegina/testsuite/sets.out +7 -0
  147. regina/sageRegina/testsuite/sets.test +42 -0
  148. regina/sageRegina/testsuite/skeleton.out +308 -0
  149. regina/sageRegina/testsuite/skeleton.test +52 -0
  150. regina/sageRegina/testsuite/snappea.out +90 -0
  151. regina/sageRegina/testsuite/snappea.test +133 -0
  152. regina/sageRegina/testsuite/snapshot.out +15 -0
  153. regina/sageRegina/testsuite/snapshot.test +76 -0
  154. regina/sageRegina/testsuite/sort.out +78 -0
  155. regina/sageRegina/testsuite/sort.test +58 -0
  156. regina/sageRegina/testsuite/special.out +4 -0
  157. regina/sageRegina/testsuite/special.test +45 -0
  158. regina/sageRegina/testsuite/standardtri.out +12101 -0
  159. regina/sageRegina/testsuite/standardtri.test +453 -0
  160. regina/sageRegina/testsuite/surfaces.out +2133 -0
  161. regina/sageRegina/testsuite/surfaces.test +112 -0
  162. regina/sageRegina/testsuite/swapping.out +25 -0
  163. regina/sageRegina/testsuite/swapping.test +86 -0
  164. regina/sageRegina/testsuite/testall.in +174 -0
  165. regina/sageRegina/testsuite/testbasic.in +277 -0
  166. regina/sageRegina/testsuite/testcallback.in +148 -0
  167. regina/sageRegina/testsuite/testsub.in +148 -0
  168. regina/sageRegina/testsuite/theta_in_solid_torus.orb +65 -0
  169. regina/sageRegina/testsuite/tightencode.out +40 -0
  170. regina/sageRegina/testsuite/tightencode.test +106 -0
  171. regina/sageRegina/testsuite/treedecomp.out +135 -0
  172. regina/sageRegina/testsuite/treedecomp.test +64 -0
  173. regina/sageRegina/testsuite/treetraversal.out +52 -0
  174. regina/sageRegina/testsuite/treetraversal.test +188 -0
  175. regina/sageRegina/testsuite/trigeneral.out +1251 -0
  176. regina/sageRegina/testsuite/trigeneral.test +153 -0
  177. regina/sageRegina/testsuite/utf8.out +42 -0
  178. regina/sageRegina/testsuite/utf8.test +92 -0
  179. regina/sageRegina/testsuite/whitehead.tri +47 -0
  180. regina/sageRegina/version.py +5 -0
  181. regina/sageSetup.py +41 -0
  182. regina/test.py +6 -0
  183. regina-7.4.1.dist-info/METADATA +109 -0
  184. regina-7.4.1.dist-info/RECORD +186 -0
  185. regina-7.4.1.dist-info/WHEEL +6 -0
  186. regina-7.4.1.dist-info/top_level.txt +4 -0
@@ -0,0 +1,546 @@
1
+ # Regina - A Normal Surface Theory Calculator
2
+ # Python Test Suite Component
3
+ #
4
+ # Copyright (c) 2007-2025, Ben Burton
5
+ # For further details contact Ben Burton (bab@debian.org).
6
+ #
7
+ # Tests the Python repr() output for some of Regina's classes.
8
+ #
9
+ # This file is a single component of Regina's python test suite. To run
10
+ # the python test suite, move to the main python directory in the source
11
+ # tree and run "make check".
12
+ #
13
+ # This program is free software; you can redistribute it and/or
14
+ # modify it under the terms of the GNU General Public License as
15
+ # published by the Free Software Foundation; either version 2 of the
16
+ #
17
+ # As an exception, when this program is distributed through (i) the
18
+ # App Store by Apple Inc.; (ii) the Mac App Store by Apple Inc.; or
19
+ # (iii) Google Play by Google Inc., then that store may impose any
20
+ # digital rights management, device limits and/or redistribution
21
+ # restrictions that are required by its terms of service.
22
+ # License, or (at your option) any later version.
23
+ #
24
+ # This program is distributed in the hope that it will be useful, but
25
+ # WITHOUT ANY WARRANTY; without even the implied warranty of
26
+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
27
+ # General Public License for more details.
28
+ #
29
+ # You should have received a copy of the GNU General Public License
30
+ # along with this program. If not, see <https://www.gnu.org/licenses/>.
31
+
32
+ # Fetch the python/testsuite path in the source tree, since we will need
33
+ # to access external files.
34
+ import sys
35
+ if (len(sys.argv) > 1):
36
+ testpath = sys.argv[1]
37
+ else:
38
+ testpath = '.'
39
+
40
+ def dump(x):
41
+ if isinstance(x, list):
42
+ if len(x) > 0:
43
+ print('list of ' + x[0].__class__.__name__)
44
+ for i in x:
45
+ print(' ' + str(i))
46
+ else:
47
+ print('empty list')
48
+ else:
49
+ print(x.__class__.__qualname__)
50
+ print(str(x))
51
+ print(repr(x))
52
+ print()
53
+
54
+ # ----------------------------------------------------------------------
55
+ # maths/
56
+ # ----------------------------------------------------------------------
57
+
58
+ dump(Integer(-5))
59
+ dump(LargeInteger(9))
60
+ dump(LargeInteger.infinity)
61
+ dump(Rational(3,8))
62
+ dump(Perm2(0,1))
63
+ dump(Perm3(1,2))
64
+ dump(Perm4(1,3))
65
+ dump(Perm5(2,3))
66
+ dump(Perm6(2,3))
67
+ dump(Perm7(2,3))
68
+ dump(Perm8(2,3))
69
+ dump(Perm15(2,3))
70
+ dump(VectorInt([1,0,-2]))
71
+ dump(VectorLarge([1,0,LargeInteger.infinity,-2]))
72
+
73
+ m = Matrix2(1,2,3,4)
74
+ dump(m)
75
+ dump(m[1])
76
+
77
+ dump(MatrixBool([[True, False], [False, True]]))
78
+ dump(makeMatchingEquations(Example3.figureEight(), NormalCoords.Quad))
79
+
80
+ t = Example3.poincare()
81
+ dump(t.turaevViro(5))
82
+ dump(t.turaevViro(5).polynomial())
83
+
84
+ l = ExampleLink.figureEight()
85
+ dump(l.jones())
86
+ dump(l.homfly())
87
+
88
+ # ----------------------------------------------------------------------
89
+ # Flags and other enumerate/flag-like types
90
+ # ----------------------------------------------------------------------
91
+
92
+ dump(HyperList.Vertex)
93
+ dump(HyperAlg.VertexDD)
94
+ dump(NormalList.Vertex)
95
+ dump(NormalAlg.VertexDD)
96
+ dump(AngleAlg.DD)
97
+ dump(CensusPurge.NonMinimal)
98
+ dump(SurfaceExport.Name)
99
+
100
+ dump(HyperList.Vertex | HyperList.Vertex)
101
+ dump(HyperAlg.VertexDD | HyperAlg.VertexDD)
102
+ dump(NormalList.Vertex | NormalList.Vertex)
103
+ dump(NormalAlg.VertexDD | NormalAlg.VertexDD)
104
+ dump(AngleAlg.DD | AngleAlg.DD)
105
+ dump(CensusPurge.NonMinimal | CensusPurge.NonPrime)
106
+ dump(SurfaceExport.Name | SurfaceExport.Euler)
107
+
108
+ dump(NormalEncoding(NormalCoords.Quad))
109
+ dump(HyperEncoding(HyperCoords.Standard))
110
+ dump(LPSystem(NormalCoords.Quad))
111
+
112
+ # ----------------------------------------------------------------------
113
+ # algebra/
114
+ # ----------------------------------------------------------------------
115
+
116
+ dump(Example3.weberSeifert().homology())
117
+ dump(Example3.weberSeifert().markedHomology())
118
+ dump(Example3.weberSeifert().markedHomology().torsionInclusion())
119
+
120
+ g = Example3.poincare().fundamentalGroup()
121
+ dump(g)
122
+ dump(g.relation(0))
123
+ dump(g.relation(0).term(2))
124
+
125
+ g = GroupPresentation(3, ['aC', 'aBCb'])
126
+ dump(g)
127
+ dump(g.simplify())
128
+ dump(g)
129
+
130
+ # ----------------------------------------------------------------------
131
+ # utilities/
132
+ # ----------------------------------------------------------------------
133
+
134
+ b = Bitmask(5)
135
+ b.set(3, True)
136
+ dump(b)
137
+
138
+ b = Bitmask8()
139
+ b.set(3, True)
140
+ dump(b)
141
+
142
+ q = Qitmask8()
143
+ q.set(3, 2)
144
+ dump(q)
145
+
146
+ dump(BoolSet(True))
147
+ dump(TrieSet())
148
+
149
+ # ----------------------------------------------------------------------
150
+ # surface/, hypersurface/ and angle/
151
+ # ----------------------------------------------------------------------
152
+
153
+ dump(DiscType(7,3))
154
+ dump(DiscSpec(1,3,2))
155
+ dump(PrismSpec(5,1))
156
+
157
+ s = NormalSurfaces(Example3.s2xs1(), NormalCoords.Quad)
158
+ dump(s)
159
+ dump(s.surface(0))
160
+ s = NormalHypersurfaces(Example4.s3xs1(), HyperCoords.Prism)
161
+ dump(s)
162
+ dump(s.hypersurface(0))
163
+ s = AngleStructures(Example3.figureEight())
164
+ dump(s)
165
+ dump(s.structure(0))
166
+
167
+ dump(SurfaceFilterCombination())
168
+ f = SurfaceFilterProperties(); f.setEulerChars([0,1]); f.setOrientability(True)
169
+ dump(f)
170
+
171
+ t = Example3.poincare()
172
+ st = NormalSurfaces(t, NormalCoords.Quad)
173
+ dt = DiscSetSurface(st.surface(0))
174
+ dump(dt)
175
+ dump(dt.tetDiscs(0))
176
+
177
+ # ----------------------------------------------------------------------
178
+ # link/
179
+ # ----------------------------------------------------------------------
180
+
181
+ g = ModelLinkGraph.fromPlantri('bcdd,aeec,abfd,acfa,bffb,ceed')
182
+ dump(g)
183
+ dump(g.node(0))
184
+ dump(g.node(0).arc(2))
185
+ dump(g.cells())
186
+
187
+ dump(Link())
188
+ dump(Link(1))
189
+ dump(ExampleLink.whitehead())
190
+ dump(PacketOfLink(ExampleLink.whitehead()))
191
+
192
+ l = Link(1)
193
+ dump(l.component(0))
194
+ l = ExampleLink.figureEight()
195
+ dump(l.component(0))
196
+ dump(l.crossing(0))
197
+
198
+ l = Tangle(3,2)
199
+ dump(l)
200
+ dump(l.crossing(0))
201
+
202
+ # ----------------------------------------------------------------------
203
+ # snappea/
204
+ # ----------------------------------------------------------------------
205
+
206
+ s = ExampleSnapPea.whiteheadLink()
207
+ dump(s)
208
+ s.fill(5,-2,0)
209
+ dump(s)
210
+ dump(PacketOfSnapPeaTriangulation(s))
211
+ dump(s.cusp(0))
212
+ dump(s.cusp(1))
213
+
214
+ # ----------------------------------------------------------------------
215
+ # triangulation/
216
+ # ----------------------------------------------------------------------
217
+
218
+ dump(FacetSpec3(6,2))
219
+ dump(FacePair(1,3))
220
+ dump(FacetPairing3(Example3.figureEight()))
221
+ dump(FacetPairing4(Example4.s3xs1()))
222
+
223
+ dump(Example2.mobius())
224
+ dump(Example3.poincare())
225
+ dump(PacketOfTriangulation3(Example3.poincare()))
226
+ dump(Example4.cappellShaneson())
227
+ dump(Example5.sphere())
228
+
229
+ t = Example2.annulus()
230
+ dump(t.vertex(0))
231
+ dump(t.vertex(0).front())
232
+ dump(t.edge(0))
233
+ dump(t.edge(0).front())
234
+ dump(t.triangle(0))
235
+ dump(t.component(0))
236
+ dump(t.boundaryComponent(0))
237
+
238
+ t = Example3.poincare()
239
+ dump(t.vertex(0))
240
+ dump(t.vertex(0).front())
241
+ dump(t.edge(0))
242
+ dump(t.edge(0).front())
243
+ dump(t.triangle(0))
244
+ dump(t.triangle(0).front())
245
+ dump(t.tetrahedron(0))
246
+ dump(t.component(0))
247
+
248
+ t = Example4.cappellShaneson()
249
+ dump(t.vertex(0))
250
+ dump(t.vertex(0).front())
251
+ dump(t.edge(0))
252
+ dump(t.edge(0).front())
253
+ dump(t.edges())
254
+ dump(t.triangle(0))
255
+ dump(t.triangle(0).front())
256
+ dump(t.tetrahedron(0))
257
+ dump(t.tetrahedron(0).front())
258
+ dump(t.pentachoron(0))
259
+ dump(t.component(0))
260
+ dump(t.boundaryComponent(0))
261
+
262
+ t = Example5.sphere()
263
+ dump(t.vertex(0))
264
+ dump(t.vertex(0).front())
265
+ dump(t.edge(0))
266
+ dump(t.edge(0).front())
267
+ dump(t.triangle(0))
268
+ dump(t.triangle(0).front())
269
+ dump(t.tetrahedron(0))
270
+ dump(t.tetrahedron(0).front())
271
+ dump(t.pentachoron(0))
272
+ dump(t.pentachoron(0).front())
273
+ dump(t.simplex(0))
274
+ dump(t.component(0))
275
+ t.insertTriangulation(Example5.ballBundle())
276
+ dump(t.component(1))
277
+ dump(t.boundaryComponent(0))
278
+
279
+ i = Isomorphism3(2)
280
+ i.setSimpImage(0, 1)
281
+ i.setSimpImage(1, 0)
282
+ i.setFacetPerm(0, Perm4(1,2,3,0))
283
+ i.setFacetPerm(1, Perm4(0,2))
284
+ dump(i)
285
+
286
+ h = HomologicalData(Example3.lst(3,4))
287
+ dump(h)
288
+ dump(h.bdryHomologyMap(1))
289
+ dump(h)
290
+
291
+ # ----------------------------------------------------------------------
292
+ # manifold/
293
+ # ----------------------------------------------------------------------
294
+
295
+ dump(SFSFibre(5,-2))
296
+
297
+ sfsDisc = SFSpace(SFSpace.o2, 0, 1)
298
+ sfsDisc.insertFibre(3,1)
299
+ sfsDisc.insertFibre(4,-3)
300
+ sfsAnnulus = SFSpace(SFSpace.o2, 0, 2)
301
+ sfsAnnulus.insertFibre(2,1)
302
+ sfsAnnulus.insertFibre(5,7)
303
+
304
+ dump(LensSpace(7,2))
305
+ dump(sfsDisc)
306
+ dump(SimpleSurfaceBundle(SimpleSurfaceBundle.RP2xS1))
307
+ dump(SnapPeaCensusManifold('x', 101))
308
+ dump(Handlebody(2))
309
+ dump(TorusBundle(0,1,1,0))
310
+ dump(GraphLoop(sfsAnnulus, Matrix2(0,1,-1,2)))
311
+ dump(GraphPair(sfsDisc, sfsDisc, Matrix2(0,1,-1,2)))
312
+ dump(GraphTriple(sfsDisc, sfsAnnulus, sfsDisc, Matrix2(0,1,-1,2), Matrix2(-1,2,-3,5)))
313
+
314
+ dump(SFSAlt.altSet(sfsDisc));
315
+ dump(SFSAlt.altSet(sfsAnnulus));
316
+
317
+ # ----------------------------------------------------------------------
318
+ # subcomplex/
319
+ # ----------------------------------------------------------------------
320
+
321
+ dump(StandardTriangulation.recognise(Example3.figureEight()))
322
+
323
+ dump(TxIDiagonalCore(6,1))
324
+ dump(TxIParallelCore())
325
+
326
+ t = Triangulation3()
327
+ (a,b) = t.newSimplices(2)
328
+ a.join(0, a, Perm4(0,1))
329
+ b.join(0, b, Perm4(0,1))
330
+ a.join(2, b, Perm4(2,3))
331
+ a.join(3, b, Perm4(2,3))
332
+ dump(SnappedBall.recognise(b))
333
+ dump(SnappedTwoSphere.recognise(a, b))
334
+
335
+ t = Triangulation3()
336
+ (a,b,c,d) = t.newSimplices(4)
337
+ for i in [1,2,3]:
338
+ c.join(i, d, Perm4())
339
+ a.join(i, b, Perm4())
340
+ a.join(0, c, Perm4())
341
+ b.join(0, d, Perm4())
342
+ dump(PillowTwoSphere.recognise(a.triangle(0), b.triangle(0)))
343
+
344
+ dump(SatCube.model())
345
+
346
+ t = Example3.sfsOverSphere(3,4,5,1,2,-1)
347
+ s = BlockedSFS.recognise(t)
348
+ dump(s)
349
+ dump(s.region())
350
+ dump(s.region().block(0))
351
+ dump(s.region().block(0).block())
352
+ dump(s.region().block(0).block().annulus(0))
353
+
354
+ dump(BlockedSFSLoop.recognise(Triangulation3('kLLLLPQkcddfjgihjijpkrkaspoadj')))
355
+ dump(BlockedSFSPair.recognise(Triangulation3('hLAvQkbccefggglpksulwb')))
356
+ dump(BlockedSFSTriple.recognise(Triangulation3('kLALALMkbccfefihijjlpkusuueotr')))
357
+ dump(PluggedTorusBundle.recognise(Triangulation3('kLLvAPQkbdfehgjiijjdwuurwmmaxn')))
358
+ dump(TrivialTri.recognise(Triangulation3('cPcbbbaai').component(0)))
359
+ dump(LayeredLoop.recognise(Triangulation3('cPcbbbqxh').component(0)))
360
+ dump(LayeredTorusBundle.recognise(Triangulation3('hvLPQkcedgffggnnkaaeiw')))
361
+ dump(PlugTriSolidTorus.recognise(Example3.poincare().component(0)))
362
+ dump(TrivialTri.recognise(Example3.rp2xs1().component(0)))
363
+
364
+ t = Example3.sfsOverSphere(3,4,5,1,2,-1)
365
+ a = AugTriSolidTorus.recognise(t.component(0))
366
+ dump(a)
367
+ dump(a.core())
368
+
369
+ l = Example3.lens(8,3)
370
+ dump(LayeredLensSpace.recognise(l.component(0)))
371
+ dump(LayeredSolidTorus.recogniseFromBase(l.tetrahedron(0)))
372
+ dump(LayeredSolidTorus.recogniseFromBase(l.tetrahedron(l.size()-1)))
373
+
374
+ y = Layering(l.tetrahedron(0), Perm4(2,3,0,1), l.tetrahedron(0), Perm4(3,2,1,0))
375
+ dump(y)
376
+ y.extend()
377
+ dump(y)
378
+
379
+ t = Triangulation3('kLLLMAMkcegfhhhijjjhqhaqjshhrw')
380
+ l = LayeredChainPair.recognise(t.component(0))
381
+ dump(l)
382
+ dump(l.chain(0))
383
+ dump(SpiralSolidTorus.recognise(l.chain(0).top(), l.chain(0).topVertexRoles()))
384
+
385
+ # ----------------------------------------------------------------------
386
+ # census/
387
+ # ----------------------------------------------------------------------
388
+
389
+ h = Census.lookup('cPcbbbiht')[0]
390
+ dump(h)
391
+ # Do not dump the CensusDB object, since the output is filesystem-dependent.
392
+ # dump(h.db())
393
+
394
+ p = FacetPairing2(Example2.annulus())
395
+ isos = p.findAutomorphisms()
396
+ dump(GluingPermSearcher2(p, isos, True))
397
+
398
+ p = FacetPairing3(Example3.sfsOverSphere(3,4,5,1,2,-1))
399
+ isos = p.findAutomorphisms()
400
+ dump(GluingPermSearcher3(p, isos, True, False, CensusPurge.NonMinimal))
401
+ dump(CompactSearcher(p, isos, True, CensusPurge.NonMinimal))
402
+ dump(HyperbolicMinSearcher(p, isos, True))
403
+ dump(EulerSearcher(-2, p, isos, False, CensusPurge.Nil))
404
+ dump(ClosedPrimeMinSearcher(p, isos, True))
405
+
406
+ p = FacetPairing4(Example4.s3xs1())
407
+ isos = p.findAutomorphisms()
408
+ dump(GluingPermSearcher4(p, isos, False, True))
409
+
410
+ # ----------------------------------------------------------------------
411
+ # enumerate/
412
+ # ----------------------------------------------------------------------
413
+
414
+ dump(TypeTrie4())
415
+ dump(TypeTrie7())
416
+
417
+ t = Example3.figureEight()
418
+ tab = LPInitialTableaux_NonSpun(t, NormalCoords.Quad)
419
+ dump(tab)
420
+ m = LPMatrix(tab.rank(), tab.columns())
421
+ tab.fillInitialTableaux(m)
422
+ dump(m)
423
+ dat = LPData_NonSpun()
424
+ dump(dat)
425
+ dat.reserve(tab)
426
+ dat.initStart()
427
+ dump(dat)
428
+
429
+ dump(makeEmbeddedConstraints(t, NormalCoords.Standard));
430
+ dump(makeEmbeddedConstraints(t, NormalCoords.QuadOct));
431
+
432
+ t = Example3.lst(3,4)
433
+ tab = LPInitialTableaux(t, NormalCoords.Standard)
434
+ dump(BanNone(tab))
435
+ dump(BanBoundary(tab))
436
+ dump(BanTorusBoundary(tab))
437
+
438
+ dump(PosOrder(MatrixInt.identity(3)))
439
+
440
+ # ----------------------------------------------------------------------
441
+ # treewidth/
442
+ # ----------------------------------------------------------------------
443
+
444
+ t = TreeDecomposition(ExampleLink.conway())
445
+ dump(t)
446
+ dump(t.bag(0))
447
+
448
+ # ----------------------------------------------------------------------
449
+ # split/
450
+ # ----------------------------------------------------------------------
451
+
452
+ dump(Signature('abbc.ac'))
453
+
454
+ # ----------------------------------------------------------------------
455
+ # file/
456
+ # ----------------------------------------------------------------------
457
+
458
+ dump(FileInfo.identify(testpath + '/file3.rga'))
459
+ dump(FileInfo.identify(testpath + '/pdf.test'))
460
+
461
+ # ----------------------------------------------------------------------
462
+ # progress/
463
+ # ----------------------------------------------------------------------
464
+
465
+ p = ProgressTrackerOpen()
466
+ dump(p)
467
+ p.newStage('Doing stuff')
468
+ p.incSteps(3)
469
+ dump(p)
470
+ p.setFinished()
471
+ dump(p)
472
+
473
+ p = ProgressTracker()
474
+ dump(p)
475
+ p.newStage('Doing stuff', 1)
476
+ p.setPercent(5.87)
477
+ dump(p)
478
+ p.setPercent(75.87)
479
+ dump(p)
480
+ p.cancel()
481
+ dump(p)
482
+
483
+ # ----------------------------------------------------------------------
484
+ # packet/
485
+ # ----------------------------------------------------------------------
486
+
487
+ c = Container()
488
+ t = Text('Hello world!')
489
+ t.setLabel('Welcome')
490
+ c.append(t)
491
+ a = Attachment(b'foo', 'test.txt')
492
+ t.append(a)
493
+ s = Script()
494
+ s.setText('print("Hello world!")\nprint(0)')
495
+ s.addVariable('text', t)
496
+ s.addVariable('dummy', None)
497
+ t.append(s)
498
+ dump(c)
499
+ dump(t)
500
+ dump(a)
501
+ dump(s)
502
+
503
+ # Do not dump PacketShell objects, since they write internal IDs which
504
+ # are not consistent between runs.
505
+ #
506
+ # dump(PacketShell(s))
507
+ # dump(PacketShell(t))
508
+
509
+ # ----------------------------------------------------------------------
510
+ # Classes that require us to use callbacks for non-trivial access:
511
+ # ----------------------------------------------------------------------
512
+
513
+ def foundGluings2(g):
514
+ dump(g)
515
+
516
+ def foundPairing2(p, isos):
517
+ GluingPermSearcher2.findAllPerms(p, isos, True, foundGluings2)
518
+
519
+ FacetPairing2.findAllPairings(2, False, 0, foundPairing2)
520
+
521
+ def processSig(s, autos):
522
+ print(s)
523
+ dump(autos[-1])
524
+
525
+ SigCensus.formCensus(2, processSig)
526
+
527
+ t = Example3.rp3rp3()
528
+ tree = TreeSingleSoln_EulerPositive(t, NormalCoords.Standard)
529
+ dump(tree)
530
+ tree.find()
531
+ dump(tree)
532
+
533
+ t = Example3.figureEight()
534
+ tree = TautEnumeration(t)
535
+ tree.run(dump)
536
+
537
+ t = Example3.figureEight()
538
+ tree = TreeEnumeration(t, NormalCoords.Quad)
539
+ tree.run(dump)
540
+
541
+ t = Example3.trefoil()
542
+ tree = TreeEnumeration_NonSpun(t, NormalCoords.Quad)
543
+ tree.run(dump)
544
+
545
+ dump(Perm8.Sn)
546
+
@@ -0,0 +1,75 @@
1
+ #!/bin/bash
2
+ #
3
+ # Regina - A Normal Surface Theory Calculator
4
+ # Python Test Suite
5
+ #
6
+ # Copyright (c) 2007-2025, Ben Burton
7
+ # For further details contact Ben Burton (bab@debian.org).
8
+ #
9
+ # Usage: runbasic
10
+ #
11
+ # Runs the stripped-down basic Python interpreter, with all necessary paths
12
+ # set in the environment.
13
+ #
14
+ # In most cases nobody should need this script. It is provided mainly to help
15
+ # debug Python issues that arise when using an embedded interpreter.
16
+ #
17
+ # This script runs everything directly out of the build tree.
18
+ # It does not require regina to be installed on the system (and indeed
19
+ # it ignores any installation that it might find).
20
+ #
21
+ # This program is free software; you can redistribute it and/or
22
+ # modify it under the terms of the GNU General Public License as
23
+ # published by the Free Software Foundation; either version 2 of the
24
+ # License, or (at your option) any later version.
25
+ #
26
+ # As an exception, when this program is distributed through (i) the
27
+ # App Store by Apple Inc.; (ii) the Mac App Store by Apple Inc.; or
28
+ # (iii) Google Play by Google Inc., then that store may impose any
29
+ # digital rights management, device limits and/or redistribution
30
+ # restrictions that are required by its terms of service.
31
+ #
32
+ # This program is distributed in the hope that it will be useful, but
33
+ # WITHOUT ANY WARRANTY; without even the implied warranty of
34
+ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
35
+ # General Public License for more details.
36
+ #
37
+ # You should have received a copy of the GNU General Public License
38
+ # along with this program. If not, see <https://www.gnu.org/licenses/>.
39
+
40
+ set -e
41
+
42
+ path="`dirname "$0"`"
43
+ executable="$path/basic"
44
+
45
+ # Make sure Python will be able to import regina.
46
+ os='@CMAKE_SYSTEM_NAME@'
47
+ case "$os" in
48
+ Darwin )
49
+ export DYLD_LIBRARY_PATH="$path/../../engine:$DYLD_LIBRARY_PATH"
50
+ export PYTHONPATH="$path/..:$PYTHONPATH"
51
+ ;;
52
+ Windows )
53
+ # The PYTHONHOME directory is incorrectly hard-coded in msys2.
54
+ # Work out the correct value by asking the python interpreter directly.
55
+ PYTHON='@BASH_Python_EXECUTABLE@'
56
+ if [ ! -e "$PYTHON" ]; then
57
+ echo "ERROR: Python interpreter not found: $PYTHON"
58
+ exit 1
59
+ fi
60
+ export PYTHONHOME="`"$PYTHON" -c 'import sys; print(sys.prefix)'`"
61
+ if [ ! -d "$PYTHONHOME" ]; then
62
+ echo "ERROR: Python home not found: $PYTHONHOME"
63
+ exit 1
64
+ fi
65
+
66
+ export PATH="$path/../../engine:$PATH"
67
+ export PYTHONPATH="$path/..;$PYTHONPATH"
68
+ ;;
69
+ * )
70
+ export LD_LIBRARY_PATH="$path/../../engine:$LD_LIBRARY_PATH"
71
+ export PYTHONPATH="$path/..:$PYTHONPATH"
72
+ ;;
73
+ esac
74
+
75
+ "$executable" "$@"
@@ -0,0 +1,17 @@
1
+ Constructor:
2
+ Empty container
3
+ Deleting parent:
4
+ Empty container
5
+ Deleting matriarch:
6
+ Container with 1 child, 1 descendant
7
+ Empty container
8
+ Multiple references:
9
+ Container with 1 child, 2 descendants
10
+ Container with 1 child, 1 descendant
11
+ Empty container
12
+ Container with 1 child, 2 descendants
13
+ Empty container
14
+ Empty container
15
+ Empty container
16
+ Empty container
17
+ Empty container