Hi.
I'm working on a Mac G5 & trying to install Sage. Darwin needs
packages installed in site-packages within Python folders in
Frameworks. But the Sage binary has two versions of Python inside Sage
with additional packages & more Sage folders inside the various
Python versions.
So I end up with
On Tue, Mar 29, 2011 at 4:00 AM, tvn wrote:
> I'd like to be able to regenerate samples by feeding a seed value to
> random.seed() , but it seems sample() doesn't use this random seed. Is
> there a way to do what I want ?
help(sage.misc.randstate) explains a lot of the gory details.
set_rand
I'd like to be able to regenerate samples by feeding a seed value to
random.seed() , but it seems sample() doesn't use this random seed. Is
there a way to do what I want ? Thanks,
sage: random.seed(1)
sage: random.random()
0.13436424411240122
sage: sample(range(5),2)
[4, 1]
sage: random.s
On Mar 28, 7:55 am, Jason Grout wrote:
> On 3/27/11 9:48 AM, Jeroen Demeyer wrote:
>
> > On 2011-03-25 11:28, Jason Grout wrote:
> >> You should be able to use the zorder parameter. If that doesn't work,
> >> it's a bug.
>
> > That works indeed, but I didn't know about the existence of the zord
On Mon, Mar 28, 2011 at 8:15 AM, Tzanko Matev wrote:
> Hi,
>
> I want to run a certain computation in Magma from a Sage script,
> however I would like to interrupt the computation if it takes longer
> than a set amount of time. Is it possible to do that?
> Thanks in advance,
> Tzanko Matev
Depend
On Mar 28, 12:13 pm, ObsessiveMathsFreak
wrote:
> Perfect. That was exactly what I needed.
Yeah, it may be time to wrap some of our evaluation methods for
special functions as using mpmath or scipy. There are a number of
open tickets about this.
>
> > If you mean complete elliptic integrals
Perfect. That was exactly what I needed.
On Mar 28, 4:11 pm, achrzesz wrote:
> If you mean complete elliptic integrals of the second kind then:
>
> sage: from scipy.special import ellipe
> sage: time pts=[ellipe(1.0/(1.0+0.01*k)) for k in range(1,101)]
> CPU times: user 0.01 s, sys: 0.00 s, tota
If you need more precision,you can also use mpmath
sage: from mpmath import *
sage: time pts=[ellipe(1.0/(1.0+0.01*k)) for k in range(1,101)]
CPU times: user 0.03 s, sys: 0.00 s, total: 0.03 s
Wall time: 0.03 s
--
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe
Hi,
I want to run a certain computation in Magma from a Sage script,
however I would like to interrupt the computation if it takes longer
than a set amount of time. Is it possible to do that?
Thanks in advance,
Tzanko Matev
--
To post to this group, send email to sage-support@googlegroups.com
To
If you mean complete elliptic integrals of the second kind then:
sage: from scipy.special import ellipe
sage: time pts=[ellipe(1.0/(1.0+0.01*k)) for k in range(1,101)]
CPU times: user 0.01 s, sys: 0.00 s, total: 0.01 s
Wall time: 0.02 s
--
To post to this group, send email to sage-support@goog
of course k in range(1,101)
--
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.sagemath.or
sage: from scipy.special import ellipk
sage: time pts=[ellipk(1.0/(1.0+0.01*k)) for k in srange(0,1,0.01)]
CPU times: user 0.02 s, sys: 0.00 s, total: 0.02 s
Wall time: 0.02 s
--
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to
sa
> Am I doing something wrong here? I realise sage isn't a numerical
> system, but this code appears to be quite slow.
Oh, and just because this isn't one of its biggest strengths now
doesn't mean we don't want it to be! We certainly have the potential,
a lot is just wrapping functionality better
sage: %time pts=[ elliptic_ec(m) for m in
srange(0,1,0.01,include_endpoint=True)]
CPU times: user 0.35 s, sys: 0.06 s, total: 0.41 s
Wall time: 3.09 s
What's interesting about this is that Wall time is much higher, also
for you. That's starting Maxima, I think. But once you've started
Maxima up,
sage: %time pts=maxima('makelist(elliptic_ec(float(1/(1+0.01*k))),k,
1,100)')
CPU times: user 0.00 s, sys: 0.00 s, total: 0.00 s
Wall time: 0.05 s
sage: pts0=[RR(x) for x in pts]
On 28 Mar, 15:39, ObsessiveMathsFreak
wrote:
> > sage: %time pts=maxima('makelist(elliptic_ec(0.01*k),k,0,100)')
> > s
> sage: %time pts=maxima('makelist(elliptic_ec(0.01*k),k,0,100)')
> sage: pts0=map(n,pts)
I'm not clear on what's happening here. I take it that the first call
is bypassing overheads associated with multiple maxima calls. The
second command does not work for me however.
In any case, my current pr
Conversion to sage list:
sage: pts0=map(n,pts)
--
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: htt
Oops
sage: %time pts=maxima('makelist(elliptic_ec(0.01*k),k,0,100)')
CPU times: user 0.00 s, sys: 0.00 s, total: 0.00 s
Wall time: 0.05 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
sage: %time maxima('makelist(elliptic_ec(0.1*k),k,0,10)')
CPU times: user 0.00 s, sys: 0.00 s, total: 0.00 s
Wall time: 0.01 s
[%pi/2,1.530757636897764,1.489035058095852,1.445363064412665,
1.399392138897432,1.350643881047676,1.298428035046913,
1.241670567945823,1.178489924327839,1.104774732704073,1
Hi,
Either sxrange or srange should do the trick :)
sage: sxrange(0,1,0.1)
sage: srange(0,1,0.1)
[0.000, 0.100, 0.200, 0.300,
0.400, 0.500, 0.600, 0.700,
0.800, 0.900]
sage: sr
The standard code to compute elliptic integrals in sage appears to be
_very_ slow numerically. To compute the complete elliptic integral on
100 points in the unit interval takes about 16 seconds for me.
sage: %time pts=[ elliptic_ec(m) for m in
srange(0,1,0.01,include_endpoint=True)]
CPU times: us
On 3/28/11 6:28 AM, ObsessiveMathsFreak wrote:
This is a simple question, but I can't find anything in the
documentation about it.
I would like to declare a simple arithmetic sequence in sage. I use
this a lot for discrete plots, etc. In octave, syntax such as
[0:0.1:1] returns the sequence
0.0
On Mon, Mar 28, 2011 at 1:57 PM, ObsessiveMathsFreak
wrote:
> Thank you. That is more or less what I was looking for.
>
> However, is there any shorthand way of getting srange to include the
> final endpoint? While
> srange(0,1.0,0.1,include_endpoint=True)
> works, it is somewhat more verbose than
Thank you. That is more or less what I was looking for.
However, is there any shorthand way of getting srange to include the
final endpoint? While
srange(0,1.0,0.1,include_endpoint=True)
works, it is somewhat more verbose than I am used to.
On Mar 28, 12:45 pm, David Joyner wrote:
> On Mon, Mar
On 3/27/11 9:48 AM, Jeroen Demeyer wrote:
On 2011-03-25 11:28, Jason Grout wrote:
You should be able to use the zorder parameter. If that doesn't work,
it's a bug.
That works indeed, but I didn't know about the existence of the zorder
parameter (it doesn't seem to be documented in the obvious
On Mon, Mar 28, 2011 at 7:28 AM, ObsessiveMathsFreak
wrote:
> This is a simple question, but I can't find anything in the
> documentation about it.
>
> I would like to declare a simple arithmetic sequence in sage. I use
> this a lot for discrete plots, etc. In octave, syntax such as
> [0:0.1:1] re
This is a simple question, but I can't find anything in the
documentation about it.
I would like to declare a simple arithmetic sequence in sage. I use
this a lot for discrete plots, etc. In octave, syntax such as
[0:0.1:1] returns the sequence
0.0 0.2 0.4 0.6 0.8 1.0
Is there such a sho
Le 26/03/2011 10:53, clodemil a écrit :
Hi All,
Sage does not accept accented characters like: é è à give a syntax
error.
For more informations, you can read this one (in French):
http://dl.afpy.org/pycon-fr-09/Comprendre_les_erreurs_unicode.pdf
As native french speaker, it saved my live mor
28 matches
Mail list logo