passagemath-categories 10.6.32__cp314-cp314t-musllinux_1_2_aarch64.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 (719) hide show
  1. passagemath_categories-10.6.32.dist-info/METADATA +156 -0
  2. passagemath_categories-10.6.32.dist-info/RECORD +719 -0
  3. passagemath_categories-10.6.32.dist-info/WHEEL +5 -0
  4. passagemath_categories-10.6.32.dist-info/top_level.txt +2 -0
  5. passagemath_categories.libs/libgcc_s-2d945d6c.so.1 +0 -0
  6. passagemath_categories.libs/libgmp-28992bcb.so.10.5.0 +0 -0
  7. passagemath_categories.libs/libstdc++-85f2cd6d.so.6.0.33 +0 -0
  8. sage/all__sagemath_categories.py +28 -0
  9. sage/arith/all.py +38 -0
  10. sage/arith/constants.pxd +27 -0
  11. sage/arith/functions.cpython-314t-aarch64-linux-musl.so +0 -0
  12. sage/arith/functions.pxd +4 -0
  13. sage/arith/functions.pyx +221 -0
  14. sage/arith/misc.py +6552 -0
  15. sage/arith/multi_modular.cpython-314t-aarch64-linux-musl.so +0 -0
  16. sage/arith/multi_modular.pxd +39 -0
  17. sage/arith/multi_modular.pyx +994 -0
  18. sage/arith/rational_reconstruction.cpython-314t-aarch64-linux-musl.so +0 -0
  19. sage/arith/rational_reconstruction.pxd +4 -0
  20. sage/arith/rational_reconstruction.pyx +115 -0
  21. sage/arith/srange.cpython-314t-aarch64-linux-musl.so +0 -0
  22. sage/arith/srange.pyx +571 -0
  23. sage/calculus/all__sagemath_categories.py +2 -0
  24. sage/calculus/functional.py +481 -0
  25. sage/calculus/functions.py +151 -0
  26. sage/categories/additive_groups.py +73 -0
  27. sage/categories/additive_magmas.py +1044 -0
  28. sage/categories/additive_monoids.py +114 -0
  29. sage/categories/additive_semigroups.py +184 -0
  30. sage/categories/affine_weyl_groups.py +238 -0
  31. sage/categories/algebra_ideals.py +95 -0
  32. sage/categories/algebra_modules.py +96 -0
  33. sage/categories/algebras.py +349 -0
  34. sage/categories/algebras_with_basis.py +377 -0
  35. sage/categories/all.py +160 -0
  36. sage/categories/aperiodic_semigroups.py +29 -0
  37. sage/categories/associative_algebras.py +47 -0
  38. sage/categories/bialgebras.py +101 -0
  39. sage/categories/bialgebras_with_basis.py +414 -0
  40. sage/categories/bimodules.py +206 -0
  41. sage/categories/chain_complexes.py +268 -0
  42. sage/categories/classical_crystals.py +480 -0
  43. sage/categories/coalgebras.py +405 -0
  44. sage/categories/coalgebras_with_basis.py +232 -0
  45. sage/categories/coercion_methods.cpython-314t-aarch64-linux-musl.so +0 -0
  46. sage/categories/coercion_methods.pyx +52 -0
  47. sage/categories/commutative_additive_groups.py +104 -0
  48. sage/categories/commutative_additive_monoids.py +45 -0
  49. sage/categories/commutative_additive_semigroups.py +48 -0
  50. sage/categories/commutative_algebra_ideals.py +87 -0
  51. sage/categories/commutative_algebras.py +94 -0
  52. sage/categories/commutative_ring_ideals.py +58 -0
  53. sage/categories/commutative_rings.py +736 -0
  54. sage/categories/complete_discrete_valuation.py +293 -0
  55. sage/categories/complex_reflection_groups.py +145 -0
  56. sage/categories/complex_reflection_or_generalized_coxeter_groups.py +1249 -0
  57. sage/categories/coxeter_group_algebras.py +186 -0
  58. sage/categories/coxeter_groups.py +3402 -0
  59. sage/categories/crystals.py +2628 -0
  60. sage/categories/cw_complexes.py +216 -0
  61. sage/categories/dedekind_domains.py +137 -0
  62. sage/categories/discrete_valuation.py +325 -0
  63. sage/categories/distributive_magmas_and_additive_magmas.py +100 -0
  64. sage/categories/division_rings.py +114 -0
  65. sage/categories/domains.py +95 -0
  66. sage/categories/drinfeld_modules.py +789 -0
  67. sage/categories/dual.py +42 -0
  68. sage/categories/enumerated_sets.py +1146 -0
  69. sage/categories/euclidean_domains.py +271 -0
  70. sage/categories/examples/algebras_with_basis.py +102 -0
  71. sage/categories/examples/all.py +1 -0
  72. sage/categories/examples/commutative_additive_monoids.py +130 -0
  73. sage/categories/examples/commutative_additive_semigroups.py +199 -0
  74. sage/categories/examples/coxeter_groups.py +8 -0
  75. sage/categories/examples/crystals.py +236 -0
  76. sage/categories/examples/cw_complexes.py +163 -0
  77. sage/categories/examples/facade_sets.py +187 -0
  78. sage/categories/examples/filtered_algebras_with_basis.py +204 -0
  79. sage/categories/examples/filtered_modules_with_basis.py +154 -0
  80. sage/categories/examples/finite_coxeter_groups.py +252 -0
  81. sage/categories/examples/finite_dimensional_algebras_with_basis.py +148 -0
  82. sage/categories/examples/finite_dimensional_lie_algebras_with_basis.py +495 -0
  83. sage/categories/examples/finite_enumerated_sets.py +208 -0
  84. sage/categories/examples/finite_monoids.py +150 -0
  85. sage/categories/examples/finite_semigroups.py +190 -0
  86. sage/categories/examples/finite_weyl_groups.py +191 -0
  87. sage/categories/examples/graded_connected_hopf_algebras_with_basis.py +152 -0
  88. sage/categories/examples/graded_modules_with_basis.py +168 -0
  89. sage/categories/examples/graphs.py +122 -0
  90. sage/categories/examples/hopf_algebras_with_basis.py +145 -0
  91. sage/categories/examples/infinite_enumerated_sets.py +190 -0
  92. sage/categories/examples/lie_algebras.py +352 -0
  93. sage/categories/examples/lie_algebras_with_basis.py +196 -0
  94. sage/categories/examples/magmas.py +162 -0
  95. sage/categories/examples/manifolds.py +94 -0
  96. sage/categories/examples/monoids.py +144 -0
  97. sage/categories/examples/posets.py +178 -0
  98. sage/categories/examples/semigroups.py +580 -0
  99. sage/categories/examples/semigroups_cython.cpython-314t-aarch64-linux-musl.so +0 -0
  100. sage/categories/examples/semigroups_cython.pyx +221 -0
  101. sage/categories/examples/semirings.py +249 -0
  102. sage/categories/examples/sets_cat.py +706 -0
  103. sage/categories/examples/sets_with_grading.py +101 -0
  104. sage/categories/examples/with_realizations.py +542 -0
  105. sage/categories/fields.py +991 -0
  106. sage/categories/filtered_algebras.py +63 -0
  107. sage/categories/filtered_algebras_with_basis.py +548 -0
  108. sage/categories/filtered_hopf_algebras_with_basis.py +138 -0
  109. sage/categories/filtered_modules.py +210 -0
  110. sage/categories/filtered_modules_with_basis.py +1209 -0
  111. sage/categories/finite_complex_reflection_groups.py +1506 -0
  112. sage/categories/finite_coxeter_groups.py +1138 -0
  113. sage/categories/finite_crystals.py +103 -0
  114. sage/categories/finite_dimensional_algebras_with_basis.py +1860 -0
  115. sage/categories/finite_dimensional_bialgebras_with_basis.py +33 -0
  116. sage/categories/finite_dimensional_coalgebras_with_basis.py +33 -0
  117. sage/categories/finite_dimensional_graded_lie_algebras_with_basis.py +231 -0
  118. sage/categories/finite_dimensional_hopf_algebras_with_basis.py +38 -0
  119. sage/categories/finite_dimensional_lie_algebras_with_basis.py +2774 -0
  120. sage/categories/finite_dimensional_modules_with_basis.py +1407 -0
  121. sage/categories/finite_dimensional_nilpotent_lie_algebras_with_basis.py +167 -0
  122. sage/categories/finite_dimensional_semisimple_algebras_with_basis.py +270 -0
  123. sage/categories/finite_enumerated_sets.py +769 -0
  124. sage/categories/finite_fields.py +252 -0
  125. sage/categories/finite_groups.py +256 -0
  126. sage/categories/finite_lattice_posets.py +242 -0
  127. sage/categories/finite_monoids.py +316 -0
  128. sage/categories/finite_permutation_groups.py +339 -0
  129. sage/categories/finite_posets.py +1994 -0
  130. sage/categories/finite_semigroups.py +136 -0
  131. sage/categories/finite_sets.py +93 -0
  132. sage/categories/finite_weyl_groups.py +39 -0
  133. sage/categories/finitely_generated_lambda_bracket_algebras.py +112 -0
  134. sage/categories/finitely_generated_lie_conformal_algebras.py +114 -0
  135. sage/categories/finitely_generated_magmas.py +57 -0
  136. sage/categories/finitely_generated_semigroups.py +214 -0
  137. sage/categories/function_fields.py +76 -0
  138. sage/categories/g_sets.py +77 -0
  139. sage/categories/gcd_domains.py +65 -0
  140. sage/categories/generalized_coxeter_groups.py +94 -0
  141. sage/categories/graded_algebras.py +85 -0
  142. sage/categories/graded_algebras_with_basis.py +258 -0
  143. sage/categories/graded_bialgebras.py +32 -0
  144. sage/categories/graded_bialgebras_with_basis.py +32 -0
  145. sage/categories/graded_coalgebras.py +65 -0
  146. sage/categories/graded_coalgebras_with_basis.py +51 -0
  147. sage/categories/graded_hopf_algebras.py +41 -0
  148. sage/categories/graded_hopf_algebras_with_basis.py +169 -0
  149. sage/categories/graded_lie_algebras.py +91 -0
  150. sage/categories/graded_lie_algebras_with_basis.py +44 -0
  151. sage/categories/graded_lie_conformal_algebras.py +74 -0
  152. sage/categories/graded_modules.py +133 -0
  153. sage/categories/graded_modules_with_basis.py +329 -0
  154. sage/categories/graphs.py +138 -0
  155. sage/categories/group_algebras.py +430 -0
  156. sage/categories/groupoid.py +94 -0
  157. sage/categories/groups.py +667 -0
  158. sage/categories/h_trivial_semigroups.py +64 -0
  159. sage/categories/hecke_modules.py +185 -0
  160. sage/categories/highest_weight_crystals.py +980 -0
  161. sage/categories/hopf_algebras.py +219 -0
  162. sage/categories/hopf_algebras_with_basis.py +309 -0
  163. sage/categories/infinite_enumerated_sets.py +115 -0
  164. sage/categories/integral_domains.py +203 -0
  165. sage/categories/j_trivial_semigroups.py +29 -0
  166. sage/categories/kac_moody_algebras.py +82 -0
  167. sage/categories/kahler_algebras.py +203 -0
  168. sage/categories/l_trivial_semigroups.py +63 -0
  169. sage/categories/lambda_bracket_algebras.py +280 -0
  170. sage/categories/lambda_bracket_algebras_with_basis.py +107 -0
  171. sage/categories/lattice_posets.py +89 -0
  172. sage/categories/left_modules.py +49 -0
  173. sage/categories/lie_algebras.py +1070 -0
  174. sage/categories/lie_algebras_with_basis.py +261 -0
  175. sage/categories/lie_conformal_algebras.py +350 -0
  176. sage/categories/lie_conformal_algebras_with_basis.py +147 -0
  177. sage/categories/lie_groups.py +73 -0
  178. sage/categories/loop_crystals.py +1290 -0
  179. sage/categories/magmas.py +1189 -0
  180. sage/categories/magmas_and_additive_magmas.py +149 -0
  181. sage/categories/magmatic_algebras.py +365 -0
  182. sage/categories/manifolds.py +352 -0
  183. sage/categories/matrix_algebras.py +40 -0
  184. sage/categories/metric_spaces.py +387 -0
  185. sage/categories/modular_abelian_varieties.py +78 -0
  186. sage/categories/modules.py +989 -0
  187. sage/categories/modules_with_basis.py +2794 -0
  188. sage/categories/monoid_algebras.py +38 -0
  189. sage/categories/monoids.py +739 -0
  190. sage/categories/noetherian_rings.py +87 -0
  191. sage/categories/number_fields.py +242 -0
  192. sage/categories/ore_modules.py +189 -0
  193. sage/categories/partially_ordered_monoids.py +49 -0
  194. sage/categories/permutation_groups.py +63 -0
  195. sage/categories/pointed_sets.py +42 -0
  196. sage/categories/polyhedra.py +74 -0
  197. sage/categories/poor_man_map.py +270 -0
  198. sage/categories/posets.py +722 -0
  199. sage/categories/principal_ideal_domains.py +270 -0
  200. sage/categories/quantum_group_representations.py +543 -0
  201. sage/categories/quotient_fields.py +728 -0
  202. sage/categories/r_trivial_semigroups.py +45 -0
  203. sage/categories/regular_crystals.py +898 -0
  204. sage/categories/regular_supercrystals.py +170 -0
  205. sage/categories/right_modules.py +49 -0
  206. sage/categories/ring_ideals.py +74 -0
  207. sage/categories/rings.py +1904 -0
  208. sage/categories/rngs.py +175 -0
  209. sage/categories/schemes.py +393 -0
  210. sage/categories/semigroups.py +1060 -0
  211. sage/categories/semirings.py +71 -0
  212. sage/categories/semisimple_algebras.py +114 -0
  213. sage/categories/sets_with_grading.py +235 -0
  214. sage/categories/shephard_groups.py +43 -0
  215. sage/categories/signed_tensor.py +120 -0
  216. sage/categories/simplicial_complexes.py +134 -0
  217. sage/categories/simplicial_sets.py +1206 -0
  218. sage/categories/super_algebras.py +149 -0
  219. sage/categories/super_algebras_with_basis.py +144 -0
  220. sage/categories/super_hopf_algebras_with_basis.py +126 -0
  221. sage/categories/super_lie_conformal_algebras.py +193 -0
  222. sage/categories/super_modules.py +229 -0
  223. sage/categories/super_modules_with_basis.py +193 -0
  224. sage/categories/supercommutative_algebras.py +99 -0
  225. sage/categories/supercrystals.py +406 -0
  226. sage/categories/tensor.py +110 -0
  227. sage/categories/topological_spaces.py +170 -0
  228. sage/categories/triangular_kac_moody_algebras.py +439 -0
  229. sage/categories/tutorial.py +58 -0
  230. sage/categories/unique_factorization_domains.py +318 -0
  231. sage/categories/unital_algebras.py +426 -0
  232. sage/categories/vector_bundles.py +159 -0
  233. sage/categories/vector_spaces.py +357 -0
  234. sage/categories/weyl_groups.py +853 -0
  235. sage/combinat/all__sagemath_categories.py +34 -0
  236. sage/combinat/backtrack.py +180 -0
  237. sage/combinat/combinat.py +2269 -0
  238. sage/combinat/combinat_cython.cpython-314t-aarch64-linux-musl.so +0 -0
  239. sage/combinat/combinat_cython.pxd +6 -0
  240. sage/combinat/combinat_cython.pyx +390 -0
  241. sage/combinat/combination.py +796 -0
  242. sage/combinat/combinatorial_map.py +416 -0
  243. sage/combinat/composition.py +2192 -0
  244. sage/combinat/dlx.py +510 -0
  245. sage/combinat/integer_lists/__init__.py +7 -0
  246. sage/combinat/integer_lists/base.cpython-314t-aarch64-linux-musl.so +0 -0
  247. sage/combinat/integer_lists/base.pxd +16 -0
  248. sage/combinat/integer_lists/base.pyx +713 -0
  249. sage/combinat/integer_lists/invlex.cpython-314t-aarch64-linux-musl.so +0 -0
  250. sage/combinat/integer_lists/invlex.pxd +4 -0
  251. sage/combinat/integer_lists/invlex.pyx +1650 -0
  252. sage/combinat/integer_lists/lists.py +328 -0
  253. sage/combinat/integer_lists/nn.py +48 -0
  254. sage/combinat/integer_vector.py +1818 -0
  255. sage/combinat/integer_vector_weighted.py +413 -0
  256. sage/combinat/matrices/all__sagemath_categories.py +5 -0
  257. sage/combinat/matrices/dancing_links.cpython-314t-aarch64-linux-musl.so +0 -0
  258. sage/combinat/matrices/dancing_links.pyx +1159 -0
  259. sage/combinat/matrices/dancing_links_c.h +380 -0
  260. sage/combinat/matrices/dlxcpp.py +136 -0
  261. sage/combinat/partition.py +10070 -0
  262. sage/combinat/partitions.cpython-314t-aarch64-linux-musl.so +0 -0
  263. sage/combinat/partitions.pyx +743 -0
  264. sage/combinat/permutation.py +10168 -0
  265. sage/combinat/permutation_cython.cpython-314t-aarch64-linux-musl.so +0 -0
  266. sage/combinat/permutation_cython.pxd +11 -0
  267. sage/combinat/permutation_cython.pyx +407 -0
  268. sage/combinat/q_analogues.py +1090 -0
  269. sage/combinat/ranker.py +268 -0
  270. sage/combinat/subset.py +1561 -0
  271. sage/combinat/subsets_hereditary.py +202 -0
  272. sage/combinat/subsets_pairwise.py +184 -0
  273. sage/combinat/tools.py +63 -0
  274. sage/combinat/tuple.py +348 -0
  275. sage/data_structures/all.py +2 -0
  276. sage/data_structures/all__sagemath_categories.py +2 -0
  277. sage/data_structures/binary_matrix.pxd +138 -0
  278. sage/data_structures/binary_search.cpython-314t-aarch64-linux-musl.so +0 -0
  279. sage/data_structures/binary_search.pxd +3 -0
  280. sage/data_structures/binary_search.pyx +66 -0
  281. sage/data_structures/bitset.cpython-314t-aarch64-linux-musl.so +0 -0
  282. sage/data_structures/bitset.pxd +40 -0
  283. sage/data_structures/bitset.pyx +2385 -0
  284. sage/data_structures/bitset_base.cpython-314t-aarch64-linux-musl.so +0 -0
  285. sage/data_structures/bitset_base.pxd +926 -0
  286. sage/data_structures/bitset_base.pyx +117 -0
  287. sage/data_structures/bitset_intrinsics.h +487 -0
  288. sage/data_structures/blas_dict.cpython-314t-aarch64-linux-musl.so +0 -0
  289. sage/data_structures/blas_dict.pxd +12 -0
  290. sage/data_structures/blas_dict.pyx +469 -0
  291. sage/data_structures/list_of_pairs.cpython-314t-aarch64-linux-musl.so +0 -0
  292. sage/data_structures/list_of_pairs.pxd +16 -0
  293. sage/data_structures/list_of_pairs.pyx +122 -0
  294. sage/data_structures/mutable_poset.py +3312 -0
  295. sage/data_structures/pairing_heap.cpython-314t-aarch64-linux-musl.so +0 -0
  296. sage/data_structures/pairing_heap.h +346 -0
  297. sage/data_structures/pairing_heap.pxd +88 -0
  298. sage/data_structures/pairing_heap.pyx +1464 -0
  299. sage/data_structures/sparse_bitset.pxd +62 -0
  300. sage/data_structures/stream.py +5070 -0
  301. sage/databases/all__sagemath_categories.py +7 -0
  302. sage/databases/sql_db.py +2236 -0
  303. sage/ext/all__sagemath_categories.py +3 -0
  304. sage/ext/fast_callable.cpython-314t-aarch64-linux-musl.so +0 -0
  305. sage/ext/fast_callable.pxd +4 -0
  306. sage/ext/fast_callable.pyx +2746 -0
  307. sage/ext/fast_eval.cpython-314t-aarch64-linux-musl.so +0 -0
  308. sage/ext/fast_eval.pxd +1 -0
  309. sage/ext/fast_eval.pyx +102 -0
  310. sage/ext/interpreters/__init__.py +1 -0
  311. sage/ext/interpreters/all__sagemath_categories.py +2 -0
  312. sage/ext/interpreters/wrapper_el.cpython-314t-aarch64-linux-musl.so +0 -0
  313. sage/ext/interpreters/wrapper_el.pxd +18 -0
  314. sage/ext/interpreters/wrapper_el.pyx +148 -0
  315. sage/ext/interpreters/wrapper_py.cpython-314t-aarch64-linux-musl.so +0 -0
  316. sage/ext/interpreters/wrapper_py.pxd +17 -0
  317. sage/ext/interpreters/wrapper_py.pyx +133 -0
  318. sage/functions/airy.py +937 -0
  319. sage/functions/all.py +97 -0
  320. sage/functions/bessel.py +2102 -0
  321. sage/functions/error.py +784 -0
  322. sage/functions/exp_integral.py +1529 -0
  323. sage/functions/gamma.py +1087 -0
  324. sage/functions/generalized.py +672 -0
  325. sage/functions/hyperbolic.py +747 -0
  326. sage/functions/hypergeometric.py +1156 -0
  327. sage/functions/jacobi.py +1705 -0
  328. sage/functions/log.py +1402 -0
  329. sage/functions/min_max.py +338 -0
  330. sage/functions/orthogonal_polys.py +3106 -0
  331. sage/functions/other.py +2303 -0
  332. sage/functions/piecewise.py +1505 -0
  333. sage/functions/prime_pi.cpython-314t-aarch64-linux-musl.so +0 -0
  334. sage/functions/prime_pi.pyx +262 -0
  335. sage/functions/special.py +1212 -0
  336. sage/functions/spike_function.py +278 -0
  337. sage/functions/transcendental.py +690 -0
  338. sage/functions/trig.py +1062 -0
  339. sage/functions/wigner.py +726 -0
  340. sage/geometry/abc.cpython-314t-aarch64-linux-musl.so +0 -0
  341. sage/geometry/abc.pyx +82 -0
  342. sage/geometry/all__sagemath_categories.py +1 -0
  343. sage/groups/all__sagemath_categories.py +11 -0
  344. sage/groups/generic.py +1733 -0
  345. sage/groups/groups_catalog.py +113 -0
  346. sage/groups/perm_gps/all__sagemath_categories.py +1 -0
  347. sage/groups/perm_gps/partn_ref/all.py +1 -0
  348. sage/groups/perm_gps/partn_ref/all__sagemath_categories.py +1 -0
  349. sage/groups/perm_gps/partn_ref/automorphism_group_canonical_label.cpython-314t-aarch64-linux-musl.so +0 -0
  350. sage/groups/perm_gps/partn_ref/automorphism_group_canonical_label.pxd +52 -0
  351. sage/groups/perm_gps/partn_ref/automorphism_group_canonical_label.pyx +906 -0
  352. sage/groups/perm_gps/partn_ref/canonical_augmentation.cpython-314t-aarch64-linux-musl.so +0 -0
  353. sage/groups/perm_gps/partn_ref/canonical_augmentation.pxd +85 -0
  354. sage/groups/perm_gps/partn_ref/canonical_augmentation.pyx +534 -0
  355. sage/groups/perm_gps/partn_ref/data_structures.cpython-314t-aarch64-linux-musl.so +0 -0
  356. sage/groups/perm_gps/partn_ref/data_structures.pxd +576 -0
  357. sage/groups/perm_gps/partn_ref/data_structures.pyx +1792 -0
  358. sage/groups/perm_gps/partn_ref/double_coset.cpython-314t-aarch64-linux-musl.so +0 -0
  359. sage/groups/perm_gps/partn_ref/double_coset.pxd +45 -0
  360. sage/groups/perm_gps/partn_ref/double_coset.pyx +739 -0
  361. sage/groups/perm_gps/partn_ref/refinement_lists.cpython-314t-aarch64-linux-musl.so +0 -0
  362. sage/groups/perm_gps/partn_ref/refinement_lists.pxd +18 -0
  363. sage/groups/perm_gps/partn_ref/refinement_lists.pyx +82 -0
  364. sage/groups/perm_gps/partn_ref/refinement_python.cpython-314t-aarch64-linux-musl.so +0 -0
  365. sage/groups/perm_gps/partn_ref/refinement_python.pxd +16 -0
  366. sage/groups/perm_gps/partn_ref/refinement_python.pyx +564 -0
  367. sage/groups/perm_gps/partn_ref/refinement_sets.cpython-314t-aarch64-linux-musl.so +0 -0
  368. sage/groups/perm_gps/partn_ref/refinement_sets.pxd +60 -0
  369. sage/groups/perm_gps/partn_ref/refinement_sets.pyx +858 -0
  370. sage/interfaces/abc.py +140 -0
  371. sage/interfaces/all.py +58 -0
  372. sage/interfaces/all__sagemath_categories.py +1 -0
  373. sage/interfaces/expect.py +1643 -0
  374. sage/interfaces/interface.py +1682 -0
  375. sage/interfaces/process.cpython-314t-aarch64-linux-musl.so +0 -0
  376. sage/interfaces/process.pxd +5 -0
  377. sage/interfaces/process.pyx +288 -0
  378. sage/interfaces/quit.py +167 -0
  379. sage/interfaces/sage0.py +604 -0
  380. sage/interfaces/sagespawn.cpython-314t-aarch64-linux-musl.so +0 -0
  381. sage/interfaces/sagespawn.pyx +308 -0
  382. sage/interfaces/tab_completion.py +101 -0
  383. sage/misc/all__sagemath_categories.py +78 -0
  384. sage/misc/allocator.cpython-314t-aarch64-linux-musl.so +0 -0
  385. sage/misc/allocator.pxd +6 -0
  386. sage/misc/allocator.pyx +47 -0
  387. sage/misc/binary_tree.cpython-314t-aarch64-linux-musl.so +0 -0
  388. sage/misc/binary_tree.pxd +29 -0
  389. sage/misc/binary_tree.pyx +537 -0
  390. sage/misc/callable_dict.cpython-314t-aarch64-linux-musl.so +0 -0
  391. sage/misc/callable_dict.pyx +89 -0
  392. sage/misc/citation.cpython-314t-aarch64-linux-musl.so +0 -0
  393. sage/misc/citation.pyx +159 -0
  394. sage/misc/converting_dict.py +293 -0
  395. sage/misc/defaults.py +129 -0
  396. sage/misc/derivative.cpython-314t-aarch64-linux-musl.so +0 -0
  397. sage/misc/derivative.pyx +223 -0
  398. sage/misc/functional.py +2005 -0
  399. sage/misc/html.py +589 -0
  400. sage/misc/latex.py +2673 -0
  401. sage/misc/latex_macros.py +236 -0
  402. sage/misc/latex_standalone.py +1833 -0
  403. sage/misc/map_threaded.py +38 -0
  404. sage/misc/mathml.py +76 -0
  405. sage/misc/method_decorator.py +88 -0
  406. sage/misc/mrange.py +755 -0
  407. sage/misc/multireplace.py +41 -0
  408. sage/misc/object_multiplexer.py +92 -0
  409. sage/misc/parser.cpython-314t-aarch64-linux-musl.so +0 -0
  410. sage/misc/parser.pyx +1107 -0
  411. sage/misc/random_testing.py +264 -0
  412. sage/misc/rest_index_of_methods.py +377 -0
  413. sage/misc/search.cpython-314t-aarch64-linux-musl.so +0 -0
  414. sage/misc/search.pxd +2 -0
  415. sage/misc/search.pyx +68 -0
  416. sage/misc/stopgap.cpython-314t-aarch64-linux-musl.so +0 -0
  417. sage/misc/stopgap.pyx +95 -0
  418. sage/misc/table.py +853 -0
  419. sage/monoids/all__sagemath_categories.py +1 -0
  420. sage/monoids/indexed_free_monoid.py +1071 -0
  421. sage/monoids/monoid.py +82 -0
  422. sage/numerical/all__sagemath_categories.py +1 -0
  423. sage/numerical/backends/all__sagemath_categories.py +1 -0
  424. sage/numerical/backends/generic_backend.cpython-314t-aarch64-linux-musl.so +0 -0
  425. sage/numerical/backends/generic_backend.pxd +61 -0
  426. sage/numerical/backends/generic_backend.pyx +1893 -0
  427. sage/numerical/backends/generic_sdp_backend.cpython-314t-aarch64-linux-musl.so +0 -0
  428. sage/numerical/backends/generic_sdp_backend.pxd +38 -0
  429. sage/numerical/backends/generic_sdp_backend.pyx +755 -0
  430. sage/parallel/all.py +6 -0
  431. sage/parallel/decorate.py +575 -0
  432. sage/parallel/map_reduce.py +1997 -0
  433. sage/parallel/multiprocessing_sage.py +76 -0
  434. sage/parallel/ncpus.py +35 -0
  435. sage/parallel/parallelism.py +364 -0
  436. sage/parallel/reference.py +47 -0
  437. sage/parallel/use_fork.py +333 -0
  438. sage/rings/abc.cpython-314t-aarch64-linux-musl.so +0 -0
  439. sage/rings/abc.pxd +31 -0
  440. sage/rings/abc.pyx +526 -0
  441. sage/rings/algebraic_closure_finite_field.py +1154 -0
  442. sage/rings/all__sagemath_categories.py +91 -0
  443. sage/rings/big_oh.py +227 -0
  444. sage/rings/continued_fraction.py +2754 -0
  445. sage/rings/continued_fraction_gosper.py +220 -0
  446. sage/rings/factorint.cpython-314t-aarch64-linux-musl.so +0 -0
  447. sage/rings/factorint.pyx +295 -0
  448. sage/rings/fast_arith.cpython-314t-aarch64-linux-musl.so +0 -0
  449. sage/rings/fast_arith.pxd +21 -0
  450. sage/rings/fast_arith.pyx +535 -0
  451. sage/rings/finite_rings/all__sagemath_categories.py +9 -0
  452. sage/rings/finite_rings/conway_polynomials.py +542 -0
  453. sage/rings/finite_rings/element_base.cpython-314t-aarch64-linux-musl.so +0 -0
  454. sage/rings/finite_rings/element_base.pxd +12 -0
  455. sage/rings/finite_rings/element_base.pyx +1176 -0
  456. sage/rings/finite_rings/finite_field_base.cpython-314t-aarch64-linux-musl.so +0 -0
  457. sage/rings/finite_rings/finite_field_base.pxd +7 -0
  458. sage/rings/finite_rings/finite_field_base.pyx +2171 -0
  459. sage/rings/finite_rings/finite_field_constructor.py +827 -0
  460. sage/rings/finite_rings/finite_field_prime_modn.py +372 -0
  461. sage/rings/finite_rings/galois_group.py +154 -0
  462. sage/rings/finite_rings/hom_finite_field.cpython-314t-aarch64-linux-musl.so +0 -0
  463. sage/rings/finite_rings/hom_finite_field.pxd +23 -0
  464. sage/rings/finite_rings/hom_finite_field.pyx +856 -0
  465. sage/rings/finite_rings/hom_prime_finite_field.cpython-314t-aarch64-linux-musl.so +0 -0
  466. sage/rings/finite_rings/hom_prime_finite_field.pxd +15 -0
  467. sage/rings/finite_rings/hom_prime_finite_field.pyx +164 -0
  468. sage/rings/finite_rings/homset.py +357 -0
  469. sage/rings/finite_rings/integer_mod.cpython-314t-aarch64-linux-musl.so +0 -0
  470. sage/rings/finite_rings/integer_mod.pxd +56 -0
  471. sage/rings/finite_rings/integer_mod.pyx +4586 -0
  472. sage/rings/finite_rings/integer_mod_limits.h +11 -0
  473. sage/rings/finite_rings/integer_mod_ring.py +2044 -0
  474. sage/rings/finite_rings/residue_field.cpython-314t-aarch64-linux-musl.so +0 -0
  475. sage/rings/finite_rings/residue_field.pxd +30 -0
  476. sage/rings/finite_rings/residue_field.pyx +1811 -0
  477. sage/rings/finite_rings/stdint.pxd +19 -0
  478. sage/rings/fraction_field.py +1452 -0
  479. sage/rings/fraction_field_element.cpython-314t-aarch64-linux-musl.so +0 -0
  480. sage/rings/fraction_field_element.pyx +1357 -0
  481. sage/rings/function_field/all.py +7 -0
  482. sage/rings/function_field/all__sagemath_categories.py +2 -0
  483. sage/rings/function_field/constructor.py +218 -0
  484. sage/rings/function_field/element.cpython-314t-aarch64-linux-musl.so +0 -0
  485. sage/rings/function_field/element.pxd +11 -0
  486. sage/rings/function_field/element.pyx +1008 -0
  487. sage/rings/function_field/element_rational.cpython-314t-aarch64-linux-musl.so +0 -0
  488. sage/rings/function_field/element_rational.pyx +513 -0
  489. sage/rings/function_field/extensions.py +230 -0
  490. sage/rings/function_field/function_field.py +1468 -0
  491. sage/rings/function_field/function_field_rational.py +1005 -0
  492. sage/rings/function_field/ideal.py +1155 -0
  493. sage/rings/function_field/ideal_rational.py +629 -0
  494. sage/rings/function_field/jacobian_base.py +826 -0
  495. sage/rings/function_field/jacobian_hess.py +1053 -0
  496. sage/rings/function_field/jacobian_khuri_makdisi.py +1027 -0
  497. sage/rings/function_field/maps.py +1039 -0
  498. sage/rings/function_field/order.py +281 -0
  499. sage/rings/function_field/order_basis.py +586 -0
  500. sage/rings/function_field/order_rational.py +576 -0
  501. sage/rings/function_field/place.py +426 -0
  502. sage/rings/function_field/place_rational.py +181 -0
  503. sage/rings/generic.py +320 -0
  504. sage/rings/homset.py +332 -0
  505. sage/rings/ideal.py +1885 -0
  506. sage/rings/ideal_monoid.py +215 -0
  507. sage/rings/infinity.py +1890 -0
  508. sage/rings/integer.cpython-314t-aarch64-linux-musl.so +0 -0
  509. sage/rings/integer.pxd +45 -0
  510. sage/rings/integer.pyx +7874 -0
  511. sage/rings/integer_ring.cpython-314t-aarch64-linux-musl.so +0 -0
  512. sage/rings/integer_ring.pxd +8 -0
  513. sage/rings/integer_ring.pyx +1693 -0
  514. sage/rings/laurent_series_ring.py +931 -0
  515. sage/rings/laurent_series_ring_element.cpython-314t-aarch64-linux-musl.so +0 -0
  516. sage/rings/laurent_series_ring_element.pxd +11 -0
  517. sage/rings/laurent_series_ring_element.pyx +1927 -0
  518. sage/rings/lazy_series.py +7815 -0
  519. sage/rings/lazy_series_ring.py +4356 -0
  520. sage/rings/localization.py +1043 -0
  521. sage/rings/morphism.cpython-314t-aarch64-linux-musl.so +0 -0
  522. sage/rings/morphism.pxd +39 -0
  523. sage/rings/morphism.pyx +3299 -0
  524. sage/rings/multi_power_series_ring.py +1145 -0
  525. sage/rings/multi_power_series_ring_element.py +2184 -0
  526. sage/rings/noncommutative_ideals.cpython-314t-aarch64-linux-musl.so +0 -0
  527. sage/rings/noncommutative_ideals.pyx +423 -0
  528. sage/rings/number_field/all__sagemath_categories.py +1 -0
  529. sage/rings/number_field/number_field_base.cpython-314t-aarch64-linux-musl.so +0 -0
  530. sage/rings/number_field/number_field_base.pxd +8 -0
  531. sage/rings/number_field/number_field_base.pyx +507 -0
  532. sage/rings/number_field/number_field_element_base.cpython-314t-aarch64-linux-musl.so +0 -0
  533. sage/rings/number_field/number_field_element_base.pxd +6 -0
  534. sage/rings/number_field/number_field_element_base.pyx +36 -0
  535. sage/rings/number_field/number_field_ideal.py +3550 -0
  536. sage/rings/padics/all__sagemath_categories.py +4 -0
  537. sage/rings/padics/local_generic.py +1670 -0
  538. sage/rings/padics/local_generic_element.cpython-314t-aarch64-linux-musl.so +0 -0
  539. sage/rings/padics/local_generic_element.pxd +5 -0
  540. sage/rings/padics/local_generic_element.pyx +1017 -0
  541. sage/rings/padics/misc.py +256 -0
  542. sage/rings/padics/padic_generic.py +1911 -0
  543. sage/rings/padics/pow_computer.cpython-314t-aarch64-linux-musl.so +0 -0
  544. sage/rings/padics/pow_computer.pxd +38 -0
  545. sage/rings/padics/pow_computer.pyx +671 -0
  546. sage/rings/padics/precision_error.py +24 -0
  547. sage/rings/polynomial/all__sagemath_categories.py +25 -0
  548. sage/rings/polynomial/commutative_polynomial.cpython-314t-aarch64-linux-musl.so +0 -0
  549. sage/rings/polynomial/commutative_polynomial.pxd +6 -0
  550. sage/rings/polynomial/commutative_polynomial.pyx +24 -0
  551. sage/rings/polynomial/cyclotomic.cpython-314t-aarch64-linux-musl.so +0 -0
  552. sage/rings/polynomial/cyclotomic.pyx +404 -0
  553. sage/rings/polynomial/flatten.py +711 -0
  554. sage/rings/polynomial/ideal.py +102 -0
  555. sage/rings/polynomial/infinite_polynomial_element.py +1768 -0
  556. sage/rings/polynomial/infinite_polynomial_ring.py +1653 -0
  557. sage/rings/polynomial/laurent_polynomial.cpython-314t-aarch64-linux-musl.so +0 -0
  558. sage/rings/polynomial/laurent_polynomial.pxd +18 -0
  559. sage/rings/polynomial/laurent_polynomial.pyx +2190 -0
  560. sage/rings/polynomial/laurent_polynomial_ideal.py +590 -0
  561. sage/rings/polynomial/laurent_polynomial_ring.py +832 -0
  562. sage/rings/polynomial/laurent_polynomial_ring_base.py +708 -0
  563. sage/rings/polynomial/multi_polynomial.cpython-314t-aarch64-linux-musl.so +0 -0
  564. sage/rings/polynomial/multi_polynomial.pxd +12 -0
  565. sage/rings/polynomial/multi_polynomial.pyx +3082 -0
  566. sage/rings/polynomial/multi_polynomial_element.py +2570 -0
  567. sage/rings/polynomial/multi_polynomial_ideal.py +5771 -0
  568. sage/rings/polynomial/multi_polynomial_ring.py +947 -0
  569. sage/rings/polynomial/multi_polynomial_ring_base.cpython-314t-aarch64-linux-musl.so +0 -0
  570. sage/rings/polynomial/multi_polynomial_ring_base.pxd +15 -0
  571. sage/rings/polynomial/multi_polynomial_ring_base.pyx +1855 -0
  572. sage/rings/polynomial/multi_polynomial_sequence.py +2204 -0
  573. sage/rings/polynomial/polydict.cpython-314t-aarch64-linux-musl.so +0 -0
  574. sage/rings/polynomial/polydict.pxd +45 -0
  575. sage/rings/polynomial/polydict.pyx +2701 -0
  576. sage/rings/polynomial/polynomial_compiled.cpython-314t-aarch64-linux-musl.so +0 -0
  577. sage/rings/polynomial/polynomial_compiled.pxd +59 -0
  578. sage/rings/polynomial/polynomial_compiled.pyx +509 -0
  579. sage/rings/polynomial/polynomial_element.cpython-314t-aarch64-linux-musl.so +0 -0
  580. sage/rings/polynomial/polynomial_element.pxd +64 -0
  581. sage/rings/polynomial/polynomial_element.pyx +13255 -0
  582. sage/rings/polynomial/polynomial_element_generic.py +1637 -0
  583. sage/rings/polynomial/polynomial_fateman.py +97 -0
  584. sage/rings/polynomial/polynomial_quotient_ring.py +2465 -0
  585. sage/rings/polynomial/polynomial_quotient_ring_element.py +779 -0
  586. sage/rings/polynomial/polynomial_ring.py +3784 -0
  587. sage/rings/polynomial/polynomial_ring_constructor.py +1051 -0
  588. sage/rings/polynomial/polynomial_ring_homomorphism.cpython-314t-aarch64-linux-musl.so +0 -0
  589. sage/rings/polynomial/polynomial_ring_homomorphism.pxd +5 -0
  590. sage/rings/polynomial/polynomial_ring_homomorphism.pyx +121 -0
  591. sage/rings/polynomial/polynomial_singular_interface.py +549 -0
  592. sage/rings/polynomial/symmetric_ideal.py +989 -0
  593. sage/rings/polynomial/symmetric_reduction.cpython-314t-aarch64-linux-musl.so +0 -0
  594. sage/rings/polynomial/symmetric_reduction.pxd +8 -0
  595. sage/rings/polynomial/symmetric_reduction.pyx +669 -0
  596. sage/rings/polynomial/term_order.py +2279 -0
  597. sage/rings/polynomial/toy_buchberger.py +449 -0
  598. sage/rings/polynomial/toy_d_basis.py +387 -0
  599. sage/rings/polynomial/toy_variety.py +362 -0
  600. sage/rings/power_series_mpoly.cpython-314t-aarch64-linux-musl.so +0 -0
  601. sage/rings/power_series_mpoly.pxd +9 -0
  602. sage/rings/power_series_mpoly.pyx +161 -0
  603. sage/rings/power_series_poly.cpython-314t-aarch64-linux-musl.so +0 -0
  604. sage/rings/power_series_poly.pxd +10 -0
  605. sage/rings/power_series_poly.pyx +1317 -0
  606. sage/rings/power_series_ring.py +1441 -0
  607. sage/rings/power_series_ring_element.cpython-314t-aarch64-linux-musl.so +0 -0
  608. sage/rings/power_series_ring_element.pxd +12 -0
  609. sage/rings/power_series_ring_element.pyx +3028 -0
  610. sage/rings/puiseux_series_ring.py +487 -0
  611. sage/rings/puiseux_series_ring_element.cpython-314t-aarch64-linux-musl.so +0 -0
  612. sage/rings/puiseux_series_ring_element.pxd +7 -0
  613. sage/rings/puiseux_series_ring_element.pyx +1055 -0
  614. sage/rings/qqbar_decorators.py +167 -0
  615. sage/rings/quotient_ring.py +1598 -0
  616. sage/rings/quotient_ring_element.py +979 -0
  617. sage/rings/rational.cpython-314t-aarch64-linux-musl.so +0 -0
  618. sage/rings/rational.pxd +20 -0
  619. sage/rings/rational.pyx +4284 -0
  620. sage/rings/rational_field.py +1730 -0
  621. sage/rings/real_double.cpython-314t-aarch64-linux-musl.so +0 -0
  622. sage/rings/real_double.pxd +16 -0
  623. sage/rings/real_double.pyx +2218 -0
  624. sage/rings/real_lazy.cpython-314t-aarch64-linux-musl.so +0 -0
  625. sage/rings/real_lazy.pxd +30 -0
  626. sage/rings/real_lazy.pyx +1773 -0
  627. sage/rings/ring.cpython-314t-aarch64-linux-musl.so +0 -0
  628. sage/rings/ring.pxd +30 -0
  629. sage/rings/ring.pyx +850 -0
  630. sage/rings/semirings/all.py +3 -0
  631. sage/rings/semirings/non_negative_integer_semiring.py +107 -0
  632. sage/rings/semirings/tropical_mpolynomial.py +972 -0
  633. sage/rings/semirings/tropical_polynomial.py +997 -0
  634. sage/rings/semirings/tropical_semiring.cpython-314t-aarch64-linux-musl.so +0 -0
  635. sage/rings/semirings/tropical_semiring.pyx +676 -0
  636. sage/rings/semirings/tropical_variety.py +1701 -0
  637. sage/rings/sum_of_squares.cpython-314t-aarch64-linux-musl.so +0 -0
  638. sage/rings/sum_of_squares.pxd +3 -0
  639. sage/rings/sum_of_squares.pyx +336 -0
  640. sage/rings/tests.py +504 -0
  641. sage/schemes/affine/affine_homset.py +508 -0
  642. sage/schemes/affine/affine_morphism.py +1574 -0
  643. sage/schemes/affine/affine_point.py +460 -0
  644. sage/schemes/affine/affine_rational_point.py +308 -0
  645. sage/schemes/affine/affine_space.py +1264 -0
  646. sage/schemes/affine/affine_subscheme.py +592 -0
  647. sage/schemes/affine/all.py +25 -0
  648. sage/schemes/all__sagemath_categories.py +5 -0
  649. sage/schemes/generic/algebraic_scheme.py +2092 -0
  650. sage/schemes/generic/all.py +5 -0
  651. sage/schemes/generic/ambient_space.py +400 -0
  652. sage/schemes/generic/divisor.py +465 -0
  653. sage/schemes/generic/divisor_group.py +313 -0
  654. sage/schemes/generic/glue.py +84 -0
  655. sage/schemes/generic/homset.py +820 -0
  656. sage/schemes/generic/hypersurface.py +234 -0
  657. sage/schemes/generic/morphism.py +2107 -0
  658. sage/schemes/generic/point.py +237 -0
  659. sage/schemes/generic/scheme.py +1190 -0
  660. sage/schemes/generic/spec.py +199 -0
  661. sage/schemes/product_projective/all.py +6 -0
  662. sage/schemes/product_projective/homset.py +236 -0
  663. sage/schemes/product_projective/morphism.py +517 -0
  664. sage/schemes/product_projective/point.py +568 -0
  665. sage/schemes/product_projective/rational_point.py +550 -0
  666. sage/schemes/product_projective/space.py +1301 -0
  667. sage/schemes/product_projective/subscheme.py +466 -0
  668. sage/schemes/projective/all.py +24 -0
  669. sage/schemes/projective/proj_bdd_height.py +453 -0
  670. sage/schemes/projective/projective_homset.py +718 -0
  671. sage/schemes/projective/projective_morphism.py +2792 -0
  672. sage/schemes/projective/projective_point.py +1484 -0
  673. sage/schemes/projective/projective_rational_point.py +569 -0
  674. sage/schemes/projective/projective_space.py +2571 -0
  675. sage/schemes/projective/projective_subscheme.py +1574 -0
  676. sage/sets/all.py +17 -0
  677. sage/sets/cartesian_product.py +376 -0
  678. sage/sets/condition_set.py +525 -0
  679. sage/sets/disjoint_set.cpython-314t-aarch64-linux-musl.so +0 -0
  680. sage/sets/disjoint_set.pxd +36 -0
  681. sage/sets/disjoint_set.pyx +998 -0
  682. sage/sets/disjoint_union_enumerated_sets.py +625 -0
  683. sage/sets/family.cpython-314t-aarch64-linux-musl.so +0 -0
  684. sage/sets/family.pxd +12 -0
  685. sage/sets/family.pyx +1556 -0
  686. sage/sets/finite_enumerated_set.py +406 -0
  687. sage/sets/finite_set_map_cy.cpython-314t-aarch64-linux-musl.so +0 -0
  688. sage/sets/finite_set_map_cy.pxd +34 -0
  689. sage/sets/finite_set_map_cy.pyx +708 -0
  690. sage/sets/finite_set_maps.py +591 -0
  691. sage/sets/image_set.py +448 -0
  692. sage/sets/integer_range.py +829 -0
  693. sage/sets/non_negative_integers.py +241 -0
  694. sage/sets/positive_integers.py +93 -0
  695. sage/sets/primes.py +188 -0
  696. sage/sets/real_set.py +2760 -0
  697. sage/sets/recursively_enumerated_set.cpython-314t-aarch64-linux-musl.so +0 -0
  698. sage/sets/recursively_enumerated_set.pxd +31 -0
  699. sage/sets/recursively_enumerated_set.pyx +2082 -0
  700. sage/sets/set.py +2083 -0
  701. sage/sets/set_from_iterator.py +1021 -0
  702. sage/sets/totally_ordered_finite_set.py +329 -0
  703. sage/symbolic/all__sagemath_categories.py +1 -0
  704. sage/symbolic/function.cpython-314t-aarch64-linux-musl.so +0 -0
  705. sage/symbolic/function.pxd +29 -0
  706. sage/symbolic/function.pyx +1488 -0
  707. sage/symbolic/symbols.py +56 -0
  708. sage/tests/all__sagemath_categories.py +1 -0
  709. sage/tests/cython.cpython-314t-aarch64-linux-musl.so +0 -0
  710. sage/tests/cython.pyx +37 -0
  711. sage/tests/stl_vector.cpython-314t-aarch64-linux-musl.so +0 -0
  712. sage/tests/stl_vector.pyx +171 -0
  713. sage/typeset/all.py +6 -0
  714. sage/typeset/ascii_art.py +295 -0
  715. sage/typeset/character_art.py +789 -0
  716. sage/typeset/character_art_factory.py +572 -0
  717. sage/typeset/symbols.py +334 -0
  718. sage/typeset/unicode_art.py +183 -0
  719. sage/typeset/unicode_characters.py +101 -0
@@ -0,0 +1,1055 @@
1
+ # sage_setup: distribution = sagemath-categories
2
+ r"""
3
+ Puiseux Series Ring Element
4
+
5
+ A Puiseux series is a series of the form
6
+
7
+ .. MATH::
8
+
9
+ p(x) = \sum_{n=N}^{\infty} a_n (x-a)^{n/e},
10
+
11
+ where the integer :math:`e` is called the *ramification index* of the series
12
+ and the number :math:`a` is the *center*. A Puiseux series is essentially a
13
+ Laurent series but with fractional exponents.
14
+
15
+ EXAMPLES:
16
+
17
+ We begin by constructing the ring of Puiseux series in `x` with coefficients
18
+ in the rationals::
19
+
20
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
21
+
22
+ This command also defines ``x`` as the generator of this ring.
23
+
24
+ When constructing a Puiseux series, the ramification index is automatically
25
+ determined from the greatest common divisor of the exponents::
26
+
27
+ sage: p = x^(1/2); p
28
+ x^(1/2)
29
+ sage: p.ramification_index()
30
+ 2
31
+ sage: q = x^(1/2) + x**(1/3); q
32
+ x^(1/3) + x^(1/2)
33
+ sage: q.ramification_index()
34
+ 6
35
+
36
+ Other arithmetic can be performed with Puiseux Series::
37
+
38
+ sage: p + q
39
+ x^(1/3) + 2*x^(1/2)
40
+ sage: p - q
41
+ -x^(1/3)
42
+ sage: p * q
43
+ x^(5/6) + x
44
+ sage: (p / q).add_bigoh(4/3)
45
+ x^(1/6) - x^(1/3) + x^(1/2) - x^(2/3) + x^(5/6) - x + x^(7/6) + O(x^(4/3))
46
+
47
+ Mind the base ring. However, the base ring can be changed::
48
+
49
+ sage: I*q # needs sage.rings.number_field
50
+ Traceback (most recent call last):
51
+ ...
52
+ TypeError: unsupported operand parent(s) for *:
53
+ 'Number Field in I with defining polynomial x^2 + 1 with I = 1*I' and
54
+ 'Puiseux Series Ring in x over Rational Field'
55
+ sage: qz = q.change_ring(ZZ); qz
56
+ x^(1/3) + x^(1/2)
57
+ sage: qz.parent()
58
+ Puiseux Series Ring in x over Integer Ring
59
+
60
+ Other properties of the Puiseux series can be easily obtained::
61
+
62
+ sage: r = (3*x^(-1/5) + 7*x^(2/5) + (1/2)*x).add_bigoh(6/5); r
63
+ 3*x^(-1/5) + 7*x^(2/5) + 1/2*x + O(x^(6/5))
64
+ sage: r.valuation()
65
+ -1/5
66
+ sage: r.prec()
67
+ 6/5
68
+ sage: r.precision_absolute()
69
+ 6/5
70
+ sage: r.precision_relative()
71
+ 7/5
72
+ sage: r.exponents()
73
+ [-1/5, 2/5, 1]
74
+ sage: r.coefficients()
75
+ [3, 7, 1/2]
76
+
77
+ Finally, Puiseux series are compatible with other objects in Sage.
78
+ For example, you can perform arithmetic with Laurent series::
79
+
80
+ sage: L.<x> = LaurentSeriesRing(ZZ)
81
+ sage: l = 3*x^(-2) + x^(-1) + 2 + x**3
82
+ sage: r + l
83
+ 3*x^-2 + x^-1 + 3*x^(-1/5) + 2 + 7*x^(2/5) + 1/2*x + O(x^(6/5))
84
+
85
+ AUTHORS:
86
+
87
+ - Chris Swierczewski 2016: initial version on https://github.com/abelfunctions/abelfunctions/tree/master/abelfunctions
88
+ - Frédéric Chapoton 2016: integration of code
89
+ - Travis Scrimshaw, Sebastian Oehms 2019-2020: basic improvements and completions
90
+
91
+ REFERENCES:
92
+
93
+ - :wikipedia:`Puiseux_series`
94
+ """
95
+
96
+
97
+ # ****************************************************************************
98
+ # Copyright (c) 2016 Chris Swierczewski
99
+ #
100
+ # This program is free software: you can redistribute it and/or modify
101
+ # it under the terms of the GNU General Public License as published by
102
+ # the Free Software Foundation, either version 2 of the License, or
103
+ # (at your option) any later version.
104
+ # https://www.gnu.org/licenses/
105
+ # ****************************************************************************
106
+
107
+ from sage.arith.functions import lcm
108
+ from sage.arith.misc import gcd
109
+ from sage.rings.integer_ring import ZZ
110
+ from sage.rings.rational_field import QQ
111
+ from sage.rings.infinity import infinity
112
+ from sage.rings.laurent_series_ring_element cimport LaurentSeries
113
+ from sage.structure.element cimport (Element, AlgebraElement)
114
+ from sage.structure.richcmp cimport richcmp
115
+
116
+
117
+ cdef class PuiseuxSeries(AlgebraElement):
118
+ r"""
119
+ A Puiseux series.
120
+
121
+ .. MATH::
122
+
123
+ \sum_{n=-N}^\infty a_n x^{n/e}
124
+
125
+ It is stored as a Laurent series:
126
+
127
+ .. MATH::
128
+
129
+ \sum_{n=-N}^\infty a_n t^n
130
+
131
+ where `t = x^{1/e}`.
132
+
133
+ INPUT:
134
+
135
+ - ``parent`` -- the parent ring
136
+
137
+ - ``f`` -- one of the following types of inputs:
138
+
139
+ * instance of :class:`PuiseuxSeries`
140
+ * instance that can be coerced into the Laurent series ring of the parent
141
+
142
+ - ``e`` -- integer (default: 1); the ramification index
143
+
144
+ EXAMPLES::
145
+
146
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
147
+ sage: p = x^(1/2) + x**3; p
148
+ x^(1/2) + x^3
149
+ sage: q = x**(1/2) - x**(-1/2)
150
+ sage: r = q.add_bigoh(7/2); r
151
+ -x^(-1/2) + x^(1/2) + O(x^(7/2))
152
+ sage: r**2
153
+ x^-1 - 2 + x + O(x^3)
154
+ """
155
+
156
+ def __init__(self, parent, f, e=1):
157
+ r"""
158
+ Initialize ``self``.
159
+
160
+ TESTS::
161
+
162
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
163
+ sage: p = x^(1/2) + x**3
164
+ sage: TestSuite(p).run()
165
+ """
166
+ AlgebraElement.__init__(self, parent)
167
+ L = parent._laurent_series_ring
168
+
169
+ if isinstance(f, PuiseuxSeries):
170
+ if (<PuiseuxSeries>f)._l._parent is L:
171
+ l = (<PuiseuxSeries>f)._l
172
+ e = (<PuiseuxSeries>f)._e
173
+ else:
174
+ l = L((<PuiseuxSeries>f)._l)
175
+ e = L((<PuiseuxSeries>f)._e)
176
+ else:
177
+ l = L(f)
178
+
179
+ # --------------------------------------------------------
180
+ # choose a representative for this Puiseux series having
181
+ # minimal ramification index. This is necessary because
182
+ # some methods need it as minimal as possible (for example
183
+ # :meth:`laurent_series' or :meth:`power_series`)
184
+ # --------------------------------------------------------
185
+ exp_list = l.exponents()
186
+ prec = l.prec()
187
+ if prec is infinity:
188
+ d = gcd(exp_list +[e])
189
+ else:
190
+ d = gcd(exp_list + [e] + [prec])
191
+ if d > 1:
192
+ # ramification index can be reduced dividing by d
193
+ e = e / d
194
+ cf_ori = l.list()
195
+ if cf_ori:
196
+ cf = [cf_ori[d*i] for i in range((len(cf_ori)-1) / d + 1)]
197
+ else:
198
+ cf = cf_ori
199
+ val = l.valuation() / d
200
+ l = l.parent()(cf, n=val)
201
+ if prec != infinity:
202
+ l = l.add_bigoh(prec / d)
203
+
204
+ self._l = l
205
+ self._e = int(abs(e))
206
+
207
+ def __reduce__(self):
208
+ """
209
+ EXAMPLES::
210
+
211
+ sage: R.<x> = PuiseuxSeriesRing(ZZ)
212
+ sage: p = x^(1/2) + x**3-x**(-1/4)
213
+ sage: loads(dumps(p)) == p # indirect doctest
214
+ True
215
+ """
216
+ return (self._parent, (self._l, self._e))
217
+
218
+ def _im_gens_(self, codomain, im_gens, base_map=None):
219
+ """
220
+ EXAMPLES::
221
+
222
+ sage: # needs sage.rings.number_field
223
+ sage: R.<x> = PuiseuxSeriesRing(ZZ)
224
+ sage: p = x^(1/3) + x**3
225
+ sage: t = p._im_gens_(QQbar, [2])
226
+ sage: t in QQbar
227
+ True
228
+ sage: f = R.hom([QQbar(2)], check=False)
229
+ sage: t == f(p)
230
+ True
231
+ """
232
+ return self(codomain(im_gens[0]))
233
+
234
+ def _repr_(self):
235
+ """
236
+ Return a string representation.
237
+
238
+ EXAMPLES::
239
+
240
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
241
+ sage: p = x^(1/2) + x**3-x**(-1/4); p
242
+ -x^(-1/4) + x^(1/2) + x^3
243
+ sage: R.zero()
244
+ 0
245
+
246
+ sage: S.<t> = PuiseuxSeriesRing(Zp(5)) # needs sage.rings.padics
247
+ sage: t**(1/2) + 5 * t^(1/3) # needs sage.rings.padics
248
+ (5 + O(5^21))*t^(1/3) + (1 + O(5^20))*t^(1/2)
249
+ """
250
+ laurent = self.laurent_part()
251
+ s = repr(laurent)
252
+ if self.ramification_index() == 1:
253
+ return s
254
+
255
+ X = self._parent.variable_name()
256
+
257
+ # find a temporary variable name (to avoid multiple transformations)
258
+ Xtemp = '?'
259
+ while Xtemp in s: Xtemp +='?' # if somebody uses '?' in variable_name
260
+
261
+ # renaming and generalizing linear term
262
+ s = s.replace('%s' %X, '%s^1' %Xtemp)
263
+ s = s.replace('^1^', '^' )
264
+
265
+ # prepare exponent list
266
+ if laurent.prec() is infinity:
267
+ exponents = [ZZ(exp) for exp in set(laurent.exponents())]
268
+ else:
269
+ exponents = [ZZ(exp) for exp in set(laurent.exponents() + [laurent.prec()])]
270
+
271
+ # sort exponents such that the largest will be replaced first
272
+ exp_pos = [exp for exp in exponents if exp >= 0]
273
+ exp_pos.sort(reverse=True)
274
+ exp_neg = [exp for exp in exponents if exp < 0]
275
+ exp_neg.sort()
276
+ exponents = exp_neg + exp_pos
277
+
278
+ # replacing exponents
279
+ e = ZZ(self.ramification_index())
280
+ for exp_l in exponents:
281
+ exp = exp_l/e
282
+ repl_str = '%s^%s' %(Xtemp, exp_l)
283
+ if exp.is_one():
284
+ s = s.replace(repl_str, '%s' %X)
285
+ elif e.divides(exp_l):
286
+ s = s.replace(repl_str, '%s^%s' %(X, exp))
287
+ else:
288
+ s = s.replace(repl_str, '%s^(%s)' %(X, exp))
289
+ return s
290
+
291
+ def __call__(self, x):
292
+ r"""
293
+ Evaluate this Puiseux series.
294
+
295
+ INPUT:
296
+
297
+ - ``x`` -- element of a ring
298
+
299
+ EXAMPLES::
300
+
301
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
302
+ sage: p = x^(1/2) + x**3-x**(-1/4)
303
+ sage: p(16)
304
+ 8199/2
305
+ sage: p(pi.n()) # needs sage.symbolic
306
+ 32.0276049867404
307
+ """
308
+ # use x.nth_root since x**(1/self._e) returns oo when x = 0
309
+ if isinstance(x, int):
310
+ x = ZZ(x)
311
+ elif isinstance(x, float):
312
+ from sage.rings.complex_mpfr import ComplexField
313
+ x = ComplexField()(x)
314
+ t = x.nth_root(self._e)
315
+ p = self._l.__u.polynomial()
316
+ n = self._l.__n
317
+ return p(t)*t**n
318
+
319
+ def _common_ramification_index(self, PuiseuxSeries right):
320
+ r"""
321
+ Return a ramification index common to ``self`` and ``right``.
322
+
323
+ In order to perform arithmetic on Puiseux series it is useful to find a
324
+ common ramification index between two operands. That is, given Puiseux
325
+ series :math:`p` and :math:`q` of ramification indices :math:`e` and
326
+ :math:`f` we write both as series :math:`\tilde{f}` and
327
+ :math:`\tilde{g}` in :math:`(x-a)^(1/g)` such that,
328
+
329
+ .. MATH::
330
+
331
+ f = \tilde{f}((x-a)^M), g = \tilde{g}((x-a)^N).
332
+
333
+ INPUT:
334
+
335
+ - ``right`` -- a Puiseux series
336
+
337
+ OUTPUT:
338
+
339
+ - ``g`` -- integer; a ramification index common to ``self`` and
340
+ ``right``
341
+ - ``M``, ``N`` -- integers; scaling factors on ``self`` and ``right``,
342
+ respectively
343
+
344
+ EXAMPLES::
345
+
346
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
347
+ sage: p = x^(1/3) + x**2-x**(-1/7)
348
+ sage: q = x^(-1/3) + x**2-x**(1/5)
349
+ sage: p._common_ramification_index(q)
350
+ (105, 5, 7)
351
+ sage: q._common_ramification_index(p)
352
+ (105, 7, 5)
353
+ """
354
+ m = self._e
355
+ n = right._e
356
+ g = lcm(m, n)
357
+ m = g / m
358
+ n = g / n
359
+ return g, m, n
360
+
361
+ cpdef _add_(self, right_m):
362
+ """
363
+ Return the sum.
364
+
365
+ EXAMPLES::
366
+
367
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
368
+ sage: p = x^(1/2) + 3/4 * x^(2/3)
369
+ sage: q = 2*x^(1/3) + 3/4 * x^(2/5)
370
+ sage: p + q # indirect doctest
371
+ 2*x^(1/3) + 3/4*x^(2/5) + x^(1/2) + 3/4*x^(2/3)
372
+ """
373
+ cdef PuiseuxSeries right = <PuiseuxSeries>right_m
374
+ cdef LaurentSeries l, l1, l2
375
+ cdef size_t g, m, n
376
+
377
+ g, m, n = self._common_ramification_index(right)
378
+ l1 = self._l.V(m)
379
+ l2 = right._l.V(n)
380
+ l = l1 + l2
381
+ return type(self)(self._parent, l, g)
382
+
383
+ cpdef _sub_(self, right_m):
384
+ """
385
+ Return the difference.
386
+
387
+ EXAMPLES::
388
+
389
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
390
+ sage: p = x^(1/2) + 3/4 * x^(2/3)
391
+ sage: q = 2*x^(1/3) + 3/4 * x^(2/5)
392
+ sage: p - q # indirect doctest
393
+ -2*x^(1/3) - 3/4*x^(2/5) + x^(1/2) + 3/4*x^(2/3)
394
+ """
395
+ cdef PuiseuxSeries right = <PuiseuxSeries>right_m
396
+ cdef LaurentSeries l, l1, l2
397
+ cdef size_t g, m, n
398
+
399
+ g, m, n = self._common_ramification_index(right)
400
+ l1 = self._l.V(m)
401
+ l2 = right._l.V(n)
402
+ l = l1 - l2
403
+ return type(self)(self._parent, l, g)
404
+
405
+ cpdef _mul_(self, right_r):
406
+ """
407
+ Return the product.
408
+
409
+ EXAMPLES::
410
+
411
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
412
+ sage: p = x^(1/2) + 3/4 * x^(2/3)
413
+ sage: q = 2*x^(1/3) + 3/4 * x^(2/5)
414
+ sage: p * q # indirect doctest
415
+ 2*x^(5/6) + 3/4*x^(9/10) + 3/2*x + 9/16*x^(16/15)
416
+ """
417
+ cdef PuiseuxSeries right = <PuiseuxSeries>right_r
418
+ cdef LaurentSeries l, l1, l2
419
+ cdef size_t g, m, n
420
+
421
+ g, m, n = self._common_ramification_index(right)
422
+ l1 = self._l.V(m)
423
+ l2 = right._l.V(n)
424
+ l = l1 * l2
425
+ return type(self)(self._parent, l, g)
426
+
427
+ cpdef _rmul_(self, Element c):
428
+ """
429
+ Return the right scalar multiplication.
430
+
431
+ EXAMPLES::
432
+
433
+ sage: P.<y> = PuiseuxSeriesRing(ZZ)
434
+ sage: t = y^(-1/3) + O(y^(0))
435
+ sage: 5*t # indirect doctest
436
+ 5*y^(-1/3) + O(1)
437
+ """
438
+ return type(self)(self._parent, self._l._rmul_(c), self._e)
439
+
440
+ cpdef _lmul_(self, Element c):
441
+ """
442
+ Return the left scalar multiplication.
443
+
444
+ EXAMPLES::
445
+
446
+ sage: P.<y> = PuiseuxSeriesRing(Zp(3)) # needs sage.rings.padics
447
+ sage: t = y^(2/5) + O(y) # needs sage.rings.padics
448
+ sage: 5*t # indirect doctest # needs sage.rings.padics
449
+ (2 + 3 + O(3^20))*y^(2/5) + O(y)
450
+ """
451
+ return type(self)(self._parent, self._l._lmul_(c), self._e)
452
+
453
+ cpdef _div_(self, right_r):
454
+ """
455
+ Return the quotient.
456
+
457
+ EXAMPLES::
458
+
459
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
460
+ sage: p = x^(1/2) + 3/4 * x^(2/3)
461
+ sage: q = 2*x^(1/3) + 3/4 * x^(2/5)
462
+ sage: p / q
463
+ 1/2*x^(1/6) - 3/16*x^(7/30) + 9/128*x^(3/10) + 3/8*x^(1/3)
464
+ - 27/1024*x^(11/30) - 9/64*x^(2/5) + 81/8192*x^(13/30)
465
+ + 27/512*x^(7/15) - 243/65536*x^(1/2) - 81/4096*x^(8/15)
466
+ + 729/524288*x^(17/30) + 243/32768*x^(3/5) - 2187/4194304*x^(19/30)
467
+ - 729/262144*x^(2/3) + 6561/33554432*x^(7/10)
468
+ + 2187/2097152*x^(11/15) - 19683/268435456*x^(23/30)
469
+ - 6561/16777216*x^(4/5) + O(x^(5/6))
470
+ """
471
+ cdef PuiseuxSeries right = <PuiseuxSeries>right_r
472
+ cdef LaurentSeries l, l1, l2
473
+ cdef size_t g, m, n
474
+
475
+ g, m, n = self._common_ramification_index(right)
476
+ l1 = self._l.V(m)
477
+ l2 = right._l.V(n)
478
+ l = l1 / l2
479
+ return type(self)(self._parent, l, g)
480
+
481
+ def __pow__(_self, r, dummy):
482
+ """
483
+ Return the power.
484
+
485
+ EXAMPLES::
486
+
487
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
488
+ sage: p = x^(1/2) + 3/4 * x^(2/3)
489
+ sage: p ** 3
490
+ x^(3/2) + 9/4*x^(5/3) + 27/16*x^(11/6) + 27/64*x^2
491
+ """
492
+ cdef PuiseuxSeries self = _self
493
+ cdef LaurentSeries l
494
+ cdef size_t e
495
+
496
+ r = QQ(r)
497
+ numer = r.numerator()
498
+ denom = r.denominator()
499
+
500
+ # if the exponent is integral then do normal exponentiation
501
+ if denom == 1:
502
+ l = self._l ** int(numer)
503
+ e = self._e
504
+ # otherwise, we only exponentiate by a rational number if there is a
505
+ # single term in the Puiseux series
506
+ #
507
+ # (I suppose we could use Taylor series expansions in the general case)
508
+ else:
509
+ if not self.is_monomial():
510
+ raise ValueError('can only exponentiate single term by rational')
511
+ l = self._l.V(numer)
512
+ e = self._e * int(denom)
513
+ return type(self)(self._parent, l, e)
514
+
515
+ cpdef _richcmp_(self, right_r, int op):
516
+ r"""
517
+ Comparison of ``self`` and ``right``.
518
+
519
+ We say two approximate Puiseux series are equal, if they agree for
520
+ all coefficients up to the *minimum* of the precisions of each.
521
+
522
+ Comparison is done in dictionary order going from lowest degree
523
+ to highest degree coefficients with respect to the corresponding
524
+ Laurent series. That means that comparison is performed for
525
+ corresponding `LaurentSeries` instances obtained for the common
526
+ ramification index.
527
+
528
+ See :meth:`power_series_ring_element._richcmp_` and
529
+ :meth:`_laurent_series_ring_element._richcmp_` for more
530
+ information.
531
+
532
+ EXAMPLES::
533
+
534
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
535
+ sage: p = x^(1/2) + 3/4 * x^(2/3)
536
+ sage: q = 2*x^(1/3) + 3/4 * x^(2/5)
537
+ sage: (p < q, p >= q, p == 0, q != 0)
538
+ (True, False, False, True)
539
+ sage: p2 = x^(1/2) + 3/5 * x^(2/3)
540
+ sage: (p2 < p, p2 >= p)
541
+ (True, False)
542
+ sage: p3 = p2.add_bigoh(2/3); p3
543
+ x^(1/2) + O(x^(2/3))
544
+ sage: (p3 == p2, p3 == p, p3 < q, p3 > q)
545
+ (True, True, True, False)
546
+ """
547
+ cdef PuiseuxSeries right = <PuiseuxSeries>right_r
548
+ if self._e == right._e:
549
+ return richcmp(self._l, right._l, op)
550
+
551
+ # If both have different ramification indices they must be different as
552
+ # Puiseux series (by the normalization performed in the python constructor).
553
+ # We use the ramification index to order them.
554
+ return richcmp(self._e, right._e, op)
555
+
556
+ def __lshift__(self, r):
557
+ """
558
+ Apply :meth:`shift` using the operator `<<`.
559
+
560
+ EXAMPLES::
561
+
562
+ sage: P.<y> = LaurentPolynomialRing(ZZ)
563
+ sage: R.<x> = PuiseuxSeriesRing(P)
564
+ sage: p = y*x**(-1/3) + 2*y^(-2)*x**(1/2)
565
+ sage: p << 1/3 # indirect doctest
566
+ y + (2*y^-2)*x^(5/6)
567
+ """
568
+ return self.shift(r)
569
+
570
+ def __rshift__(self, r):
571
+ """
572
+ Apply :meth:`shift` with negative argument using the operator `>>`.
573
+
574
+ EXAMPLES::
575
+
576
+ sage: P.<y> = LaurentPolynomialRing(ZZ)
577
+ sage: R.<x> = PuiseuxSeriesRing(P)
578
+ sage: p = y*x**(-1/3) + 2*y^(-2)*x**(1/2)
579
+ sage: p >> 1/3 # indirect doctest
580
+ y*x^(-2/3) + (2*y^-2)*x^(1/6)
581
+ """
582
+ return self.shift(-r)
583
+
584
+ def __bool__(self):
585
+ """
586
+ Return whether ``self`` is not zero.
587
+
588
+ EXAMPLES::
589
+
590
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
591
+ sage: p = x^(1/2) + 3/4 * x^(2/3)
592
+ sage: p.is_zero() # indirect doctest
593
+ False
594
+ sage: R.zero() != 0
595
+ False
596
+ """
597
+ return bool(self._l)
598
+
599
+ def __hash__(self):
600
+ """
601
+ Return a hash of ``self``.
602
+
603
+ EXAMPLES::
604
+
605
+ sage: from operator import xor
606
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
607
+ sage: p = x^(-7/2) + 3 + 5*x^(1/2) - 7*x**3
608
+ sage: hash(p) == xor(hash(p.laurent_part()), 2) # indirect doctest
609
+ True
610
+ """
611
+ return hash(self._l) ^ self._e
612
+
613
+ def __getitem__(self, r):
614
+ r"""
615
+ Return the coefficient with exponent ``r``.
616
+
617
+ EXAMPLES::
618
+
619
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
620
+ sage: p = x^(-7/2) + 3 + 5*x^(1/2) - 7*x**3
621
+ sage: p[-7/2]
622
+ 1
623
+ sage: p[0]
624
+ 3
625
+ sage: p[1/2]
626
+ 5
627
+ sage: p[3]
628
+ -7
629
+ sage: p[100]
630
+ 0
631
+ """
632
+ if isinstance(r, slice):
633
+ start, stop, step = r.start, r.stop, r.step
634
+ n = slice(start * self._e, stop * self._e, step * self._e)
635
+ return PuiseuxSeries(self._parent, self._l[start:stop:step], self._e)
636
+ else:
637
+ n = int(r * self._e)
638
+ return self._l[n]
639
+
640
+ def __iter__(self):
641
+ """
642
+ Return an iterator over the coefficients.
643
+
644
+ EXAMPLES::
645
+
646
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
647
+ sage: p = x^(-7/2) + 3 + 5*x^(1/2) - 7*x**3
648
+ sage: list(p)
649
+ [1, 0, 0, 0, 0, 0, 0, 3, 5, 0, 0, 0, 0, -7]
650
+ """
651
+ return iter(self._l)
652
+
653
+ def __copy__(self):
654
+ """
655
+ Since this is immutable, return ``self``.
656
+
657
+ EXAMPLES::
658
+
659
+ sage: R.<x> = PuiseuxSeriesRing(ZZ)
660
+ sage: p = x^(3/4) + 2*x^(4/5) + 3* x^(5/6)
661
+ sage: p2 = copy(p); p2
662
+ x^(3/4) + 2*x^(4/5) + 3*x^(5/6)
663
+ sage: p == p2
664
+ True
665
+ sage: p is p2
666
+ True
667
+ """
668
+ return self
669
+
670
+ def laurent_part(self):
671
+ """
672
+ Return the underlying Laurent series.
673
+
674
+ EXAMPLES::
675
+
676
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
677
+ sage: p = x^(1/2) + 3/4 * x^(2/3)
678
+ sage: p.laurent_part()
679
+ x^3 + 3/4*x^4
680
+ """
681
+ return self._l
682
+
683
+ def ramification_index(self):
684
+ """
685
+ Return the ramification index.
686
+
687
+ EXAMPLES::
688
+
689
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
690
+ sage: p = x^(1/2) + 3/4 * x^(2/3)
691
+ sage: p.ramification_index()
692
+ 6
693
+ """
694
+ return self._e
695
+
696
+ def valuation(self):
697
+ r"""
698
+ Return the valuation of ``self``.
699
+
700
+ EXAMPLES::
701
+
702
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
703
+ sage: p = x^(-7/2) + 3 + 5*x^(1/2) - 7*x**3
704
+ sage: p.valuation()
705
+ -7/2
706
+
707
+ TESTS::
708
+
709
+ sage: R.zero().valuation()
710
+ +Infinity
711
+ """
712
+ return self._l.valuation() / QQ(self._e)
713
+
714
+ def add_bigoh(self, prec):
715
+ r"""
716
+ Return the truncated series at chosen precision ``prec``.
717
+
718
+ INPUT:
719
+
720
+ - ``prec`` -- the precision of the series as a rational number
721
+
722
+ EXAMPLES::
723
+
724
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
725
+ sage: p = x^(-7/2) + 3 + 5*x^(1/2) - 7*x**3
726
+ sage: p.add_bigoh(2)
727
+ x^(-7/2) + 3 + 5*x^(1/2) + O(x^2)
728
+ sage: p.add_bigoh(0)
729
+ x^(-7/2) + O(1)
730
+ sage: p.add_bigoh(-1)
731
+ x^(-7/2) + O(x^-1)
732
+
733
+ .. NOTE::
734
+
735
+ The precision passed to the method is adapted to the common
736
+ ramification index::
737
+
738
+ sage: R.<x> = PuiseuxSeriesRing(ZZ)
739
+ sage: p = x**(-1/3) + 2*x**(1/5)
740
+ sage: p.add_bigoh(1/2)
741
+ x^(-1/3) + 2*x^(1/5) + O(x^(7/15))
742
+ """
743
+ if prec is infinity or prec >= self.prec():
744
+ return self
745
+
746
+ l_prec = int(prec * self._e)
747
+ l = self._l.add_bigoh(l_prec)
748
+ return PuiseuxSeries(self._parent, l, self._e)
749
+
750
+ def change_ring(self, R):
751
+ r"""
752
+ Return ``self`` over a the new ring ``R``.
753
+
754
+ EXAMPLES::
755
+
756
+ sage: R.<x> = PuiseuxSeriesRing(ZZ)
757
+ sage: p = x^(-7/2) + 3 + 5*x^(1/2) - 7*x**3
758
+ sage: q = p.change_ring(QQ); q
759
+ x^(-7/2) + 3 + 5*x^(1/2) - 7*x^3
760
+ sage: q.parent()
761
+ Puiseux Series Ring in x over Rational Field
762
+ """
763
+ return self._parent.change_ring(R)(self)
764
+
765
+ def is_unit(self):
766
+ r"""
767
+ Return whether ``self`` is a unit.
768
+
769
+ A Puiseux series is a unit if and only if its leading coefficient is.
770
+
771
+ EXAMPLES::
772
+
773
+ sage: R.<x> = PuiseuxSeriesRing(ZZ)
774
+ sage: p = x^(-7/2) + 3 + 5*x^(1/2) - 7*x**3
775
+ sage: p.is_unit()
776
+ True
777
+ sage: q = 4 * x^(-7/2) + 3 * x**4
778
+ sage: q.is_unit()
779
+ False
780
+ """
781
+ return self._l.is_unit()
782
+
783
+ def is_zero(self):
784
+ """
785
+ Return whether ``self`` is zero.
786
+
787
+ EXAMPLES::
788
+
789
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
790
+ sage: p = x^(1/2) + 3/4 * x^(2/3)
791
+ sage: p.is_zero()
792
+ False
793
+ sage: R.zero().is_zero()
794
+ True
795
+ """
796
+ return self._l.is_zero()
797
+
798
+ def is_monomial(self):
799
+ r"""
800
+ Return whether ``self`` is a monomial.
801
+
802
+ This is ``True`` if and only if ``self`` is `x^p` for
803
+ some rational `p`.
804
+
805
+ EXAMPLES::
806
+
807
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
808
+ sage: p = x^(1/2) + 3/4 * x^(2/3)
809
+ sage: p.is_monomial()
810
+ False
811
+ sage: q = x**(11/13)
812
+ sage: q.is_monomial()
813
+ True
814
+ sage: q = 4*x**(11/13)
815
+ sage: q.is_monomial()
816
+ False
817
+ """
818
+ return self._l.is_monomial()
819
+
820
+ def list(self):
821
+ r"""
822
+ Return the list of coefficients indexed by the exponents of the
823
+ the corresponding Laurent series.
824
+
825
+ EXAMPLES::
826
+
827
+ sage: R.<x> = PuiseuxSeriesRing(ZZ)
828
+ sage: p = x^(3/4) + 2*x^(4/5) + 3* x^(5/6)
829
+ sage: p.list()
830
+ [1, 0, 0, 2, 0, 3]
831
+ """
832
+ return self._l.list()
833
+
834
+ def coefficients(self):
835
+ r"""
836
+ Return the list of coefficients.
837
+
838
+ EXAMPLES::
839
+
840
+ sage: R.<x> = PuiseuxSeriesRing(ZZ)
841
+ sage: p = x^(3/4) + 2*x^(4/5) + 3* x^(5/6)
842
+ sage: p.coefficients()
843
+ [1, 2, 3]
844
+ """
845
+ return self._l.coefficients()
846
+
847
+ def exponents(self):
848
+ r"""
849
+ Return the list of exponents.
850
+
851
+ EXAMPLES::
852
+
853
+ sage: R.<x> = PuiseuxSeriesRing(ZZ)
854
+ sage: p = x^(3/4) + 2*x^(4/5) + 3* x^(5/6)
855
+ sage: p.exponents()
856
+ [3/4, 4/5, 5/6]
857
+ """
858
+ return [QQ(n) / self._e for n in self._l.exponents()]
859
+
860
+ def __setitem__(self, n, value):
861
+ """
862
+ EXAMPLES::
863
+
864
+ sage: R.<t> = PuiseuxSeriesRing(QQ)
865
+ sage: f = t^2 + t^3 + O(t^10)
866
+ sage: f[2] = 5
867
+ Traceback (most recent call last):
868
+ ...
869
+ IndexError: Puiseux series are immutable
870
+ """
871
+ raise IndexError('Puiseux series are immutable')
872
+
873
+ def degree(self):
874
+ r"""
875
+ Return the degree of ``self``.
876
+
877
+ EXAMPLES::
878
+
879
+ sage: P.<y> = PolynomialRing(GF(5))
880
+ sage: R.<x> = PuiseuxSeriesRing(P)
881
+ sage: p = 3*y*x**(-2/3) + 2*y**2*x**(1/5); p
882
+ 3*y*x^(-2/3) + 2*y^2*x^(1/5)
883
+ sage: p.degree()
884
+ 1/5
885
+ """
886
+ return self._l.degree() / self._e
887
+
888
+ def shift(self, r):
889
+ r"""
890
+ Return this Puiseux series multiplied by `x^r`.
891
+
892
+ EXAMPLES::
893
+
894
+ sage: P.<y> = LaurentPolynomialRing(ZZ)
895
+ sage: R.<x> = PuiseuxSeriesRing(P)
896
+ sage: p = y*x**(-1/3) + 2*y^(-2)*x**(1/2); p
897
+ y*x^(-1/3) + (2*y^-2)*x^(1/2)
898
+ sage: p.shift(3)
899
+ y*x^(8/3) + (2*y^-2)*x^(7/2)
900
+ """
901
+ cdef LaurentSeries l = self._l.shift(r * self._e)
902
+ return PuiseuxSeries(self._parent, l, self._e)
903
+
904
+ def truncate(self, r):
905
+ r"""
906
+ Return the Puiseux series of degree `< r`.
907
+
908
+ This is equivalent to ``self`` modulo `x^r`.
909
+
910
+ EXAMPLES::
911
+
912
+ sage: R.<x> = PuiseuxSeriesRing(ZZ)
913
+ sage: p = (x**(-1/3) + 2*x**3)**2; p
914
+ x^(-2/3) + 4*x^(8/3) + 4*x^6
915
+ sage: q = p.truncate(5); q
916
+ x^(-2/3) + 4*x^(8/3)
917
+ sage: q == p.add_bigoh(5)
918
+ True
919
+ """
920
+ l = self._l.truncate(r * self._e)
921
+ return PuiseuxSeries(self._parent, l, self._e)
922
+
923
+ def prec(self):
924
+ r"""
925
+ Return the precision of ``self``.
926
+
927
+ EXAMPLES::
928
+
929
+ sage: R.<x> = PuiseuxSeriesRing(ZZ)
930
+ sage: p = (x**(-1/3) + 2*x**3)**2; p
931
+ x^(-2/3) + 4*x^(8/3) + 4*x^6
932
+ sage: q = p.add_bigoh(5); q
933
+ x^(-2/3) + 4*x^(8/3) + O(x^5)
934
+ sage: q.prec()
935
+ 5
936
+ """
937
+ if self._l.prec() is infinity:
938
+ return infinity
939
+ return self._l.prec() / self._e
940
+
941
+ precision_absolute = prec
942
+
943
+ def precision_relative(self):
944
+ r"""
945
+ Return the relative precision of the series.
946
+
947
+ The relative precision of the Puiseux series is the difference
948
+ between its absolute precision and its valuation.
949
+
950
+ EXAMPLES::
951
+
952
+ sage: R.<x> = PuiseuxSeriesRing(GF(3))
953
+ sage: p = (x**(-1/3) + 2*x**3)**2; p
954
+ x^(-2/3) + x^(8/3) + x^6
955
+ sage: q = p.add_bigoh(7); q
956
+ x^(-2/3) + x^(8/3) + x^6 + O(x^7)
957
+ sage: q.precision_relative()
958
+ 23/3
959
+ """
960
+ if self.is_zero():
961
+ return 0
962
+ return self.prec() - self.valuation()
963
+
964
+ def common_prec(self, p):
965
+ r"""
966
+ Return the minimum precision of `p` and ``self``.
967
+
968
+ EXAMPLES::
969
+
970
+ sage: R.<x> = PuiseuxSeriesRing(ZZ)
971
+ sage: p = (x**(-1/3) + 2*x**3)**2
972
+ sage: q5 = p.add_bigoh(5); q5
973
+ x^(-2/3) + 4*x^(8/3) + O(x^5)
974
+ sage: q7 = p.add_bigoh(7); q7
975
+ x^(-2/3) + 4*x^(8/3) + 4*x^6 + O(x^7)
976
+ sage: q5.common_prec(q7)
977
+ 5
978
+ sage: q7.common_prec(q5)
979
+ 5
980
+ """
981
+ if self.prec() is infinity:
982
+ return p.prec()
983
+ elif p.prec() is infinity:
984
+ return self.prec()
985
+ return min(self.prec(), p.prec())
986
+
987
+ def variable(self):
988
+ r"""
989
+ Return the variable of ``self``.
990
+
991
+ EXAMPLES::
992
+
993
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
994
+ sage: p = x^(-7/2) + 3 + 5*x^(1/2) - 7*x**3
995
+ sage: p.variable()
996
+ 'x'
997
+ """
998
+ return self._parent.variable_name()
999
+
1000
+ def laurent_series(self):
1001
+ r"""
1002
+ If ``self`` is a Laurent series, return it as a Laurent series.
1003
+
1004
+ EXAMPLES::
1005
+
1006
+ sage: R.<x> = PuiseuxSeriesRing(ZZ)
1007
+ sage: p = x**(1/2) - x**(-1/2)
1008
+ sage: p.laurent_series()
1009
+ Traceback (most recent call last):
1010
+ ...
1011
+ ArithmeticError: self is not a Laurent series
1012
+ sage: q = p**2
1013
+ sage: q.laurent_series()
1014
+ x^-1 - 2 + x
1015
+ """
1016
+ if self._e != 1:
1017
+ raise ArithmeticError('self is not a Laurent series')
1018
+ return self._l
1019
+
1020
+ def power_series(self):
1021
+ r"""
1022
+ If ``self`` is a power series, return it as a power series.
1023
+
1024
+ EXAMPLES::
1025
+
1026
+ sage: # needs sage.rings.number_field
1027
+ sage: R.<x> = PuiseuxSeriesRing(QQbar)
1028
+ sage: p = x**(3/2) - QQbar(I)*x**(1/2)
1029
+ sage: p.power_series()
1030
+ Traceback (most recent call last):
1031
+ ...
1032
+ ArithmeticError: self is not a power series
1033
+ sage: q = p**2
1034
+ sage: q.power_series()
1035
+ -x - 2*I*x^2 + x^3
1036
+ """
1037
+ try:
1038
+ l = self.laurent_series()
1039
+ return l.power_series()
1040
+ except ArithmeticError:
1041
+ raise ArithmeticError('self is not a power series')
1042
+
1043
+ def inverse(self):
1044
+ r"""
1045
+ Return the inverse of ``self``.
1046
+
1047
+ EXAMPLES::
1048
+
1049
+ sage: R.<x> = PuiseuxSeriesRing(QQ)
1050
+ sage: p = x^(-7/2) + 3 + 5*x^(1/2) - 7*x**3
1051
+ sage: 1/p
1052
+ x^(7/2) - 3*x^7 - 5*x^(15/2) + 7*x^10 + 9*x^(21/2) + 30*x^11 +
1053
+ 25*x^(23/2) + O(x^(27/2))
1054
+ """
1055
+ return self.__invert__()