passagemath-pari 10.6.32__cp314-cp314-musllinux_1_2_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.
Potentially problematic release.
This version of passagemath-pari might be problematic. Click here for more details.
- PARIKernel/__init__.py +2 -0
- PARIKernel/__main__.py +5 -0
- PARIKernel/io.cpython-314-x86_64-linux-musl.so +0 -0
- PARIKernel/io.pxd +7 -0
- PARIKernel/io.pyx +84 -0
- PARIKernel/kernel.cpython-314-x86_64-linux-musl.so +0 -0
- PARIKernel/kernel.pyx +260 -0
- PARIKernel/paridecl.pxd +95 -0
- PARIKernel/svg.cpython-314-x86_64-linux-musl.so +0 -0
- PARIKernel/svg.pyx +52 -0
- cypari2/__init__.py +8 -0
- cypari2/auto_paridecl.pxd +1070 -0
- cypari2/closure.cpython-314-x86_64-linux-musl.so +0 -0
- cypari2/closure.pxd +5 -0
- cypari2/closure.pyx +246 -0
- cypari2/convert.cpython-314-x86_64-linux-musl.so +0 -0
- cypari2/convert.pxd +80 -0
- cypari2/convert.pyx +613 -0
- cypari2/custom_block.cpython-314-x86_64-linux-musl.so +0 -0
- cypari2/custom_block.pyx +30 -0
- cypari2/cypari.h +13 -0
- cypari2/gen.cpython-314-x86_64-linux-musl.so +0 -0
- cypari2/gen.pxd +69 -0
- cypari2/gen.pyx +4819 -0
- cypari2/handle_error.cpython-314-x86_64-linux-musl.so +0 -0
- cypari2/handle_error.pxd +7 -0
- cypari2/handle_error.pyx +232 -0
- cypari2/pari_instance.cpython-314-x86_64-linux-musl.so +0 -0
- cypari2/pari_instance.pxd +27 -0
- cypari2/pari_instance.pyx +1438 -0
- cypari2/paridecl.pxd +5353 -0
- cypari2/paripriv.pxd +34 -0
- cypari2/pycore_long.h +98 -0
- cypari2/pycore_long.pxd +9 -0
- cypari2/stack.cpython-314-x86_64-linux-musl.so +0 -0
- cypari2/stack.pxd +27 -0
- cypari2/stack.pyx +278 -0
- cypari2/string_utils.cpython-314-x86_64-linux-musl.so +0 -0
- cypari2/string_utils.pxd +29 -0
- cypari2/string_utils.pyx +65 -0
- cypari2/types.pxd +147 -0
- passagemath_pari-10.6.32.data/data/etc/jupyter/nbconfig/notebook.d/gp-mode.json +5 -0
- passagemath_pari-10.6.32.data/data/share/jupyter/kernels/pari_jupyter/kernel.js +28 -0
- passagemath_pari-10.6.32.data/data/share/jupyter/kernels/pari_jupyter/kernel.json +6 -0
- passagemath_pari-10.6.32.data/data/share/jupyter/kernels/pari_jupyter/logo-64x64.png +0 -0
- passagemath_pari-10.6.32.data/data/share/jupyter/kernels/xeus-gp/kernel.json +13 -0
- passagemath_pari-10.6.32.data/data/share/jupyter/kernels/xeus-gp/logo-32x32.png +0 -0
- passagemath_pari-10.6.32.data/data/share/jupyter/kernels/xeus-gp/logo-64x64.png +0 -0
- passagemath_pari-10.6.32.data/data/share/jupyter/kernels/xeus-gp/logo-svg.svg +75 -0
- passagemath_pari-10.6.32.data/data/share/jupyter/nbextensions/gp-mode/gp.js +284 -0
- passagemath_pari-10.6.32.data/data/share/jupyter/nbextensions/gp-mode/main.js +15 -0
- passagemath_pari-10.6.32.dist-info/METADATA +209 -0
- passagemath_pari-10.6.32.dist-info/RECORD +331 -0
- passagemath_pari-10.6.32.dist-info/WHEEL +5 -0
- passagemath_pari-10.6.32.dist-info/top_level.txt +4 -0
- passagemath_pari.libs/libcrypto-f04afe95.so.3 +0 -0
- passagemath_pari.libs/libflint-fd6f12fc.so.21.0.0 +0 -0
- passagemath_pari.libs/libgcc_s-0cd532bd.so.1 +0 -0
- passagemath_pari.libs/libgf2x-9e30c3e3.so.3.0.0 +0 -0
- passagemath_pari.libs/libgfortran-2c33b284.so.5.0.0 +0 -0
- passagemath_pari.libs/libgivaro-9a94c711.so.9.2.1 +0 -0
- passagemath_pari.libs/libgmp-0e7fc84e.so.10.5.0 +0 -0
- passagemath_pari.libs/libgmpxx-9e08595c.so.4.7.0 +0 -0
- passagemath_pari.libs/libgsl-42cda06f.so.28.0.0 +0 -0
- passagemath_pari.libs/libmpfr-aaecbfc0.so.6.2.1 +0 -0
- passagemath_pari.libs/libncursesw-9c9e32c3.so.6.5 +0 -0
- passagemath_pari.libs/libntl-26885ca2.so.44.0.1 +0 -0
- passagemath_pari.libs/libopenblasp-r0-905cb27d.3.29.so +0 -0
- passagemath_pari.libs/libpari-gmp-tls-f31f908f.so.2.17.2 +0 -0
- passagemath_pari.libs/libquadmath-bb76a5fc.so.0.0.0 +0 -0
- passagemath_pari.libs/libreadline-06542304.so.8.2 +0 -0
- passagemath_pari.libs/libstdc++-5d72f927.so.6.0.33 +0 -0
- passagemath_pari.libs/libuuid-f3770415.so.1.3.0 +0 -0
- passagemath_pari.libs/libxeus-735780ff.so.13.1.0 +0 -0
- passagemath_pari.libs/libxeus-zmq-c68577b4.so.6.0.1 +0 -0
- passagemath_pari.libs/libzmq-1ba9a3da.so.5.2.5 +0 -0
- sage/all__sagemath_pari.py +26 -0
- sage/databases/all__sagemath_pari.py +7 -0
- sage/databases/conway.py +274 -0
- sage/ext/all__sagemath_pari.py +1 -0
- sage/ext/memory.cpython-314-x86_64-linux-musl.so +0 -0
- sage/ext/memory.pyx +98 -0
- sage/ext_data/pari/buzzard/DimensionSk.g +286 -0
- sage/ext_data/pari/buzzard/Tpprog.g +179 -0
- sage/ext_data/pari/buzzard/genusn.g +129 -0
- sage/ext_data/pari/dokchitser/computel.gp +740 -0
- sage/ext_data/pari/dokchitser/computel.gp.template +740 -0
- sage/ext_data/pari/dokchitser/ex-bsw +43 -0
- sage/ext_data/pari/dokchitser/ex-chgen +48 -0
- sage/ext_data/pari/dokchitser/ex-chqua +37 -0
- sage/ext_data/pari/dokchitser/ex-delta +35 -0
- sage/ext_data/pari/dokchitser/ex-eisen +30 -0
- sage/ext_data/pari/dokchitser/ex-gen2 +38 -0
- sage/ext_data/pari/dokchitser/ex-gen3 +49 -0
- sage/ext_data/pari/dokchitser/ex-gen4 +54 -0
- sage/ext_data/pari/dokchitser/ex-nf +48 -0
- sage/ext_data/pari/dokchitser/ex-shin +50 -0
- sage/ext_data/pari/dokchitser/ex-tau2 +30 -0
- sage/ext_data/pari/dokchitser/ex-zeta +27 -0
- sage/ext_data/pari/dokchitser/ex-zeta2 +47 -0
- sage/ext_data/pari/dokchitser/testall +13 -0
- sage/ext_data/pari/simon/ell.gp +2129 -0
- sage/ext_data/pari/simon/ellQ.gp +2151 -0
- sage/ext_data/pari/simon/ellcommon.gp +126 -0
- sage/ext_data/pari/simon/qfsolve.gp +722 -0
- sage/ext_data/pari/simon/resultant3.gp +306 -0
- sage/groups/all__sagemath_pari.py +3 -0
- sage/groups/pari_group.py +175 -0
- sage/interfaces/all__sagemath_pari.py +1 -0
- sage/interfaces/genus2reduction.py +464 -0
- sage/interfaces/gp.py +1114 -0
- sage/libs/all__sagemath_pari.py +2 -0
- sage/libs/linkages/__init__.py +1 -0
- sage/libs/linkages/padics/API.pxi +617 -0
- sage/libs/linkages/padics/Polynomial_ram.pxi +388 -0
- sage/libs/linkages/padics/Polynomial_shared.pxi +554 -0
- sage/libs/linkages/padics/__init__.py +1 -0
- sage/libs/linkages/padics/fmpz_poly_unram.pxi +869 -0
- sage/libs/linkages/padics/mpz.pxi +691 -0
- sage/libs/linkages/padics/relaxed/API.pxi +518 -0
- sage/libs/linkages/padics/relaxed/__init__.py +1 -0
- sage/libs/linkages/padics/relaxed/flint.pxi +543 -0
- sage/libs/linkages/padics/unram_shared.pxi +247 -0
- sage/libs/pari/__init__.py +210 -0
- sage/libs/pari/all.py +5 -0
- sage/libs/pari/convert_flint.cpython-314-x86_64-linux-musl.so +0 -0
- sage/libs/pari/convert_flint.pxd +14 -0
- sage/libs/pari/convert_flint.pyx +159 -0
- sage/libs/pari/convert_gmp.cpython-314-x86_64-linux-musl.so +0 -0
- sage/libs/pari/convert_gmp.pxd +14 -0
- sage/libs/pari/convert_gmp.pyx +210 -0
- sage/libs/pari/convert_sage.cpython-314-x86_64-linux-musl.so +0 -0
- sage/libs/pari/convert_sage.pxd +16 -0
- sage/libs/pari/convert_sage.pyx +588 -0
- sage/libs/pari/convert_sage_complex_double.cpython-314-x86_64-linux-musl.so +0 -0
- sage/libs/pari/convert_sage_complex_double.pxd +14 -0
- sage/libs/pari/convert_sage_complex_double.pyx +132 -0
- sage/libs/pari/convert_sage_matrix.cpython-314-x86_64-linux-musl.so +0 -0
- sage/libs/pari/convert_sage_matrix.pyx +106 -0
- sage/libs/pari/convert_sage_real_double.cpython-314-x86_64-linux-musl.so +0 -0
- sage/libs/pari/convert_sage_real_double.pxd +5 -0
- sage/libs/pari/convert_sage_real_double.pyx +14 -0
- sage/libs/pari/convert_sage_real_mpfr.cpython-314-x86_64-linux-musl.so +0 -0
- sage/libs/pari/convert_sage_real_mpfr.pxd +7 -0
- sage/libs/pari/convert_sage_real_mpfr.pyx +108 -0
- sage/libs/pari/misc.cpython-314-x86_64-linux-musl.so +0 -0
- sage/libs/pari/misc.pxd +4 -0
- sage/libs/pari/misc.pyx +26 -0
- sage/libs/pari/tests.py +1848 -0
- sage/matrix/all__sagemath_pari.py +1 -0
- sage/matrix/matrix_integer_pari.cpython-314-x86_64-linux-musl.so +0 -0
- sage/matrix/matrix_integer_pari.pyx +187 -0
- sage/matrix/matrix_rational_pari.cpython-314-x86_64-linux-musl.so +0 -0
- sage/matrix/matrix_rational_pari.pyx +160 -0
- sage/quadratic_forms/all__sagemath_pari.py +10 -0
- sage/quadratic_forms/genera/all.py +9 -0
- sage/quadratic_forms/genera/genus.py +3506 -0
- sage/quadratic_forms/genera/normal_form.py +1519 -0
- sage/quadratic_forms/genera/spinor_genus.py +243 -0
- sage/quadratic_forms/qfsolve.py +255 -0
- sage/quadratic_forms/quadratic_form__automorphisms.py +427 -0
- sage/quadratic_forms/quadratic_form__genus.py +141 -0
- sage/quadratic_forms/quadratic_form__local_density_interfaces.py +140 -0
- sage/quadratic_forms/quadratic_form__local_normal_form.py +421 -0
- sage/quadratic_forms/quadratic_form__local_representation_conditions.py +889 -0
- sage/quadratic_forms/quadratic_form__mass.py +69 -0
- sage/quadratic_forms/quadratic_form__mass__Conway_Sloane_masses.py +663 -0
- sage/quadratic_forms/quadratic_form__mass__Siegel_densities.py +373 -0
- sage/quadratic_forms/quadratic_form__siegel_product.py +198 -0
- sage/quadratic_forms/special_values.py +323 -0
- sage/rings/all__sagemath_pari.py +15 -0
- sage/rings/factorint_pari.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/factorint_pari.pyx +80 -0
- sage/rings/finite_rings/all__sagemath_pari.py +1 -0
- sage/rings/finite_rings/element_givaro.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/finite_rings/element_givaro.pxd +91 -0
- sage/rings/finite_rings/element_givaro.pyx +1769 -0
- sage/rings/finite_rings/element_ntl_gf2e.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/finite_rings/element_ntl_gf2e.pxd +22 -0
- sage/rings/finite_rings/element_ntl_gf2e.pyx +1333 -0
- sage/rings/finite_rings/element_pari_ffelt.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/finite_rings/element_pari_ffelt.pxd +13 -0
- sage/rings/finite_rings/element_pari_ffelt.pyx +1441 -0
- sage/rings/finite_rings/finite_field_givaro.py +612 -0
- sage/rings/finite_rings/finite_field_pari_ffelt.py +238 -0
- sage/rings/finite_rings/hom_finite_field_givaro.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/finite_rings/hom_finite_field_givaro.pxd +28 -0
- sage/rings/finite_rings/hom_finite_field_givaro.pyx +280 -0
- sage/rings/finite_rings/residue_field_givaro.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/finite_rings/residue_field_givaro.pyx +133 -0
- sage/rings/finite_rings/residue_field_pari_ffelt.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/finite_rings/residue_field_pari_ffelt.pyx +128 -0
- sage/rings/function_field/all__sagemath_pari.py +1 -0
- sage/rings/function_field/valuation.py +1450 -0
- sage/rings/function_field/valuation_ring.py +212 -0
- sage/rings/number_field/all__sagemath_pari.py +14 -0
- sage/rings/number_field/totallyreal.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/number_field/totallyreal.pyx +509 -0
- sage/rings/number_field/totallyreal_data.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/number_field/totallyreal_data.pxd +26 -0
- sage/rings/number_field/totallyreal_data.pyx +928 -0
- sage/rings/number_field/totallyreal_phc.py +144 -0
- sage/rings/number_field/totallyreal_rel.py +1018 -0
- sage/rings/padics/CA_template.pxi +1847 -0
- sage/rings/padics/CA_template_header.pxi +50 -0
- sage/rings/padics/CR_template.pxi +2563 -0
- sage/rings/padics/CR_template_header.pxi +57 -0
- sage/rings/padics/FM_template.pxi +1575 -0
- sage/rings/padics/FM_template_header.pxi +50 -0
- sage/rings/padics/FP_template.pxi +2176 -0
- sage/rings/padics/FP_template_header.pxi +57 -0
- sage/rings/padics/all.py +3 -0
- sage/rings/padics/all__sagemath_pari.py +11 -0
- sage/rings/padics/common_conversion.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/common_conversion.pxd +15 -0
- sage/rings/padics/common_conversion.pyx +508 -0
- sage/rings/padics/eisenstein_extension_generic.py +232 -0
- sage/rings/padics/factory.py +3623 -0
- sage/rings/padics/generic_nodes.py +1615 -0
- sage/rings/padics/lattice_precision.py +2889 -0
- sage/rings/padics/morphism.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/morphism.pxd +11 -0
- sage/rings/padics/morphism.pyx +366 -0
- sage/rings/padics/padic_base_generic.py +467 -0
- sage/rings/padics/padic_base_leaves.py +1235 -0
- sage/rings/padics/padic_capped_absolute_element.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/padic_capped_absolute_element.pxd +15 -0
- sage/rings/padics/padic_capped_absolute_element.pyx +520 -0
- sage/rings/padics/padic_capped_relative_element.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/padic_capped_relative_element.pxd +14 -0
- sage/rings/padics/padic_capped_relative_element.pyx +614 -0
- sage/rings/padics/padic_extension_generic.py +990 -0
- sage/rings/padics/padic_extension_leaves.py +738 -0
- sage/rings/padics/padic_fixed_mod_element.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/padic_fixed_mod_element.pxd +15 -0
- sage/rings/padics/padic_fixed_mod_element.pyx +584 -0
- sage/rings/padics/padic_floating_point_element.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/padic_floating_point_element.pxd +14 -0
- sage/rings/padics/padic_floating_point_element.pyx +447 -0
- sage/rings/padics/padic_generic_element.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/padic_generic_element.pxd +48 -0
- sage/rings/padics/padic_generic_element.pyx +4642 -0
- sage/rings/padics/padic_lattice_element.py +1342 -0
- sage/rings/padics/padic_printing.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/padic_printing.pxd +38 -0
- sage/rings/padics/padic_printing.pyx +1505 -0
- sage/rings/padics/padic_relaxed_element.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/padic_relaxed_element.pxd +56 -0
- sage/rings/padics/padic_relaxed_element.pyx +18 -0
- sage/rings/padics/padic_relaxed_errors.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/padic_relaxed_errors.pxd +11 -0
- sage/rings/padics/padic_relaxed_errors.pyx +71 -0
- sage/rings/padics/padic_template_element.pxi +1212 -0
- sage/rings/padics/padic_template_element_header.pxi +50 -0
- sage/rings/padics/padic_valuation.py +1423 -0
- sage/rings/padics/pow_computer_flint.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/pow_computer_flint.pxd +38 -0
- sage/rings/padics/pow_computer_flint.pyx +641 -0
- sage/rings/padics/pow_computer_relative.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/pow_computer_relative.pxd +29 -0
- sage/rings/padics/pow_computer_relative.pyx +415 -0
- sage/rings/padics/qadic_flint_CA.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/qadic_flint_CA.pxd +21 -0
- sage/rings/padics/qadic_flint_CA.pyx +130 -0
- sage/rings/padics/qadic_flint_CR.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/qadic_flint_CR.pxd +13 -0
- sage/rings/padics/qadic_flint_CR.pyx +172 -0
- sage/rings/padics/qadic_flint_FM.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/qadic_flint_FM.pxd +14 -0
- sage/rings/padics/qadic_flint_FM.pyx +111 -0
- sage/rings/padics/qadic_flint_FP.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/qadic_flint_FP.pxd +12 -0
- sage/rings/padics/qadic_flint_FP.pyx +165 -0
- sage/rings/padics/relative_extension_leaves.py +429 -0
- sage/rings/padics/relative_ramified_CA.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/relative_ramified_CA.pxd +9 -0
- sage/rings/padics/relative_ramified_CA.pyx +33 -0
- sage/rings/padics/relative_ramified_CR.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/relative_ramified_CR.pxd +8 -0
- sage/rings/padics/relative_ramified_CR.pyx +33 -0
- sage/rings/padics/relative_ramified_FM.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/relative_ramified_FM.pxd +9 -0
- sage/rings/padics/relative_ramified_FM.pyx +33 -0
- sage/rings/padics/relative_ramified_FP.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/padics/relative_ramified_FP.pxd +8 -0
- sage/rings/padics/relative_ramified_FP.pyx +33 -0
- sage/rings/padics/relaxed_template.pxi +4229 -0
- sage/rings/padics/relaxed_template_header.pxi +160 -0
- sage/rings/padics/tests.py +35 -0
- sage/rings/padics/tutorial.py +341 -0
- sage/rings/padics/unramified_extension_generic.py +335 -0
- sage/rings/padics/witt_vector.py +917 -0
- sage/rings/padics/witt_vector_ring.py +934 -0
- sage/rings/pari_ring.py +235 -0
- sage/rings/polynomial/all__sagemath_pari.py +1 -0
- sage/rings/polynomial/padics/all.py +1 -0
- sage/rings/polynomial/padics/polynomial_padic.py +360 -0
- sage/rings/polynomial/padics/polynomial_padic_capped_relative_dense.py +1324 -0
- sage/rings/polynomial/padics/polynomial_padic_flat.py +72 -0
- sage/rings/power_series_pari.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/power_series_pari.pxd +6 -0
- sage/rings/power_series_pari.pyx +934 -0
- sage/rings/tate_algebra.py +1282 -0
- sage/rings/tate_algebra_element.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/tate_algebra_element.pxd +49 -0
- sage/rings/tate_algebra_element.pyx +3464 -0
- sage/rings/tate_algebra_ideal.cpython-314-x86_64-linux-musl.so +0 -0
- sage/rings/tate_algebra_ideal.pxd +7 -0
- sage/rings/tate_algebra_ideal.pyx +1307 -0
- sage/rings/valuation/all.py +7 -0
- sage/rings/valuation/augmented_valuation.py +2118 -0
- sage/rings/valuation/developing_valuation.py +362 -0
- sage/rings/valuation/gauss_valuation.py +812 -0
- sage/rings/valuation/inductive_valuation.py +1686 -0
- sage/rings/valuation/limit_valuation.py +946 -0
- sage/rings/valuation/mapped_valuation.py +656 -0
- sage/rings/valuation/scaled_valuation.py +322 -0
- sage/rings/valuation/trivial_valuation.py +382 -0
- sage/rings/valuation/valuation.py +1119 -0
- sage/rings/valuation/valuation_space.py +1615 -0
- sage/rings/valuation/valuations_catalog.py +10 -0
- sage/rings/valuation/value_group.py +697 -0
- sage/schemes/all__sagemath_pari.py +1 -0
- sage/schemes/elliptic_curves/all__sagemath_pari.py +1 -0
- sage/schemes/elliptic_curves/descent_two_isogeny_pari.cpython-314-x86_64-linux-musl.so +0 -0
- sage/schemes/elliptic_curves/descent_two_isogeny_pari.pyx +46 -0
- sage_wheels/bin/gp +0 -0
- sage_wheels/bin/gp2c +0 -0
- sage_wheels/bin/gp2c-run +57 -0
- sage_wheels/bin/xeus-gp +0 -0
- sage_wheels/share/gp2c/func.dsc +18414 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
# sage_setup: distribution = sagemath-pari
|
|
@@ -0,0 +1,617 @@
|
|
|
1
|
+
# sage_setup: distribution = sagemath-pari
|
|
2
|
+
"""
|
|
3
|
+
This file defines the common API for p-adic elements.
|
|
4
|
+
Elements using different precision models (e.g. capped relative,
|
|
5
|
+
capped absolute and fixed modulus) can plug in different linkage
|
|
6
|
+
files. By separating the linkage file from the precision templates we
|
|
7
|
+
reduce code duplication.
|
|
8
|
+
|
|
9
|
+
Each linkage file should implement the following functions. These
|
|
10
|
+
functions will be implemented for many backends, usually in C (thus
|
|
11
|
+
the c at the beginning of the function names). The remainder of the
|
|
12
|
+
file gives the function signatures.
|
|
13
|
+
|
|
14
|
+
- :meth:`cconstruct` -- construct a new element
|
|
15
|
+
- :meth:`cdestruct` -- deallocate an element
|
|
16
|
+
- :meth:`ccmp` -- comparison of two elements
|
|
17
|
+
- :meth:`cneg` -- negation
|
|
18
|
+
- :meth:`cadd` -- addition
|
|
19
|
+
- :meth:`creduce` -- reduce modulo a power of the maximal ideal
|
|
20
|
+
- :meth:`creduce_small` -- reduce modulo a power of the maximal ideal,
|
|
21
|
+
assuming only a single addition/subtraction
|
|
22
|
+
- :meth:`cremove` -- extract the maximum power of the uniformizer
|
|
23
|
+
dividing this element
|
|
24
|
+
- :meth:`cvaluation` -- return the maximum power of the uniformizer
|
|
25
|
+
dividing this element
|
|
26
|
+
- :meth:`cisunit` -- returns whether this element has valuation zero
|
|
27
|
+
- :meth:`cshift` -- multiplies by a power of the uniformizer
|
|
28
|
+
- :meth:`cshift_notrunc` -- multiplies by a power of the uniformizer,
|
|
29
|
+
assuming no truncation
|
|
30
|
+
- :meth:`csub` -- subtraction
|
|
31
|
+
- :meth:`cinvert` -- inversion
|
|
32
|
+
- :meth:`cmul` -- multiplication
|
|
33
|
+
- :meth:`cdivunit` -- division
|
|
34
|
+
- :meth:`csetone` -- sets to 1
|
|
35
|
+
- :meth:`csetzero` -- sets to 0
|
|
36
|
+
- :meth:`cisone` -- tests for equality with 1
|
|
37
|
+
- :meth:`ciszero` -- tests for equality with 0
|
|
38
|
+
- :meth:`cpow` -- exponentiation
|
|
39
|
+
- :meth:`ccopy` -- copying
|
|
40
|
+
- :meth:`cpickle` -- serialization into objects that Sage knows how to
|
|
41
|
+
pickle
|
|
42
|
+
- :meth:`cunpickle` -- reconstruction from the output of :meth:`cpickle`
|
|
43
|
+
- :meth:`chash` -- hashing
|
|
44
|
+
- :meth:`cexpansion_next` -- gets the next digit in the series expansion
|
|
45
|
+
- :meth:`cexpansion_getitem` -- gets a specified digit in the series expansion
|
|
46
|
+
- :meth:`ccoefficients` -- list of coefficients as elements of the base ring
|
|
47
|
+
- :meth:`cteichmuller` -- Teichmuller lifting
|
|
48
|
+
- :meth:`cconv` -- conversion from other types in Sage
|
|
49
|
+
- :meth:`cconv_mpz_t` -- conversion from mpz_t, separated for speed and
|
|
50
|
+
convenience
|
|
51
|
+
- :meth:`cconv_mpq_t` -- conversion from mpq_t, separated for speed and
|
|
52
|
+
convenience
|
|
53
|
+
- :meth:`cconv_mpz_t_out` -- conversion into an mpz_t
|
|
54
|
+
- :meth:`cconv_mpq_t_out` -- conversion into an mpq_t
|
|
55
|
+
- _expansion_zero -- the entry that should be used for zero in p-adic expansions
|
|
56
|
+
|
|
57
|
+
The gluing file should ctypedef celement as appropriate.
|
|
58
|
+
|
|
59
|
+
.. NOTE::
|
|
60
|
+
|
|
61
|
+
This particular file is not included anywhere. It just defines
|
|
62
|
+
the interface implemented by other pxi files in this directory.
|
|
63
|
+
|
|
64
|
+
AUTHORS:
|
|
65
|
+
|
|
66
|
+
- David Roe (2012-3-1) -- initial version
|
|
67
|
+
"""
|
|
68
|
+
|
|
69
|
+
#*****************************************************************************
|
|
70
|
+
# Copyright (C) 2012 David Roe <roed@math.harvard.edu>
|
|
71
|
+
# William Stein <wstein@gmail.com>
|
|
72
|
+
#
|
|
73
|
+
# Distributed under the terms of the GNU General Public License (GPL)
|
|
74
|
+
# as published by the Free Software Foundation; either version 2 of
|
|
75
|
+
# the License, or (at your option) any later version.
|
|
76
|
+
#
|
|
77
|
+
# http://www.gnu.org/licenses/
|
|
78
|
+
#*****************************************************************************
|
|
79
|
+
|
|
80
|
+
|
|
81
|
+
cdef inline int cconstruct(celement value, PowComputer_class prime_pow) except -1:
|
|
82
|
+
"""
|
|
83
|
+
Construct a new element.
|
|
84
|
+
|
|
85
|
+
INPUT:
|
|
86
|
+
|
|
87
|
+
- ``unit`` -- an ``celement`` to be initialized
|
|
88
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
89
|
+
"""
|
|
90
|
+
pass
|
|
91
|
+
|
|
92
|
+
cdef inline int cdestruct(celement value, PowComputer_class prime_pow) except -1:
|
|
93
|
+
"""
|
|
94
|
+
Deallocate an element.
|
|
95
|
+
|
|
96
|
+
INPUT:
|
|
97
|
+
|
|
98
|
+
- ``unit`` -- an ``celement`` to be cleared
|
|
99
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
100
|
+
"""
|
|
101
|
+
pass
|
|
102
|
+
|
|
103
|
+
cdef inline int ccmp(celement a, celement b, long prec, bint reduce_a, bint reduce_b, PowComputer_class prime_pow) except -2:
|
|
104
|
+
"""
|
|
105
|
+
Comparison of two elements.
|
|
106
|
+
|
|
107
|
+
INPUT:
|
|
108
|
+
|
|
109
|
+
- ``a`` -- an ``celement``
|
|
110
|
+
- ``b`` -- an ``celement``
|
|
111
|
+
- ``prec`` -- a long, the precision of the comparison
|
|
112
|
+
- ``reduce_a`` -- a bint, whether ``a`` needs to be reduced
|
|
113
|
+
- ``reduce_b`` -- a bint, whether ``b`` needs to be reduced
|
|
114
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
115
|
+
|
|
116
|
+
OUTPUT:
|
|
117
|
+
|
|
118
|
+
- If neither ``a`` nor ``b`` needs to be reduced, returns
|
|
119
|
+
-1 (if `a < b`), 0 (if `a == b`) or 1 (if `a > b`)
|
|
120
|
+
|
|
121
|
+
- If at least one needs to be reduced, returns
|
|
122
|
+
0 (if ``a == b mod p^prec``) or 1 (otherwise)
|
|
123
|
+
"""
|
|
124
|
+
pass
|
|
125
|
+
|
|
126
|
+
cdef inline int cneg(celement out, celement a, long prec, PowComputer_class prime_pow) except -1:
|
|
127
|
+
"""
|
|
128
|
+
Negation
|
|
129
|
+
|
|
130
|
+
Note that no reduction is performed.
|
|
131
|
+
|
|
132
|
+
INPUT:
|
|
133
|
+
|
|
134
|
+
- ``out`` -- an ``celement`` to store the negation
|
|
135
|
+
- ``a`` -- an ``celement`` to be negated
|
|
136
|
+
- ``prec`` -- a long, the precision: ignored
|
|
137
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
138
|
+
"""
|
|
139
|
+
pass
|
|
140
|
+
|
|
141
|
+
cdef inline int cadd(celement out, celement a, celement b, long prec, PowComputer_class prime_pow) except -1:
|
|
142
|
+
"""
|
|
143
|
+
Addition
|
|
144
|
+
|
|
145
|
+
Note that no reduction is performed.
|
|
146
|
+
|
|
147
|
+
INPUT:
|
|
148
|
+
|
|
149
|
+
- ``out`` -- an ``celement`` to store the sum
|
|
150
|
+
- ``a`` -- an ``celement``, the first summand
|
|
151
|
+
- ``b`` -- an ``celement``, the second summand
|
|
152
|
+
- ``prec`` -- a long, the precision: ignored
|
|
153
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
154
|
+
"""
|
|
155
|
+
pass
|
|
156
|
+
|
|
157
|
+
cdef inline bint creduce(celement out, celement a, long prec, PowComputer_class prime_pow) except -1:
|
|
158
|
+
"""
|
|
159
|
+
Reduce modulo a power of the maximal ideal.
|
|
160
|
+
|
|
161
|
+
INPUT:
|
|
162
|
+
|
|
163
|
+
- ``out`` -- an ``celement`` to store the reduction
|
|
164
|
+
- ``a`` -- the element to be reduced
|
|
165
|
+
- ``prec`` -- a long, the precision to reduce modulo
|
|
166
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
167
|
+
|
|
168
|
+
OUTPUT: returns ``True`` if the reduction is zero; ``False`` otherwise
|
|
169
|
+
"""
|
|
170
|
+
pass
|
|
171
|
+
|
|
172
|
+
cdef inline bint creduce_small(celement out, celement a, long prec, PowComputer_class prime_pow) except -1:
|
|
173
|
+
"""
|
|
174
|
+
Reduce modulo a power of the maximal ideal.
|
|
175
|
+
|
|
176
|
+
This function assumes that at most one addition/subtraction has
|
|
177
|
+
happened on reduced inputs. For integral inputs this translates
|
|
178
|
+
to the assumption that `-p^prec < a < 2p^prec`.
|
|
179
|
+
|
|
180
|
+
INPUT:
|
|
181
|
+
|
|
182
|
+
- ``out`` -- an ``celement`` to store the reduction
|
|
183
|
+
- ``a`` -- the element to be reduced
|
|
184
|
+
- ``prec`` -- a long, the precision to reduce modulo
|
|
185
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
186
|
+
|
|
187
|
+
OUTPUT:
|
|
188
|
+
|
|
189
|
+
- returns ``True`` if the reduction is zero; ``False`` otherwise.
|
|
190
|
+
"""
|
|
191
|
+
pass
|
|
192
|
+
|
|
193
|
+
cdef inline long cremove(celement out, celement a, long prec, PowComputer_class prime_pow, bint reduce_relative=False) except -1:
|
|
194
|
+
"""
|
|
195
|
+
Extract the maximum power of the uniformizer dividing this element.
|
|
196
|
+
|
|
197
|
+
INPUT:
|
|
198
|
+
|
|
199
|
+
- ``out`` -- an ``celement`` to store the unit
|
|
200
|
+
- ``a`` -- the element whose valuation and unit are desired
|
|
201
|
+
- ``prec`` -- a long, used if `a = 0`
|
|
202
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
203
|
+
- ``reduce_relative`` -- a bint: whether the final result
|
|
204
|
+
should be reduced at precision ``prec`` (case ``False``)
|
|
205
|
+
or ``prec - valuation`` (case ``True``)
|
|
206
|
+
|
|
207
|
+
OUTPUT:
|
|
208
|
+
|
|
209
|
+
- if `a = 0`, returns prec (the value of ``out`` is undefined).
|
|
210
|
+
Otherwise, returns the number of times `p` divides `a`.
|
|
211
|
+
"""
|
|
212
|
+
pass
|
|
213
|
+
|
|
214
|
+
cdef inline long cvaluation(celement a, long prec, PowComputer_class prime_pow) except -1:
|
|
215
|
+
"""
|
|
216
|
+
Return the maximum power of the uniformizer dividing this
|
|
217
|
+
element.
|
|
218
|
+
|
|
219
|
+
This function differs from :meth:`cremove` in that the unit is
|
|
220
|
+
discarded.
|
|
221
|
+
|
|
222
|
+
INPUT:
|
|
223
|
+
|
|
224
|
+
- ``a`` -- the element whose valuation is desired
|
|
225
|
+
- ``prec`` -- a long, used if `a = 0`
|
|
226
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
227
|
+
|
|
228
|
+
OUTPUT:
|
|
229
|
+
|
|
230
|
+
- if `a = 0`, returns prec. Otherwise, returns the number of
|
|
231
|
+
times p divides a.
|
|
232
|
+
"""
|
|
233
|
+
pass
|
|
234
|
+
|
|
235
|
+
cdef inline bint cisunit(celement a, PowComputer_class prime_pow) except -1:
|
|
236
|
+
"""
|
|
237
|
+
Return whether this element has valuation zero.
|
|
238
|
+
|
|
239
|
+
INPUT:
|
|
240
|
+
|
|
241
|
+
- ``a`` -- the element to test
|
|
242
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
243
|
+
|
|
244
|
+
OUTPUT: returns ``True`` if `a` has valuation 0, and ``False`` otherwise
|
|
245
|
+
"""
|
|
246
|
+
pass
|
|
247
|
+
|
|
248
|
+
cdef inline int cshift(celement out, celement rem, celement a, long n, long prec, PowComputer_class prime_pow, bint reduce_afterward) except -1:
|
|
249
|
+
"""
|
|
250
|
+
Multiply by a power of the uniformizer.
|
|
251
|
+
|
|
252
|
+
INPUT:
|
|
253
|
+
|
|
254
|
+
- ``out`` -- an ``celement`` to store the result. If `n >= 0`
|
|
255
|
+
then out will be set to `a * p^n`
|
|
256
|
+
If `n < 0`, out will be set to `a // p^-n`.
|
|
257
|
+
- ``rem`` -- a ``celement`` to store the remainder, when `n < 0`
|
|
258
|
+
- ``a`` -- the element to shift
|
|
259
|
+
- ``n`` -- long, the amount to shift by
|
|
260
|
+
- ``prec`` -- long, a precision modulo which to reduce
|
|
261
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
262
|
+
- ``reduce_afterward`` -- whether to reduce afterward
|
|
263
|
+
"""
|
|
264
|
+
pass
|
|
265
|
+
|
|
266
|
+
cdef inline int cshift_notrunc(celement out, celement a, long n, long prec, PowComputer_class prime_pow, bint reduce_afterward) except -1:
|
|
267
|
+
"""
|
|
268
|
+
Multiply by a power of the uniformizer, assuming that the
|
|
269
|
+
valuation of a is at least -n.
|
|
270
|
+
|
|
271
|
+
INPUT:
|
|
272
|
+
|
|
273
|
+
- ``out`` -- an ``celement`` to store the result. If `n >= 0`
|
|
274
|
+
then out will be set to `a * p^n`
|
|
275
|
+
If `n < 0`, out will be set to `a // p^-n`.
|
|
276
|
+
- ``a`` -- the element to shift. Assumes that the valuation of a
|
|
277
|
+
is at least -n.
|
|
278
|
+
- ``n`` -- long, the amount to shift by
|
|
279
|
+
- ``prec`` -- long, a precision modulo which to reduce
|
|
280
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
281
|
+
- ``reduce_afterward`` -- whether to reduce afterward
|
|
282
|
+
"""
|
|
283
|
+
pass
|
|
284
|
+
|
|
285
|
+
cdef inline int csub(celement out, celement a, celement b, long prec, PowComputer_class prime_pow) except -1:
|
|
286
|
+
"""
|
|
287
|
+
Subtraction.
|
|
288
|
+
|
|
289
|
+
Note that no reduction is performed.
|
|
290
|
+
|
|
291
|
+
INPUT:
|
|
292
|
+
|
|
293
|
+
- ``out`` -- an ``celement`` to store the difference
|
|
294
|
+
- ``a`` -- an ``celement``, the first input
|
|
295
|
+
- ``b`` -- an ``celement``, the second input
|
|
296
|
+
- ``prec`` -- a long, the precision: ignored
|
|
297
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
298
|
+
"""
|
|
299
|
+
pass
|
|
300
|
+
|
|
301
|
+
cdef inline int cinvert(celement out, celement a, long prec, PowComputer_class prime_pow) except -1:
|
|
302
|
+
"""
|
|
303
|
+
Inversion
|
|
304
|
+
|
|
305
|
+
The result will be reduced modulo p^prec.
|
|
306
|
+
|
|
307
|
+
INPUT:
|
|
308
|
+
|
|
309
|
+
- ``out`` -- an ``celement`` to store the inverse
|
|
310
|
+
- ``a`` -- an ``celement``, the element to be inverted
|
|
311
|
+
- ``prec`` -- a long, the precision
|
|
312
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
313
|
+
"""
|
|
314
|
+
pass
|
|
315
|
+
|
|
316
|
+
cdef inline int cmul(celement out, celement a, celement b, long prec, PowComputer_class prime_pow) except -1:
|
|
317
|
+
"""
|
|
318
|
+
Multiplication.
|
|
319
|
+
|
|
320
|
+
Note that no reduction is performed.
|
|
321
|
+
|
|
322
|
+
INPUT:
|
|
323
|
+
|
|
324
|
+
- ``out`` -- an ``celement`` to store the product
|
|
325
|
+
- ``a`` -- an ``celement``, the first input
|
|
326
|
+
- ``b`` -- an ``celement``, the second input
|
|
327
|
+
- ``prec`` -- a long, the precision: ignored
|
|
328
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
329
|
+
"""
|
|
330
|
+
pass
|
|
331
|
+
|
|
332
|
+
cdef inline int cdivunit(celement out, celement a, celement b, long prec, PowComputer_class prime_pow) except -1:
|
|
333
|
+
"""
|
|
334
|
+
Division.
|
|
335
|
+
|
|
336
|
+
The inversion is performed modulo p^prec. Note that no reduction
|
|
337
|
+
is performed after the product.
|
|
338
|
+
|
|
339
|
+
INPUT:
|
|
340
|
+
|
|
341
|
+
- ``out`` -- an ``celement`` to store the quotient
|
|
342
|
+
- ``a`` -- an ``celement``, the first input
|
|
343
|
+
- ``b`` -- an ``celement``, the second input
|
|
344
|
+
- ``prec`` -- a long, the precision
|
|
345
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
346
|
+
"""
|
|
347
|
+
pass
|
|
348
|
+
|
|
349
|
+
cdef inline int csetone(celement out, PowComputer_class prime_pow) except -1:
|
|
350
|
+
"""
|
|
351
|
+
Set to 1.
|
|
352
|
+
|
|
353
|
+
INPUT:
|
|
354
|
+
|
|
355
|
+
- ``out`` -- the ``celement`` in which to store 1
|
|
356
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
357
|
+
"""
|
|
358
|
+
pass
|
|
359
|
+
|
|
360
|
+
cdef inline int csetzero(celement out, PowComputer_class prime_pow) except -1:
|
|
361
|
+
"""
|
|
362
|
+
Set to 0.
|
|
363
|
+
|
|
364
|
+
INPUT:
|
|
365
|
+
|
|
366
|
+
- ``out`` -- the ``celement`` in which to store 0
|
|
367
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
368
|
+
"""
|
|
369
|
+
pass
|
|
370
|
+
|
|
371
|
+
cdef inline bint cisone(celement a, PowComputer_class prime_pow) except -1:
|
|
372
|
+
"""
|
|
373
|
+
Return whether this element is equal to 1.
|
|
374
|
+
|
|
375
|
+
INPUT:
|
|
376
|
+
|
|
377
|
+
- ``a`` -- the element to test
|
|
378
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
379
|
+
|
|
380
|
+
OUTPUT:
|
|
381
|
+
|
|
382
|
+
- returns ``True`` if `a = 1`, and ``False`` otherwise.
|
|
383
|
+
"""
|
|
384
|
+
pass
|
|
385
|
+
|
|
386
|
+
cdef inline bint ciszero(celement a, PowComputer_class prime_pow) except -1:
|
|
387
|
+
"""
|
|
388
|
+
Return whether this element is equal to 0.
|
|
389
|
+
|
|
390
|
+
INPUT:
|
|
391
|
+
|
|
392
|
+
- ``a`` -- the element to test
|
|
393
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
394
|
+
|
|
395
|
+
OUTPUT:
|
|
396
|
+
|
|
397
|
+
- returns ``True`` if `a = 0`, and ``False`` otherwise.
|
|
398
|
+
"""
|
|
399
|
+
pass
|
|
400
|
+
|
|
401
|
+
cdef inline int cpow(celement out, celement a, mpz_t n, long prec, PowComputer_class prime_pow) except -1:
|
|
402
|
+
"""
|
|
403
|
+
Exponentiation.
|
|
404
|
+
|
|
405
|
+
INPUT:
|
|
406
|
+
|
|
407
|
+
- ``out`` -- the ``celement`` in which to store the result
|
|
408
|
+
- ``a`` -- the base
|
|
409
|
+
- ``n`` -- an ``mpz_t``, the exponent
|
|
410
|
+
- ``prec`` -- a long, the working absolute precision
|
|
411
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
412
|
+
"""
|
|
413
|
+
pass
|
|
414
|
+
|
|
415
|
+
cdef inline int ccopy(celement out, celement a, PowComputer_class prime_pow) except -1:
|
|
416
|
+
"""
|
|
417
|
+
Copying.
|
|
418
|
+
|
|
419
|
+
INPUT:
|
|
420
|
+
|
|
421
|
+
- ``out`` -- the ``celement`` to store the result
|
|
422
|
+
- ``a`` -- the element to copy
|
|
423
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
424
|
+
"""
|
|
425
|
+
pass
|
|
426
|
+
|
|
427
|
+
cdef inline cpickle(celement a, PowComputer_class prime_pow):
|
|
428
|
+
"""
|
|
429
|
+
Serialization into objects that Sage knows how to pickle.
|
|
430
|
+
|
|
431
|
+
INPUT:
|
|
432
|
+
|
|
433
|
+
- ``a`` -- the element to pickle
|
|
434
|
+
- ``prime_pow`` the PowComputer for the ring
|
|
435
|
+
|
|
436
|
+
OUTPUT:
|
|
437
|
+
|
|
438
|
+
- a serializable object storing ``a``.
|
|
439
|
+
"""
|
|
440
|
+
pass
|
|
441
|
+
|
|
442
|
+
cdef inline int cunpickle(celement out, x, PowComputer_class prime_pow) except -1:
|
|
443
|
+
"""
|
|
444
|
+
Reconstruction from the output of :meth:`cpickle`.
|
|
445
|
+
|
|
446
|
+
INPUT:
|
|
447
|
+
|
|
448
|
+
- ``out`` -- the ``celement`` in which to store the result
|
|
449
|
+
- ``x`` -- the result of :meth:`cpickle`
|
|
450
|
+
- ``prime_pow`` -- the PowComputer for the ring
|
|
451
|
+
"""
|
|
452
|
+
pass
|
|
453
|
+
|
|
454
|
+
cdef inline long chash(celement a, long ordp, long prec, PowComputer_class prime_pow) except -1:
|
|
455
|
+
"""
|
|
456
|
+
Hashing.
|
|
457
|
+
|
|
458
|
+
INPUT:
|
|
459
|
+
|
|
460
|
+
- ``a`` -- an ``celement`` storing the underlying element to hash
|
|
461
|
+
- ``ordp`` -- a long storing the valuation
|
|
462
|
+
- ``prec`` -- a long storing the precision
|
|
463
|
+
- ``prime_pow`` -- a PowComputer for the ring
|
|
464
|
+
"""
|
|
465
|
+
pass
|
|
466
|
+
|
|
467
|
+
# the expansion_mode enum is defined in padic_template_element_header.pxi
|
|
468
|
+
cdef inline cexpansion_next(celement value, expansion_mode mode, long curpower, PowComputer_ prime_pow):
|
|
469
|
+
r"""
|
|
470
|
+
Return the next digit in a `\pi`-adic expansion of ``value``.
|
|
471
|
+
|
|
472
|
+
INPUT:
|
|
473
|
+
|
|
474
|
+
- ``value`` -- the `\pi`-adic element whose expansion is desired
|
|
475
|
+
- ``mode`` -- either ``simple_mode`` or ``smallest_mode``
|
|
476
|
+
- ``curpower`` -- the current power of `\pi` for which the coefficient
|
|
477
|
+
is being found. Only used in ``smallest_mode``
|
|
478
|
+
- ``prime_pow`` -- a ``PowComputer`` holding `\pi`-adic data
|
|
479
|
+
"""
|
|
480
|
+
pass
|
|
481
|
+
|
|
482
|
+
cdef inline cexpansion_getitem(celement value, long m, PowComputer_ prime_pow):
|
|
483
|
+
r"""
|
|
484
|
+
Return the `m`-th `\pi`-adic digit in the ``simple_mode`` expansion.
|
|
485
|
+
|
|
486
|
+
INPUT:
|
|
487
|
+
|
|
488
|
+
- ``value`` -- the `\pi`-adic element whose expansion is desired
|
|
489
|
+
- ``m`` -- nonnegative integer: which entry in the `\pi`-adic expansion to return
|
|
490
|
+
- ``prime_pow`` -- a ``PowComputer`` holding `\pi`-adic data
|
|
491
|
+
"""
|
|
492
|
+
pass
|
|
493
|
+
|
|
494
|
+
# The element is filled in for zero in the p-adic expansion if necessary.
|
|
495
|
+
# It could be [] for some other linkages.
|
|
496
|
+
_expansion_zero = Integer(0)
|
|
497
|
+
|
|
498
|
+
cdef list ccoefficients(celement x, long valshift, PowComputer_class prime_pow):
|
|
499
|
+
"""
|
|
500
|
+
Return a list of coefficients, as elements that can be converted into the base ring.
|
|
501
|
+
|
|
502
|
+
INPUT:
|
|
503
|
+
|
|
504
|
+
- ``x`` -- a ``celement`` giving the underlying `p`-adic element, or possibly its unit part
|
|
505
|
+
- ``valshift`` -- a long giving the power of the uniformizer to shift `x` by
|
|
506
|
+
- ``prec`` -- a long, the (relative) precision desired, used in rational reconstruction
|
|
507
|
+
- ``prime_pow`` -- the ``PowComputer`` of the ring
|
|
508
|
+
"""
|
|
509
|
+
pass
|
|
510
|
+
|
|
511
|
+
cdef int cteichmuller(celement out, celement value, long prec, PowComputer_class prime_pow) except -1:
|
|
512
|
+
r"""
|
|
513
|
+
Teichmuller lifting.
|
|
514
|
+
|
|
515
|
+
INPUT:
|
|
516
|
+
|
|
517
|
+
- ``out`` -- an ``celement`` which is set to a `q-1` root of unity
|
|
518
|
+
congruent to `value` mod `\pi`; or 0 if `a \equiv 0 \pmod{\pi}`
|
|
519
|
+
- ``value`` -- an ``celement``, the element mod `\pi` to lift
|
|
520
|
+
- ``prec`` -- a long, the precision to which to lift
|
|
521
|
+
- ``prime_pow`` -- the ``PowComputer`` of the ring
|
|
522
|
+
"""
|
|
523
|
+
pass
|
|
524
|
+
|
|
525
|
+
cdef int cconv(celement out, x, long prec, long valshift, PowComputer_class prime_pow) except -2:
|
|
526
|
+
"""
|
|
527
|
+
Conversion from other Sage types.
|
|
528
|
+
|
|
529
|
+
INPUT:
|
|
530
|
+
|
|
531
|
+
- ``out`` -- an ``celement`` to store the output
|
|
532
|
+
- ``x`` -- a Sage element that can be converted to a `p`-adic element
|
|
533
|
+
- ``prec`` -- a long, giving the precision desired: absolute if
|
|
534
|
+
`valshift = 0`, relative if `valshift > 0`
|
|
535
|
+
- ``valshift`` -- the power of the uniformizer to divide by before
|
|
536
|
+
storing the result in ``out``
|
|
537
|
+
- ``prime_pow`` -- a PowComputer for the ring
|
|
538
|
+
"""
|
|
539
|
+
pass
|
|
540
|
+
|
|
541
|
+
cdef inline long cconv_mpz_t(celement out, mpz_t x, long prec, bint absolute, PowComputer_class prime_pow) except -2:
|
|
542
|
+
"""
|
|
543
|
+
A fast pathway for conversion of integers that doesn't require
|
|
544
|
+
precomputation of the valuation.
|
|
545
|
+
|
|
546
|
+
INPUT:
|
|
547
|
+
|
|
548
|
+
- ``out`` -- an ``celement`` to store the output
|
|
549
|
+
- ``x`` -- an ``mpz_t`` giving the integer to be converted
|
|
550
|
+
- ``prec`` -- a long, giving the precision desired: absolute or
|
|
551
|
+
relative depending on the ``absolute`` input
|
|
552
|
+
- ``absolute`` -- if False then extracts the valuation and returns
|
|
553
|
+
it, storing the unit in ``out``; if ``True`` then just reduces ``x``
|
|
554
|
+
modulo the precision
|
|
555
|
+
- ``prime_pow`` -- a PowComputer for the ring
|
|
556
|
+
|
|
557
|
+
OUTPUT:
|
|
558
|
+
|
|
559
|
+
- If ``absolute`` is False then returns the valuation that was
|
|
560
|
+
extracted (``maxordp`` when `x = 0`).
|
|
561
|
+
"""
|
|
562
|
+
pass
|
|
563
|
+
|
|
564
|
+
cdef inline int cconv_mpz_t_out(mpz_t out, celement x, long valshift, long prec, PowComputer_class prime_pow) except -1:
|
|
565
|
+
"""
|
|
566
|
+
Convert the underlying `p`-adic element into an integer if
|
|
567
|
+
possible.
|
|
568
|
+
|
|
569
|
+
- ``out`` -- stores the resulting integer as an integer between 0
|
|
570
|
+
and `p^{prec + valshift}`
|
|
571
|
+
- ``x`` -- an ``celement`` giving the underlying `p`-adic element
|
|
572
|
+
- ``valshift`` -- a long giving the power of `p` to shift `x` by
|
|
573
|
+
-` ``prec`` -- a long, the precision of ``x``: currently not used
|
|
574
|
+
- ``prime_pow`` -- a PowComputer for the ring
|
|
575
|
+
"""
|
|
576
|
+
pass
|
|
577
|
+
|
|
578
|
+
cdef inline long cconv_mpq_t(celement out, mpq_t x, long prec, bint absolute, PowComputer_class prime_pow) except? -10000:
|
|
579
|
+
"""
|
|
580
|
+
A fast pathway for conversion of rationals that doesn't require
|
|
581
|
+
precomputation of the valuation.
|
|
582
|
+
|
|
583
|
+
INPUT:
|
|
584
|
+
|
|
585
|
+
- ``out`` -- an ``celement`` to store the output
|
|
586
|
+
- ``x`` -- an ``mpq_t`` giving the rational to be converted
|
|
587
|
+
- ``prec`` -- a long, giving the precision desired: absolute or
|
|
588
|
+
relative depending on the ``absolute`` input
|
|
589
|
+
- ``absolute`` -- if False then extracts the valuation and returns
|
|
590
|
+
it, storing the unit in ``out``; if ``True`` then just reduces ``x``
|
|
591
|
+
modulo the precision
|
|
592
|
+
- ``prime_pow`` -- a PowComputer for the ring
|
|
593
|
+
|
|
594
|
+
OUTPUT:
|
|
595
|
+
|
|
596
|
+
- If ``absolute`` is False then returns the valuation that was
|
|
597
|
+
extracted (``maxordp`` when `x = 0`).
|
|
598
|
+
"""
|
|
599
|
+
pass
|
|
600
|
+
|
|
601
|
+
cdef inline int cconv_mpq_t_out(mpq_t out, celement x, long valshift, long prec, PowComputer_class prime_pow) except -1:
|
|
602
|
+
"""
|
|
603
|
+
Convert the underlying `p`-adic element into a rational.
|
|
604
|
+
|
|
605
|
+
- ``out`` -- gives a rational approximating the input. Currently
|
|
606
|
+
uses rational reconstruction but may change in the future to use a more
|
|
607
|
+
naive method
|
|
608
|
+
- ``x`` -- an ``celement`` giving the underlying `p`-adic element
|
|
609
|
+
- ``valshift`` -- a long giving the power of the uniformizer to shift `x` by
|
|
610
|
+
- ``prec`` -- a long, the precision of ``x``, used in rational
|
|
611
|
+
reconstruction
|
|
612
|
+
- ``prime_pow`` -- a PowComputer for the ring
|
|
613
|
+
"""
|
|
614
|
+
pass
|
|
615
|
+
|
|
616
|
+
# In order to ensure that this file is not actually included, we make this file cause a compile error.
|
|
617
|
+
cdef UndefinedType raise_compile_error
|