#15061: Pari can't handle all polynomial resultants
-------------------------------------------------+-------------------------
       Reporter:  robharron                      |        Owner:
           Type:  defect                         |       Status:
       Priority:  major                          |  needs_info
      Component:  algebra                        |    Milestone:  sage-6.2
       Keywords:  pari, resultant, sylvester     |   Resolution:
  matrix                                         |    Merged in:
        Authors:                                 |    Reviewers:
Report Upstream:  N/A                            |  Work issues:
         Branch:                                 |       Commit:
   Dependencies:                                 |     Stopgaps:
-------------------------------------------------+-------------------------

Comment (by gagern):

 Replying to [comment:10 pbruin]:
 > That commit only changed the order of the superclasses; the inheritance
 was there before.

 Thanks, I missed that fact.

 > I agree that it is strange for polynomials over arbitrary fields to
 inherit from that class.  An alternative would be to "manually" prescribe
 this inheritance for polynomials over fields that support conversion to
 Singular, but that doesn't sound very attractive.

 I see how
 
[http://git.sagemath.org/sage.git/tree/src/sage/rings/polynomial/polynomial_ring.py?id=6.2.rc1#n1467
 the constructor of `PolynomialRing_field`] checks for singular support and
 sets the `_has_singular` property accordingly. We could use that place to
 change `element_class` in a suitable way. But if we wanted to handle this
 using different classes, we'd add one more point to the already dense
 network of generic vs. special, domain vs. field, sparse vs. dense. Not
 sure I like that either.

 > Another alternative would be to move `resultant()` to a more generic
 polynomial class that first tries to use Singular and uses a generic
 Python implementation in case that fails.

 Sounds good. As a first step, we could change
 
[http://git.sagemath.org/sage.git/tree/src/sage/rings/polynomial/polynomial_singular_interface.py?id=6.2.rc1#n372
 `Polynomial_singular_repr`] to check `self.parent()._has_singular` and
 call `super` if that isn't set. We could then make sure that
 
[http://git.sagemath.org/sage.git/tree/src/sage/rings/polynomial/polynomial_element.pyx?id=6.2.rc1#n4798
 `Polynomial.resultant`] falls back to `sylvester_matrix` if PARI doesn't
 work. Although I don't know yet for which rings PARI *will* work. Messy
 business…

--
Ticket URL: <http://trac.sagemath.org/ticket/15061#comment:11>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica, 
and MATLAB

-- 
You received this message because you are subscribed to the Google Groups 
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.

Reply via email to