Opened 11 years ago

Closed 9 years ago

# Discriminant and resultant of RDF polynomials fails

Reported by: Owned by: Jeroen Demeyer Alex Ghitza major sage-duplicate/invalid/wontfix basic arithmetic real complex double field resultant Jeroen Demeyer N/A

### Description

```sage: R.<x> = PolynomialRing(RDF)
sage: x.discriminant()
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)

/usr/local/src/sage-4.7.2.alpha2/<ipython console> in <module>()

/usr/local/src/sage-4.7.2.alpha2/local/lib/python2.6/site-packages/sage/rings/polynomial/polynomial_element.so in sage.rings.polynomial.polynomial_element.Polynomial.discriminant (sage/rings/polynomial/polynomial_element.c:28999)()

/usr/local/src/sage-4.7.2.alpha2/local/lib/python2.6/site-packages/sage/rings/polynomial/polynomial_singular_interface.pyc in resultant(self, other, variable)
351         return lcm_func(self, singular, have_ring)
352     def resultant(self, other, variable=None):
--> 353         return resultant_func(self, other, variable)
354
355 def _singular_func(self, singular=singular_default, have_ring=False):

/usr/local/src/sage-4.7.2.alpha2/local/lib/python2.6/site-packages/sage/rings/polynomial/polynomial_singular_interface.pyc in resultant_func(self, other, variable)
499     if variable is None:
500         variable = self.parent().gen(0)
--> 501     rt = self._singular_().resultant(other._singular_(), variable._singular_())
502     r = rt.sage_poly(self.parent())
503     if self.parent().ngens() <= 1 and r.degree() <= 0:

/usr/local/src/sage-4.7.2.alpha2/local/lib/python2.6/site-packages/sage/interfaces/interface.pyc in __call__(self, *args, **kwds)
586
587     def __call__(self, *args, **kwds):
--> 588         return self._obj.parent().function_call(self._name, [self._obj] + list(args), kwds)
589
590     def help(self):

/usr/local/src/sage-4.7.2.alpha2/local/lib/python2.6/site-packages/sage/interfaces/interface.pyc in function_call(self, function, args, kwds)
487                                        [s.name() for s in args],
488                                        ['%s=%s'%(key,value.name()) for key, value in kwds.items()])
--> 489         return self.new(s)
490
491     def _function_call_string(self, function, args, kwds):

/usr/local/src/sage-4.7.2.alpha2/local/lib/python2.6/site-packages/sage/interfaces/interface.pyc in new(self, code)
262
263     def new(self, code):
--> 264         return self(code)
265
266     ###################################################################

/usr/local/src/sage-4.7.2.alpha2/local/lib/python2.6/site-packages/sage/interfaces/singular.pyc in __call__(self, x, type)
667             x = str(x)[1:-1]
668
--> 669         return SingularElement(self, type, x, False)
670
671     def has_coerce_map_from_impl(self, S):

/usr/local/src/sage-4.7.2.alpha2/local/lib/python2.6/site-packages/sage/interfaces/singular.pyc in __init__(self, parent, type, value, is_name)
1130             except (RuntimeError, TypeError, KeyboardInterrupt), x:
1131                 self._session_number = -1
-> 1132                 raise TypeError, x
1133         else:
1134             self._name = value

TypeError: Singular error:
? not implemented
? error occurred in or before STDIN line 57: `def sage12=resultant(sage8,sage11,sage8);`
```

For `RR` instead of `RDF`, it does work.

### comment:1 Changed 9 years ago by Frédéric Chapoton

Summary: Discrimant of RDF polynomials fails → Discriminant and resultant of RDF polynomials fails

the problem is already in resultant

```sage: x.resultant(x)
```

see #10978

### comment:3 Changed 9 years ago by Jeroen Demeyer

Milestone: sage-5.11 → sage-5.12

### comment:4 Changed 9 years ago by Jeroen Demeyer

Milestone: sage-6.1 → sage-duplicate/invalid/wontfix → duplicate → Jeroen Demeyer new → closed
Note: See TracTickets for help on using tickets.