Skip to content

Commit c1d0859

Browse files
committed
splitting_field: polred -> polredbest
1 parent 0c390a0 commit c1d0859

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

src/sage/rings/number_field/splitting_field.py

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ def splitting_field(poly, name, map=False, degree_multiple=None, abort_degree=No
147147
148148
- ``simplify`` -- (default: ``True``) during the algorithm, try
149149
to find a simpler defining polynomial for the intermediate
150-
number fields using PARI's ``polred()``. This usually speeds
150+
number fields using PARI's ``polredbest()``. This usually speeds
151151
up the computation but can also considerably slow it down.
152152
Try and see what works best in the given situation.
153153
@@ -549,11 +549,9 @@ def splitting_field(poly, name, map=False, degree_multiple=None, abort_degree=No
549549
# Find a simpler defining polynomial Lpol for Mpol
550550
verbose("New field before simplifying: %s" % Mpol, t)
551551
t = cputime()
552-
M = Mpol.polred(flag=3)
553-
n = len(M[0])-1
554-
Lpol = M[1][n].change_variable_name("y")
555-
LtoM = M[0][n].change_variable_name("y").Mod(Mpol.change_variable_name("y"))
556-
MtoL = LtoM.modreverse()
552+
M = Mpol.polredbest(1)
553+
Lpol = M[0].change_variable_name("y")
554+
MtoL = M[1].lift().change_variable_name("y").Mod(Lpol)
557555
else:
558556
# Lpol = Mpol
559557
Lpol = Mpol.change_variable_name("y")

0 commit comments

Comments
 (0)