#4190: [with patch, with positive review and a question] division of number
field
order elements doesn't check for membership
---------------------------+------------------------------------------------
Reporter: davidloeffler | Owner: davidloeffler
Type: defect | Status: assigned
Priority: major | Milestone: sage-3.2.1
Component: number theory | Resolution:
Keywords: |
---------------------------+------------------------------------------------
Changes (by cremona):
* summary: [with patch, needs review] division of number field order
elements doesn't check for membership => [with
patch, with positive review and a question]
division of number field order elements doesn't
check for membership
Comment:
Question: is it necessary to have three versions of this? Would it not
be enough to have one and the others would work just by inheritance?
Apart from that, I noticed that the doctest has a duplicate line (repeated
3 times!).
I tried to find out what code is run when you say "a in OK" but I have
absolutely no idea. I could not find any {{{__contains__}}} function
which seemed to be relevant. Does this work via some coercion magic, or
by chance, or what have I missed?
The patch applies fine to 3.2.alpha3. All tests in number_field/ pass.
You should add this doctest (from the original post):
{{{
sage: OK = NumberField(x^2 - x + 2, 'w').ring_of_integers()
sage: w = OK.ring_generators()[0]
sage: 1/w in OK
False
}}}
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/4190#comment:9>
Sage <http://sagemath.org/>
Sage - Open Source Mathematical Software: Building the Car Instead of
Reinventing the Wheel
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en
-~----------~----~----~----~------~----~------~--~---