[sage-devel] Re: sage-1.8

2007-01-23 Thread Steven Sivek

I had the same problem -- my sage/functions directory was missing, and 
when I copied it in from an older release everything worked.

Steven

 sage-1.8 installed successfully [1] but there's junk [2] on each startup
 and other weirdness [3].

 Ifti.

 +
 [1]
 ===
 Writing
 /Users/weirdalerdos/Documents/sage-1.8/local/lib/python2.5/site-packages/pysqlite-2.3.2-py2.5.egg-info

 real1m3.548s
 user0m36.142s
 sys 0m19.976s
 Successfully installed sqlite-3.3.11
 Now cleaning up tmp files.
 Making SAGE/Python scripts relocatable...
 Making script relocatable

 real64m57.838s
 user39m20.542s
 sys 15m4.382s
 To install gap, gp, singular, etc., scripts
 in a standard bin directory, start sage and
 type e.g., install_scripts('/usr/local/bin')
 at the command prompt.

 SAGE build/upgrade complete!
 172:~/Documents/sage-1.8 weirdalerdos$ make
 cd spkg  ./install all 21 | tee -a ../install.log
 make[1]: Nothing to be done for `all'.

 real0m0.046s
 user0m0.004s
 sys 0m0.005s
 To install gap, gp, singular, etc., scripts
 in a standard bin directory, start sage and
 type e.g., install_scripts('/usr/local/bin')
 at the command prompt.

 SAGE build/upgrade complete!
 172:~/Documents/sage-1.8 weirdalerdos$

 +
 [2]
 ===
 172:~/Documents/sage-1.8 weirdalerdos$ ./sage
 --
 | SAGE Version 1.8, Release Date: 2007-01-22 |
 | Type notebook() for the GUI, and license() for information.|
 --

 ---
 type 'exceptions.ImportError'   Traceback (most recent call
 last)

 /Users/weirdalerdos/Documents/sage-1.8/local/bin/ipython console in
 module()

 /Users/weirdalerdos/Documents/sage-1.8/local/lib/python2.5/site-packages/sage/all_cmdline.py
 in module()
  1 nodoctest
  2 from sage.all import *
  3

 /Users/weirdalerdos/Documents/sage-1.8/local/lib/python2.5/site-packages/sage/all.py
 in module()
 66 from sage.algebras.all   import *
 67 from sage.modular.allimport *
 --- 68 from sage.schemes.allimport *
 69 from sage.graphs.all import *
 70 from sage.groups.all import *

 /Users/weirdalerdos/Documents/sage-1.8/local/lib/python2.5/site-packages/sage/schemes/all.py
 in module()
 27 from plane_curves.all import *
 28
 --- 29 from elliptic_curves.all import *
 30
 31 from plane_quartics.all import *

 /Users/weirdalerdos/Documents/sage-1.8/local/lib/python2.5/site-packages/sage/schemes/elliptic_curves/all.py
 in module()
 22
 23
 --- 24 from ell_generic import is_EllipticCurve
 25
 26 from ell_rational_field import cremona_curves,
 cremona_optimal_curves

 /Users/weirdalerdos/Documents/sage-1.8/local/lib/python2.5/site-packages/sage/schemes/elliptic_curves/ell_generic.py
 in module()
 32 import sage.misc.latex as latex
 33 import sage.modular.modform as modform
 --- 34 import sage.functions.transcendental as transcendental
 35
 36 # Schemes

 type 'exceptions.ImportError': No module named functions.transcendental
 sage:

 ++

 [3]
 ===
 sage: E = EllipticCurve([1,0])
 ---
 type 'exceptions.NameError' Traceback (most recent call
 last)

 /Users/weirdalerdos/Documents/sage-1.8/local/bin/ipython console in
 module()

 type 'exceptions.NameError': name 'EllipticCurve' is not defined
 sage:





 


--~--~-~--~~~---~--~~
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/
-~--~~~~--~~--~--~---



[sage-devel] dubious ?? help in 1.8

2007-01-23 Thread Joel B. Mohler

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.

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

--
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 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/
-~--~~~~--~~--~--~---



[sage-devel] Re: Dlogs

2007-01-23 Thread David Kohel

 I'm really glad I'm not writing everything in SAGE from scratch!

Definitely.

I can put this in this weekend, but if someone doesn't get to it
sooner.

--David


--~--~-~--~~~---~--~~
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/
-~--~~~~--~~--~--~---



[sage-devel] Re: Dlogs

2007-01-23 Thread William Stein

On Tue, 23 Jan 2007 12:27:47 -0800, David Kohel [EMAIL PROTECTED] wrote:


 I'm really glad I'm not writing everything in SAGE from scratch!

 Definitely.

 I can put this in this weekend, but if someone doesn't get to it
 sooner.

OK, this is now

   http://sage.math.washington.edu:9002/sage_trac/ticket/210

Check there before doing anything on this to see if it's
already been done.

William

--~--~-~--~~~---~--~~
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/
-~--~~~~--~~--~--~---



[sage-devel] Fwd: Thank you for Sage!

2007-01-23 Thread William Stein

Fan mail...

--- Forwarded message ---
From: Michael Borysow  at .utexas.edu
To: [EMAIL PROTECTED]
Cc:
Subject: Thank you for Sage!
Date: Tue, 23 Jan 2007 14:17:24 -0800

Hi Prof. Stein,

I just had to say something to one of the developers for Sage, and
that's 'Wow!'  Sage is exactly what I've been looking for.  It merges my
beloved language of python with the notebook display of Mathematica (and
it looks more attractive to boot!).

So, thank you so incredibly much for the large amount of time I'm sure
you've put into this.  Believe, I'll be telling all my colleagues about
Sage.

Regards,
Michael Borysow



--~--~-~--~~~---~--~~
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/
-~--~~~~--~~--~--~---



[sage-devel] Re: Benchmark

2007-01-23 Thread William Stein

On Tue, 23 Jan 2007 14:09:56 -0800, Kiran S. Kedlaya [EMAIL PROTECTED] wrote:

 Here's a benchmark I just tried, which annoys me.

 sage: def test1():
 : P.x = PolynomialRing(RationalField())
 : t = x^8 - 11*x^7 + x^5 - 1
 : for _ in xrange(1000):
 : t.complex_roots()
 :
 sage: time test1()
 CPU times: user 6.78 s, sys: 0.02 s, total: 6.80 s
 Wall time: 6.80
 sage: def test2():
 : t = pari(x^8 - 11*x^7 + x^5 - 1)
 : for _ in xrange(1000):
 :  t.polroots()
 :
 sage: time test2()
 CPU times: user 6.15 s, sys: 0.00 s, total: 6.15 s
 Wall time: 6.15
 sage: %magma
 magma: procedure test3()
 magma: Px := PolynomialRing(RealField(53));
 magma: u := x^8 - 11*x^7 + x^5 - 1;
 magma: for i := 1 to 1000 do
 magma: t := Roots(u);
 magma: end for;
 magma: end procedure;
 magma: time test3();
  Time: 1.200

 The thing that bugs me is that Magma does not have some fancy
 proprietary algorithm for finding roots of a univariate polynomial; it
 uses PARI! So why are we so much slower?

Why do you think MAGMA uses PARI for this?  (And this isn't so much
a problem with SAGE but with PARI  Try the same computation
directly in PARI and it is just as slow.)

If you really want the answer to only 53-bits precision, by the way,
numpy can do it much much faster than MAGMA. For example,

sage: import numpy
sage: f = numpy.array([1,-11,0,1,0,0,0,0,-1]))
sage: numpy.roots(f)
sage: array([ 10.99172314+0.j,  -0.72174425+0.j,
 -0.45332013+0.53432014j,  -0.45332013-0.53432014j,
  0.66182264+0.30451078j,   0.66182264-0.30451078j,
  0.15650805+0.67766101j,   0.15650805-0.67766101j])
sage: time v=[numpy.roots(f) for _ in range(1000)]
CPU times: user 0.28 s, sys: 0.00 s, total: 0.28 s
Wall time: 0.28

That's already about 5 times faster than MAGMA.  And I bet
that on larger degree numpy beats MAGMA by a lot more...

SAGE doesn't use numpy for root finding yet, partly because
numpy was added to SAGE only very recently, and I haven't
touched the root finding code in a while.

I've made this trac ticket #211.

William

--~--~-~--~~~---~--~~
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/
-~--~~~~--~~--~--~---



[sage-devel] Re: sqlite

2007-01-23 Thread Gonzalo Tornaria

On Mon, Jan 22, 2007 at 09:01:57AM -0800, William Stein wrote:
 Yes.  E.g., there is a large table of graphs that one person made, and another
 very large table of reflexive polytopes in dimension = 4.  Both are best
 queried using SQL.   Gonzalo Tornario once made a very nice SQLite database
 of Cremona's tables of elliptic curves.  I have a lot of data that might
 best be stored as a SQL table.

The database with Cremona's tables is up-to-date, I can contribute it
and/or the scripts to generate it (bash+perl+wget+pari+sqlite+...).
The database currently (conductor up to 130k) weights 500+ Mb, and it
takes 2-3 hours to generate (it computes /all/ quadratic twists in the
tables).

I also have a database for some of William's data on newforms of
weight 2, although it is more limited (I believe up to level 5k or
so).

There is also a database of ternary quadratic forms computed by
myself.

The data is online at http://www.ma.utexas.edu/users/tornaria/cnt/;
unfortunately you cannot do sql queries on the databases, but you can
browse around, including taking quadratic twists, etc.

Best, Gonzalo

--~--~-~--~~~---~--~~
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/
-~--~~~~--~~--~--~---