Skip to content

Commit

Permalink
adaptation of sage source code
Browse files Browse the repository at this point in the history
  • Loading branch information
videlec committed Oct 14, 2023
1 parent b490285 commit 45d6b14
Show file tree
Hide file tree
Showing 14 changed files with 19 additions and 5 deletions.
1 change: 1 addition & 0 deletions src/sage/algebras/quatalg/quaternion_algebra_element.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ from sage.libs.gmp.mpq cimport *
from sage.libs.ntl.convert cimport mpz_to_ZZ, ZZ_to_mpz
from sage.libs.flint.fmpz cimport *
from sage.libs.flint.fmpz_poly cimport *
from sage.libs.flint.fmpz_poly_sage cimport *
from sage.libs.flint.ntl_interface cimport *

# variables for holding temporary values computed in
Expand Down
2 changes: 2 additions & 0 deletions src/sage/graphs/matchpoly.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ from sage.rings.integer cimport Integer

from sage.libs.flint.fmpz cimport *
from sage.libs.flint.fmpz_poly cimport *
from sage.libs.flint.fmpz_poly_sage cimport *


x = polygen(ZZ, 'x')

Expand Down
3 changes: 2 additions & 1 deletion src/sage/libs/linbox/linbox_flint_interface.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@ from sage.libs.gmp.types cimport mpz_t
from sage.libs.flint.types cimport fmpz_t
from sage.libs.flint.fmpz cimport fmpz_get_mpz, fmpz_set_mpz
from sage.libs.flint.fmpz_mat cimport fmpz_mat_entry, fmpz_mat_nrows, fmpz_mat_ncols
from sage.libs.flint.fmpz_poly cimport fmpz_poly_set_coeff_mpz, fmpz_poly_fit_length, _fmpz_poly_set_length
from sage.libs.flint.fmpz_poly cimport fmpz_poly_fit_length, _fmpz_poly_set_length
from sage.libs.flint.fmpz_poly_sage cimport fmpz_poly_set_coeff_mpz

cimport sage.libs.linbox.givaro as givaro
cimport sage.libs.linbox.linbox as linbox
Expand Down
2 changes: 2 additions & 0 deletions src/sage/libs/linkages/padics/fmpz_poly_unram.pxi
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ from sage.rings.finite_rings.integer_mod_ring import Zmod

from sage.libs.flint.fmpz cimport *
from sage.libs.flint.fmpz_poly cimport *
from sage.libs.flint.fmpz_poly_sage cimport *


DEF CELEMENT_IS_PY_OBJECT = False

Expand Down
1 change: 1 addition & 0 deletions src/sage/libs/linkages/padics/relaxed/flint.pxi
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ AUTHOR:
from sage.libs.flint.types cimport flint_rand_t
from sage.libs.flint.fmpz cimport *
from sage.libs.flint.fmpz_poly cimport *
from sage.libs.flint.fmpz_poly_sage cimport *

cdef extern from "sage/libs/linkages/padics/relaxed/flint_helper.c":
cdef void flint_randseed(flint_rand_t state, ulong seed1, ulong seed2)
Expand Down
3 changes: 2 additions & 1 deletion src/sage/matrix/matrix_integer_sparse.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,8 @@ from .matrix cimport Matrix
from .args cimport SparseEntry, MatrixArgs_init
from .matrix_integer_dense cimport Matrix_integer_dense
from sage.libs.flint.fmpz cimport fmpz_set_mpz, fmpz_get_mpz
from sage.libs.flint.fmpz_poly cimport fmpz_poly_fit_length, fmpz_poly_set_coeff_mpz, _fmpz_poly_set_length
from sage.libs.flint.fmpz_poly cimport fmpz_poly_fit_length, _fmpz_poly_set_length
from sage.libs.flint.fmpz_poly_sage cimport fmpz_poly_set_coeff_mpz
from sage.libs.flint.fmpz_mat cimport fmpz_mat_entry

from .matrix_modn_sparse cimport Matrix_modn_sparse
Expand Down
2 changes: 1 addition & 1 deletion src/sage/modular/modform/eis_series_cython.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ from sage.rings.fast_arith cimport prime_range
from cpython.list cimport PyList_GET_ITEM
from sage.libs.flint.fmpz_poly cimport *
from sage.libs.gmp.mpz cimport *
from sage.libs.flint.fmpz_poly cimport Fmpz_poly
from sage.libs.flint.fmpz_poly_sage cimport Fmpz_poly, fmpz_poly_set_coeff_mpz, fmpz_poly_scalar_mul_mpz

cpdef Ek_ZZ(int k, int prec=10):
"""
Expand Down
2 changes: 1 addition & 1 deletion src/sage/modular/modform/vm_basis.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@

import math

from sage.libs.flint.fmpz_poly import Fmpz_poly
from sage.libs.flint.fmpz_poly_sage import Fmpz_poly
from sage.misc.verbose import verbose
from sage.rings.big_oh import O as bigO
from sage.rings.finite_rings.integer_mod_ring import Integers
Expand Down
1 change: 1 addition & 0 deletions src/sage/modular/modsym/apply.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ Monomial expansion of `(aX + bY)^i (cX + dY)^{j-i}`
from sage.ext.stdsage cimport PY_NEW

from sage.libs.flint.fmpz_poly cimport *
from sage.libs.flint.fmpz_poly_sage cimport *
from sage.rings.integer cimport Integer

cdef class Apply:
Expand Down
2 changes: 1 addition & 1 deletion src/sage/rings/complex_arb.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ from cpython.complex cimport PyComplex_FromDoubles
from sage.ext.stdsage cimport PY_NEW

from sage.libs.mpfr cimport MPFR_RNDU, MPFR_RNDD, MPFR_PREC_MIN, mpfr_get_d_2exp
from sage.libs.arb.types cimport ARF_RND_NEAR
from sage.libs.arb.types cimport ARF_RND_NEAR, arf_t, mag_t
from sage.libs.arb.arb cimport *
from sage.libs.arb.acb cimport *
from sage.libs.arb.acb_calc cimport *
Expand Down
2 changes: 2 additions & 0 deletions src/sage/rings/polynomial/evaluation_flint.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ from sage.libs.gmp.mpz cimport *
from sage.libs.gmp.mpq cimport *
from sage.libs.flint.fmpz cimport *
from sage.libs.flint.fmpz_poly cimport *
from sage.libs.flint.fmpz_poly_sage cimport *


cdef fmpz_poly_evaluation_mpfr(mpfr_t res, const fmpz_poly_t poly, const mpfr_t a):
cdef mpz_t c
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ from sage.arith.functions import lcm
from sage.libs.arb.arb_fmpz_poly cimport arb_fmpz_poly_evaluate_arb, arb_fmpz_poly_evaluate_acb
from sage.libs.flint.fmpz cimport *
from sage.libs.flint.fmpz_poly cimport *
from sage.libs.flint.fmpz_poly_sage cimport *
from sage.libs.flint.types cimport ulong, fmpz_poly_t
from sage.libs.flint.ntl_interface cimport fmpz_set_ZZ, fmpz_poly_set_ZZX, fmpz_poly_get_ZZX
from sage.libs.ntl.ZZX cimport *
Expand Down
1 change: 1 addition & 0 deletions src/sage/rings/polynomial/polynomial_rational_flint.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ from sage.libs.flint.fmpz cimport *
from sage.libs.flint.fmpq cimport *
from sage.libs.flint.fmpz_poly cimport *
from sage.libs.flint.fmpq_poly cimport *
from sage.libs.flint.fmpq_poly_sage cimport *

from sage.interfaces.singular import singular as singular_default

Expand Down
1 change: 1 addition & 0 deletions src/sage/schemes/elliptic_curves/descent_two_isogeny.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ import sage.libs.ntl.all as ntl
from sage.rings.integer cimport Integer
from sage.libs.gmp.mpz cimport *
from sage.libs.flint.fmpz_poly cimport *
from sage.libs.flint.fmpz_poly_sage cimport *
from sage.libs.flint.nmod_poly cimport *
from sage.libs.flint.nmod_poly_factor cimport *
from sage.libs.flint.ulong_extras cimport *
Expand Down

0 comments on commit 45d6b14

Please sign in to comment.