Skip to content

Commit fe7265d

Browse files
committed
Fix doctests
1 parent 8d4cf40 commit fe7265d

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

src/flint/types/fmpq_poly.pyx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -459,7 +459,7 @@ cdef class fmpq_poly(flint_poly):
459459
>>> p
460460
1/4*x^7 + (-1/4)*x^6 + (-5/4)*x^5 + 1/4*x^4 + 2*x^3 + x^2
461461
>>> p.factor_squarefree()
462-
(1/4, [(x**2 - 2*x, 2), (x + 1, 3)])
462+
(1/4, [(x^2 + (-2)*x, 2), (x + 1, 3)])
463463
>>> p.factor()
464464
(1/4, [(x, 2), (x + (-2), 2), (x + 1, 3)])
465465

src/flint/types/fmpz_poly.pyx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -395,9 +395,9 @@ cdef class fmpz_poly(flint_poly):
395395
>>> x = fmpz_poly([0, 1])
396396
>>> p = (-3 * x**2 * (x + 1)**2 * (x - 1)**3)
397397
>>> p.factor_squarefree()
398-
(-3, [(x**2 + x, 2), (x - 1, 3)])
398+
(-3, [(x^2 + x, 2), (x + (-1), 3)])
399399
>>> p.factor()
400-
(-3, [(x, 2), (x + 1, 2), (x - 1, 3)])
400+
(-3, [(x, 2), (x + 1, 2), (x + (-1), 3)])
401401
402402
"""
403403
return self._factor('squarefree')

src/flint/types/nmod_poly.pyx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -649,9 +649,9 @@ cdef class nmod_poly(flint_poly):
649649
>>> p
650650
2*x^7 + 5*x^6 + 4*x^5 + 2*x^4 + 2*x^3 + x^2
651651
>>> p.factor_squarefree()
652-
(2, [(x**2 - 2*x, 2), (x + 1, 3)])
652+
(2, [(x^2 + 5*x, 2), (x + 1, 3)])
653653
>>> p.factor()
654-
(1/4, [(x, 2), (x + 5, 2), (x + 1, 3)])
654+
(2, [(x, 2), (x + 5, 2), (x + 1, 3)])
655655
656656
"""
657657
return self._factor('squarefree')

0 commit comments

Comments
 (0)