Skip to content

Commit f482540

Browse files
author
Jake Moss
committed
Clarify doc strings
1 parent f34e228 commit f482540

File tree

5 files changed

+13
-5
lines changed

5 files changed

+13
-5
lines changed

src/flint/types/fmpq_mpoly.pyx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1131,6 +1131,8 @@ cdef class fmpq_mpoly(flint_mpoly):
11311131
>>> f_deflated
11321132
x + y + 1
11331133
>>> m = ctx.term(exp_vec=I)
1134+
>>> m
1135+
x*y
11341136
>>> m * f_deflated.inflate(N)
11351137
x^3*y + x*y^4 + x*y
11361138
"""

src/flint/types/fmpz_mod_mpoly.pyx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1208,6 +1208,8 @@ cdef class fmpz_mod_mpoly(flint_mpoly):
12081208
>>> f_deflated
12091209
x + y + 1
12101210
>>> m = ctx.term(exp_vec=I)
1211+
>>> m
1212+
x*y
12111213
>>> m * f_deflated.inflate(N)
12121214
x^3*y + x*y^4 + x*y
12131215
"""

src/flint/types/fmpz_mpoly.pyx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1227,6 +1227,8 @@ cdef class fmpz_mpoly(flint_mpoly):
12271227
>>> f_deflated
12281228
x + y + 1
12291229
>>> m = ctx.term(exp_vec=I)
1230+
>>> m
1231+
x*y
12301232
>>> m * f_deflated.inflate(N)
12311233
x^3*y + x*y^4 + x*y
12321234
"""

src/flint/types/fmpz_poly.pyx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -644,7 +644,7 @@ cdef class fmpz_poly(flint_poly):
644644

645645
def deflation_monom(self) -> tuple[fmpz_poly, int, fmpz_poly]:
646646
"""
647-
Compute the exponent vector ``n`` and monomial ``m`` such that ``p(x^(1/n))
647+
Compute the exponent ``n`` and monomial ``m`` such that ``p(x^(1/n))
648648
= m * q(x^n)`` for maximal n. Importantly the deflation itself is not computed
649649
here. The returned monomial allows the undo-ing of the deflation.
650650

@@ -664,10 +664,10 @@ cdef class fmpz_poly(flint_poly):
664664

665665
def deflation_index(self) -> tuple[int, int]:
666666
"""
667-
Compute the exponent vectors ``N`` and ``I`` such that ``p(X^(1/N)) = X^I *
668-
q(X^N)`` for maximal N. Importantly the deflation itself is not computed
669-
here. The returned exponent vector ``I`` is the shift that was applied to the
670-
exponents. It is the exponent vector of the monomial returned by
667+
Compute the exponent ``n`` and ``i`` such that ``p(x^(1/n)) = x^i *
668+
q(x^n)`` for maximal ``n``. Importantly the deflation itself is not computed
669+
here. The returned exponent ``i`` is the shift that was applied to the
670+
exponents. It is the exponent of the monomial returned by
671671
``deflation_monom``.
672672

673673
>>> f = fmpz_poly([1, 0, 1])

src/flint/types/nmod_mpoly.pyx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1178,6 +1178,8 @@ cdef class nmod_mpoly(flint_mpoly):
11781178
>>> f_deflated
11791179
x + y + 1
11801180
>>> m = ctx.term(exp_vec=I)
1181+
>>> m
1182+
x*y
11811183
>>> m * f_deflated.inflate(N)
11821184
x^3*y + x*y^4 + x*y
11831185
"""

0 commit comments

Comments
 (0)