I think "extend=" also can take a concrete field as an argument, as there are cases when you know what it can be, and e.g. number fields are faster than QQbar. (or, for instance, you know that the eigenvalues are real, and you want to pass this on)
On December 4, 2025 11:24:44 AM CST, Nils Bruin <[email protected]> wrote: >On Thursday, 4 December 2025 at 01:58:41 UTC-8 vdelecroix wrote: > >My concrete proposal is > >def eivenvalues(self, ring=None, extends=False): >if ring is None: >ring = self.base_ring() >if extends: >ring = ring.algebraic_closure() # or possibly something smarter? >return self.charpoly().roots(ring) > > >I think you'd end up a little more backwards compatible by making the >default for base ring QQ to be "extends=True". Otherwise that seems like a >flexible solution to me. In fact, there is already an extend option to the >command! Adding the "ring" parameter would be a change. The default is >"extend=True", so Martin's request is really just to return results in >QQbar always when "extend=True". That's OK, I think. We should check that >with "extend=False" we do return the roots just in the base ring. The >keyword argument is already documented ... > > > >-- >You received this message because you are subscribed to the Google Groups >"sage-devel" group. >To unsubscribe from this group and stop receiving emails from it, send an >email to [email protected]. >To view this discussion visit >https://groups.google.com/d/msgid/sage-devel/c873ef6f-9b52-4173-a5da-4e54b9bbdb32n%40googlegroups.com. -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion visit https://groups.google.com/d/msgid/sage-devel/69823FE7-2A39-49AA-B84A-3C19BB4AB1B3%40gmail.com.
