On 01/05/2018 18:31, Nils Bruin wrote:
On Tuesday, May 1, 2018 at 9:10:27 AM UTC-7, vdelecroix wrote:

Dear all,

How should be defined division in non-integral domains like Zmod(6)? The
following looks a bit incoherent to me

PPS: people with access to magma are welcome to report!


Magma complains about division by a non-unit. It does allow "div", but it
also allows 5 div 2 in ZZ/6.

I think the problem for "/" is division by a zero-divisor. Otherwise an
answer can be returned in a structure where an inverse has been adjoined.

The ZeroDivisionError is therefore spot-on, if you read it as an
abbreviation of ZeroDivisorDivisionError. Using non-unit as abbreviation
for zero-divisor in Z/nZ is pretty common too. I don't think a change is
necessary.

But there is still something missing in Sage: how do I compute all
possible "quotients" of 5 by 2 in Zmod(6) in my Sage console other than

sage: R = Zmod(6)
sage: a = R(5)
sage: b = R(2)
sage: [c for c in R if c*b == a]
[2, 5]

Vincent

--
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 post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to