On Fri, Apr 24, 2009 at 11:53 AM, Robert Miller wrote:
>
> Yeah, I should have mentioned that my point was that maybe h%3 should
> raise an error over QQ.
>
Over QQ, the number 3 generates the unit ideal, so everything is 0
modulo it :-).
William
> On Apr 24, 11:00 am, Craig Citro wrote:
>> >
Yeah, I should have mentioned that my point was that maybe h%3 should
raise an error over QQ.
On Apr 24, 11:00 am, Craig Citro wrote:
> > Worse still:
>
> > sage: x = polygen(QQ)
> > sage: h = 4*x
> > sage: h%3
> > 0
>
> Over QQ[x], isn't 4*x = 3 * (4/3*x) ? Over ZZ, it's fine:
>
> sage: x = pol
> Worse still:
>
> sage: x = polygen(QQ)
> sage: h = 4*x
> sage: h%3
> 0
>
Over QQ[x], isn't 4*x = 3 * (4/3*x) ? Over ZZ, it's fine:
sage: x = polygen(ZZ)
sage: h = 4*x
sage: h%3
x
-cc
--~--~-~--~~~---~--~~
To post to this group, send email to sage-devel@googleg
Worse still:
sage: x = polygen(QQ)
sage: h = 4*x
sage: h%3
0
--~--~-~--~~~---~--~~
To post to this group, send email to sage-devel@googlegroups.com
To unsubscribe from this group, send email to
sage-devel-unsubscr...@googlegroups.com
For more options, visit this
On Fri, Apr 24, 2009 at 9:03 AM, Robert Miller wrote:
>
> sage: x = polygen(ZZ)
> sage: f = 2*x^2
> sage: f.mod(2)==0
> False
You should do "f.mod?" and read the docstring, which says:
"Return a representative for self modulo the ideal I (or the ideal
generated by the elements of I if I is no