> others where they are not -- and in these other rings the notion > "prime" is just not useful as an attribute for elements, so one goes > over to using it for ideals only.
I'm not sure I believe this. > Conclusion: is_prime should be defined for integers, and ideals, but > need not be defined (i.e. implemented) for elements of any other ring > than Z. > > Does anyone agree? I think the best course of action would be the following. Integers get a is_prime_number method with is_prime being an alias to is_prime_number. All ring elements would get an is_prime_element method that checks whether the element is prime in it parent ring; is_prime could be an alias for this in the generic case. For integers, is_prime(-7) would be False, and is_prime_element(-7) would be True. Then, is_prime_element would always give consistent behavior for things like ideals. Plus, this split highlights the fact that there are really two definitions occurring. --Mike --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to sage-devel@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-devel URLs: http://sage.scipy.org/sage/ and http://modular.math.washington.edu/sage/ -~----------~----~----~----~------~----~------~--~---