On Fri, Dec 13, 2024 at 2:38 PM 'Martin R' via sage-devel <
sage-devel@googlegroups.com> wrote:

> This does not look right, does it?
>
> sage: K.<a> = NumberField(x^2-3)
> sage: O = K.ring_of_integers()
> sage: c = O(2*a + 4)
> sage: isinstance(O, Field)
> False
> sage: isinstance(c, FieldElement)
> True
>

It's not ideal, but OrderElement_quadratic inherits from
NumberFieldElement_quadratic because there's a lot of common functionality,
which eventually inherits from FieldElement.  It's basically a consequence
of Cython not supporting multiple inheritance.
David


> Martin
> On Thursday, 12 December 2024 at 23:35:40 UTC+1 Nils Bruin wrote:
>
>> On Thursday, 12 December 2024 at 12:39:46 UTC-8 axio...@yahoo.de wrote:
>>
>> Great, thank you! This - almost - provides a performance test:
>>
>>
>> Yes, you would need to convince sage that this is indeed a euclidean ring
>> (I think for this one the usual norm actually is a euclidean norm). I don't
>> think that simply being a UFD will do it for you.
>>
> --
> 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 sage-devel+unsubscr...@googlegroups.com.
> To view this discussion visit
> https://groups.google.com/d/msgid/sage-devel/35043e34-7915-4c54-9c74-29521c3762e1n%40googlegroups.com
> <https://groups.google.com/d/msgid/sage-devel/35043e34-7915-4c54-9c74-29521c3762e1n%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
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 sage-devel+unsubscr...@googlegroups.com.
To view this discussion visit 
https://groups.google.com/d/msgid/sage-devel/CAChs6_mxSyC0kxC%3DtsJnDq6Qs%2BdRbghcB%3D8cTiUAaLeqRWHGBQ%40mail.gmail.com.

Reply via email to