Also:
sage: s=SR(result)
sage: type(s)
--
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to
sage-support+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/sage-support
URL: http://www
great -- thanks -- wasn't aware of such function.
--
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to
sage-support+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/sage-support
U
Yep, looking at Integer.__pow__
def __pow__(self, n, modulus):
if modulus is not None:
from sage.rings.finite_rings.integer_mod import Mod
return Mod(self, modulus) ** n
so that should be exactly the same thing.
On Thu, Mar 17, 2011 at 10:26 AM, Graham Enos wr
Another option is to use the pow() function, as in pow(a, b, c).
On Mar 17, 1:58 am, Robert Bradshaw
wrote:
> mod(a, c)^b
>
> On Wed, Mar 16, 2011 at 10:44 PM, Santanu Sarkar
>
>
>
>
>
>
>
> wrote:
> > How one can calculate a^b mod c in Sage for large b?
>
> > --
> > To post to this group, sen
sage: R = PolynomialRing(QQ,[x,y])
result = R(0.5*x + 0.7*y); result; type(result)
1/2*x + 7/10*y
Does it help ?
sage: s=symbolic_expression(result)
sage: type(s)
Laurent
--
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to
s
ic -- thanks for the quick reply
--
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to
sage-support+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/sage-support
URL: http://www.sage
I am trying to convert something like.5*x + 0.7*y of type Expression
tosomething like 1/2*x + 7/10*y of type Expression
so far I am able to do
sage: R = PolynomialRing(QQ,[x,y])
result = R(0.5*x + 0.7*y); result; type(result)
1/2*x + 7/10*y
however the 'type' of the result is
On 3/17/11 11:19 AM, tvn wrote:
I'd expect them to be the same
sage: eval('-1/10')
-1
sage: eval('-(1/10)')
0
Remember that eval doesn't use the Sage preparser, so eval('1/10') is
not the same as 1/10 in Sage, since if you just typed it in Sage, what
is actually run is:
sage: preparse('-1
I'd expect them to be the same
sage: eval('-1/10')
-1
sage: eval('-(1/10)')
0
--
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to
sage-support+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.googl
On 3/16/11 10:32 PM, Oscar Gerardo Lazo Arjona wrote:
luis@linux-smne:~> cd
Documentos/sage/sage-4.5.3-linux-32bit-opensuse_11.1_i586-i686-Linux/^C
luis@linux-smne:~> cd
Documentos/sage/sage-4.5.3-linux-32bit-opensuse_11.1_i586-i686-Linux/
luis@linux-smne:~/Documentos/sage/sage-4.5.3-linux-32bit-
On Wed, 16 Mar 2011 20:36:24 -0700, Oscar Lazo wrote:
> Sorry, I forgot to describe what's going on. It's this friend of mine,
> Luis, who is using Suse now, and wants to run sage. But he gets the
> error above.
>
> Thank you!
>
> Oscar.
What processor does your friend have? Last time I tried
11 matches
Mail list logo