Skip to content

Commit 98f8ee3

Browse files
committed
small changes including monomial_factorization -> monomial_reduction
1 parent d6cbcca commit 98f8ee3

File tree

3 files changed

+7
-11
lines changed

3 files changed

+7
-11
lines changed

src/sage/groups/finitely_presented.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1798,7 +1798,7 @@ def characteristic_varieties(self, ring=QQ, matrix_ideal=None, groebner=False):
17981798
S = R.polynomial_ring()
17991799
ideal = [S(elt) for elt in ideal]
18001800
for j in range(1, A.ncols()):
1801-
L = [p.monomial_factorization()[0] for p in A.minors(j)]
1801+
L = [p.monomial_reduction()[0] for p in A.minors(j)]
18021802
J = R.ideal(L + ideal)
18031803
res.append(J)
18041804
if not groebner or not R.base_ring().is_field():

src/sage/rings/polynomial/laurent_polynomial.pyx

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1557,8 +1557,6 @@ cdef class LaurentPolynomial_univariate(LaurentPolynomial):
15571557
Return the polynomial and the shift in power used to construct the
15581558
Laurent polynomial `t^n u`.
15591559
1560-
``monomial_factorization`` is an alias for ``polynomial_construction``
1561-
15621560
OUTPUT:
15631561
15641562
A tuple ``(u, n)`` where ``u`` is the underlying polynomial and ``n``
@@ -1570,12 +1568,10 @@ cdef class LaurentPolynomial_univariate(LaurentPolynomial):
15701568
sage: f = 1/x + x^2 + 3*x^4
15711569
sage: f.polynomial_construction()
15721570
(3*x^5 + x^3 + 1, -1)
1573-
sage: f.polynomial_construction() == f.monomial_factorization()
1574-
True
15751571
"""
15761572
return (self.__u, self.__n)
15771573

1578-
monomial_factorization = polynomial_construction
1574+
monomial_reduction = polynomial_construction
15791575

15801576
def is_constant(self):
15811577
"""

src/sage/rings/polynomial/laurent_polynomial_mpair.pyx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1520,7 +1520,7 @@ cdef class LaurentPolynomial_mpair(LaurentPolynomial):
15201520

15211521
return R({m[i]: c for m, c in self.dict().iteritems()})
15221522

1523-
def monomial_factorization(self):
1523+
def monomial_reduction(self):
15241524
"""
15251525
Factor ``self`` into a polynomial and a monomial.
15261526
@@ -1533,14 +1533,14 @@ cdef class LaurentPolynomial_mpair(LaurentPolynomial):
15331533
15341534
sage: R.<x, y> = LaurentPolynomialRing(QQ)
15351535
sage: f = y / x + x^2 / y + 3 * x^4 * y^-2
1536-
sage: f.monomial_factorization()
1536+
sage: f.monomial_reduction()
15371537
(3*x^5 + x^3*y + y^3, 1/(x*y^2))
15381538
sage: f = y * x + x^2 / y + 3 * x^4 * y^-2
1539-
sage: f.monomial_factorization()
1539+
sage: f.monomial_reduction()
15401540
(3*x^3 + y^3 + x*y, x/y^2)
1541-
sage: x.monomial_factorization()
1541+
sage: x.monomial_reduction()
15421542
(1, x)
1543-
sage: (y^-1).monomial_factorization()
1543+
sage: (y^-1).monomial_reduction()
15441544
(1, 1/y)
15451545
"""
15461546
self._normalize()

0 commit comments

Comments
 (0)