On Tue, 23 Jan 2007 11:11:11 -0800, Joel B. Mohler <[EMAIL PROTECTED]> wrote:

>
> What does _lcm have to do with valuation in the snippet below? This is version
> 1.8 upgraded from 1.7.1.  The actual function call seems to do what I want it 
> to
> do, but the help seems a bit off.

Your install must be messed up, since n.valuation?? works fine for me.
Could you try "sage -ba" wait a few minutes, then try again?  Also, could
you try it in the notebook.  I think that compiled source code viewing via
IPython still might have some issues.   Also, what does this give for you:

   sage: print n.valuation.__doc__
   File: sage/rings/integer.pyx (starting at line 1125)

> Also
> sage: (3).valuation(1)
> seems to go into an endless loop, but I think I can patch that easily enough 
> by
> myself.
>

Thanks.   Fix it to give a ValueError if p < = 1, after making sure that p is
an Integer (via a coerce).  Composite p is OK to allow.

> --
> Joel
>
> sage: n=1
> sage: n.valuation??
> Type:           builtin_function_or_method
> Base Class:     <type 'builtin_function_or_method'>
> String Form:    <built-in method valuation of sage.rings.integer.Integer 
> object at 0xb19cf9bc>
> Namespace:      Interactive
> Source:
> def _lcm(self, Integer n):
>         """
>         Returns the least common multiple of self and $n$.
>
>         EXAMPLES:
> .....
>
>
> >
>



--~--~---------~--~----~------------~-------~--~----~
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-devel
URLs: http://sage.scipy.org/sage/ and http://modular.math.washington.edu/sage/
-~----------~----~----~----~------~----~------~--~---

Reply via email to