On Sun, Mar 15, 2009 at 12:57 PM, Maurizio <maurizio.gran...@gmail.com> wrote:
>
> Ok, let me add another long post to this conversation... hopefully you
> have enough patience!! This is probably known stuff for some of you,
> but I'm sure some others will learn something! I kindly ask you to try
> to go through all this post, I think it will be worthwile.
>
> Short and not so important things first: why can't I get method
> suggested by Jason to get Python integers in SAGE work from the
> notebook? I mean:
>
> import quantities as pq
> res = 10r*pq.ohm
>
> works in sage (run from the command line), but not from the notebook!
> I get the same error, and I also get
>
> value = 10
> type(value)
> <type 'sage.rings.integer.Integer'>
> value = 10r
> type(value)
> <type 'sage.rings.integer.Integer'>
>
> But from sage command line I correctly get type(10r) = python integer!
> Why is that?

This was bug #5356; it's been fixed in Sage 3.4.  So you could upgrade
to 3.4, or as a workaround you could use
value = int(10)
instead.

Carl

--~--~---------~--~----~------------~-------~--~----~
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 group at http://groups.google.com/group/sage-devel
URLs: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---

Reply via email to