Skip to content

Commit d3d0ea8

Browse files
committed
enhanced documentation
1 parent 002f1d3 commit d3d0ea8

File tree

1 file changed

+15
-8
lines changed

1 file changed

+15
-8
lines changed

src/sage/rings/polynomial/multi_polynomial_ring_base.pyx

Lines changed: 15 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -574,15 +574,21 @@ cdef class MPolynomialRing_base(CommutativeRing):
574574
cpdef _coerce_map_from_(self, other):
575575
"""
576576
Return whether there is canonical coercion map
577-
from the ring ``other`` to this multivariate polynomial ring.
577+
from the ring ``other`` to this multivariate polynomial ring `R`.
578578
579-
The rings that canonically coerce to this polynomial ring are:
579+
The rings that canonically coerce to the polynomial ring `R` are:
580580
581-
- this ring itself
582-
- polynomial rings in a subset of the variables over any base ring that
583-
canonically coerces to the base ring of this ring
584-
- any ring that canonically coerces to the base ring of this polynomial
585-
ring.
581+
- the ring `R` itself,
582+
583+
- the base ring of `R`,
584+
585+
- any ring that canonically coerces to the base ring of `R`.
586+
587+
- polynomial rings in an initial subset of the variables of `R`
588+
over any base ring that canonically coerces to the base ring of `R`,
589+
590+
- polynomial rings in one of the variables of `R`
591+
over any base ring that canonically coerces to the base ring of `R`,
586592
587593
TESTS:
588594
@@ -606,11 +612,12 @@ cdef class MPolynomialRing_base(CommutativeRing):
606612
# registers the coercion map from the base ring, is called only
607613
# when inheriting from this class in Python (cf. Issue #26958).
608614
return self._coerce_map_from_base_ring()
615+
609616
f = self._coerce_map_via([base_ring], other)
610617
if f is not None:
611618
return f
612619

613-
# polynomial rings in a subset of variables
620+
# polynomial rings in an initial subset of variables
614621
# over the any base that coerces in
615622
if isinstance(other, MPolynomialRing_base):
616623
if self is other:

0 commit comments

Comments
 (0)