[sage-devel] Re: base_ring()

2009-09-03 Thread Jan Groenewald

Hi William

On Wed, Sep 02, 2009 at 10:31:01PM -0700, William Stein wrote:
  Is this the intended behaviour?
 
  sage: z=1.+sqrt(-1); print z; z.base_ring()
  1.00 + 1.00*I
  Symbolic Ring
  sage: z=1.+sqrt(-1.); print z; z.base_ring()
  1.00 + 1.00*I
  Real Field with 53 bits of precision
  note the sqrt(-1) versus sqrt(-1.)
 
Yes, this is definitely the intended behavior.  Why do you think either
one is wrong?  

Uhm, I have asked the originator to join the thread.

The first one, I is not a symbolic variable, it is sqrt(-1).
I am not sure what something like integers with I adjoined is?

The second is not a real field, it is the complex field?

regards,
Jan

-- 
   .~. 
   /V\ Jan Groenewald
  /( )\www.aims.ac.za
  ^^-^^ 

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] polynomial substitution

2009-09-03 Thread William Stein
Hi Martin (and Sage-devel),

I discovered that polynomial substitution is badly inconsistent between the
symbolic ring and multivariate polynomials:

sage: R.x,y = QQ[]
sage: f = x + 2*y
sage: f.subs(x=y,y=x)
3*y
sage: var('x,y')
sage: f = x + 2*y
sage: f.subs(x=y,y=x)
2*x + y

See http://trac.sagemath.org/sage_trac/ticket/6873 for more and a proposal
about how to solve this.

William

-- 
William Stein
Associate Professor of Mathematics
University of Washington
http://wstein.org

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: base_ring()

2009-09-03 Thread William Stein
2009/9/2 Jan Groenewald j...@aims.ac.za


 Hi William

 On Wed, Sep 02, 2009 at 10:31:01PM -0700, William Stein wrote:
   Is this the intended behaviour?
 
   sage: z=1.+sqrt(-1); print z; z.base_ring()
   1.00 + 1.00*I
   Symbolic Ring
   sage: z=1.+sqrt(-1.); print z; z.base_ring()
   1.00 + 1.00*I
   Real Field with 53 bits of precision
   note the sqrt(-1) versus sqrt(-1.)
 
 Yes, this is definitely the intended behavior.  Why do you think
 either
 one is wrong?

 Uhm, I have asked the originator to join the thread.

 The first one, I is not a symbolic variable, it is sqrt(-1).

I am not sure what something like integers with I adjoined is?


If you take any integer (or rational) alpha such that alpha is not a perfect
square, and try to compute sqrt(alpha), Sage promotes alpha to the symbolic
ring (SR) and takes the square root there.  Thus the first is correct, since
sqrt(-1) is not in ZZ, so the square root is instead taken in the symbolic
ring, which yields I.

In the second case, the expression z=1.+sqrt(-1.) is in the complex real
field with 53 bits precision.  The *base ring* of that field is the real
field with 53 bits precision.  Maybe you were instead thinking about the
parent of z?

William



 The second is not a real field, it is the complex field?

 regards,
 Jan

 --
   .~.
   /V\ Jan Groenewald
  /( )\www.aims.ac.za
  ^^-^^

 



-- 
William Stein
Associate Professor of Mathematics
University of Washington
http://wstein.org

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: base_ring()

2009-09-03 Thread Jan Groenewald

Hi William

On Wed, Sep 02, 2009 at 11:18:40PM -0700, William Stein wrote:
If you take any integer (or rational) alpha such that alpha is not a
perfect square, and try to compute sqrt(alpha), Sage promotes alpha to the
symbolic ring (SR) and takes the square root there.  Thus the first is
correct, since sqrt(-1) is not in ZZ, so the square root is instead taken
in the symbolic ring, which yields I. 

OK

In the second case, the expression z=1.+sqrt(-1.) is in the complex real
field with 53 bits precision.  The *base ring* of that field is the real
field with 53 bits precision.  Maybe you were instead thinking about the
parent of z?

Thanks

sage: z=1.+sqrt(-1); print z; z.parent()
1.00 + 1.00*I
Symbolic Ring
sage: z=1.+sqrt(-1.); print z; z.parent()
1.00 + 1.00*I
Complex Field with 53 bits of precision
sage: 

regards,
Jan
-- 
   .~. 
   /V\ Jan Groenewald
  /( )\www.aims.ac.za
  ^^-^^ 

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: base_ring()

2009-09-03 Thread Dirk

I'm the originator.  In fairness to Jan, I must say that I only showed
him the code and output with no other comment than that I hoped that
the students would not ask me to explain it.

I've in the meantime found a way of illustrating the point I meant to
make more clearly.

sage: z=1.+sqrt(-1)
sage: base_ring(z)
Symbolic Ring
sage: base_ring(real(z))
Symbolic Ring
sage: base_ring(imag(z))
Real Field with 53 bits of precision

Dirk

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: base_ring()

2009-09-03 Thread William Stein
2009/9/2 Dirk dirk.lau...@gmail.com


 I'm the originator.  In fairness to Jan, I must say that I only showed
 him the code and output with no other comment than that I hoped that
 the students would not ask me to explain it.

 I've in the meantime found a way of illustrating the point I meant to
 make more clearly.

 sage: z=1.+sqrt(-1)
 sage: base_ring(z)
 Symbolic Ring
 sage: base_ring(real(z))
 Symbolic Ring
 sage: base_ring(imag(z))
 Real Field with 53 bits of precision

 Dirk


I see, your point is that the following is inconsistent:

sage: z = 1.0+1.0*I
sage: type(real(z))
type 'sage.symbolic.expression.Expression'
sage: type(imag(z))
type 'sage.rings.real_mpfr.RealNumber'

I agree that this definitely looks like a bug.

William

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: base_ring()

2009-09-03 Thread javier

Hi William,

On Sep 3, 8:18 am, William Stein wst...@gmail.com wrote:
 I am not sure what something like integers with I adjoined is?


I guess that means the complex numbers of the fomr a + bI with  a, b
integers, or Z[I] (the Gaussian Integers). Mathematica prides itself
to be able to apply primality tests, factorization algorithms and the
kind in this ring:
http://reference.wolfram.com/mathematica/ref/GaussianIntegers.html

Maybe we should add an easy way of working with it, taking advantage
of Sage fast arithmetic for integers?

Cheers
Javier
--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: base_ring()

2009-09-03 Thread William Stein
2009/9/3 javier vengor...@gmail.com


 Hi William,

 On Sep 3, 8:18 am, William Stein wst...@gmail.com wrote:
  I am not sure what something like integers with I adjoined is?


 I guess that means the complex numbers of the fomr a + bI with  a, b
 integers, or Z[I] (the Gaussian Integers). Mathematica prides itself
 to be able to apply primality tests, factorization algorithms and the
 kind in this ring:
 http://reference.wolfram.com/mathematica/ref/GaussianIntegers.html

 Maybe we should add an easy way of working with it, taking advantage
 of Sage fast arithmetic for integers?


Sage has the Gaussian integers, and I'm sure the basic arithmetic and
functionality is as good or better than Mathematica already.

sage: R.I = ZZ[sqrt(-1)]; R
Order in Number Field in I with defining polynomial x^2 + 1
sage: a = 2 + 3*I
sage: timeit('a*a')
625 loops, best of 3: 1.4 µs per loop
sage: R.ideal(3)
Fractional ideal (3)
sage: R.ideal(3).factor()
Fractional ideal (3)
sage: R.ideal(5).factor()
(Fractional ideal (-I - 2)) * (Fractional ideal (2*I + 1))
sage: R.class_group()
Class group of order 1 with structure  of Number Field in I with defining
polynomial x^2 + 1
sage: P = R.ideal(11); P
Fractional ideal (11)
sage: P.is_prime()
True
sage: k = R.quotient(P,'a'); k
Quotient of Maximal Order in Number Field in I with defining polynomial x^2
+ 1 by the ideal (11)

Of course Sage can do all the above sort of stuff with any number field.

William

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: extension field iterator

2009-09-03 Thread John Cremona

givaro seems to be listing the powers of a multiplcative generator,
since that's how givaro represents finite field elements, so it would
be much harder (and slower) for it to do otherwise.

Personally I'm happy to allow Sage to decide which of the 4
implementations is used depending on the characteristic and degree;
and then to allow that implementation to do what is best for it.

Surely it is only for very small fields where we would be listing (or
iterating over) elements anyway?  So if you care that much, list all
the lements and then sort them how you like?

John

2009/9/3 Robert Bradshaw rober...@math.washington.edu:

 On Wed, 2 Sep 2009, YannLC wrote:


 Hi all,

 I noticed that iterating over a finite field gives a different order
 depending on the implementation:

 sage: list(sage.rings.finite_field_prime_modn.FiniteField_prime_modn
 (7))
 [0, 1, 2, 3, 4, 5, 6]
 sage: list(sage.rings.finite_field.FiniteField_givaro(7))
 [0, 3, 2, 6, 4, 5, 1]
 sage: list(sage.rings.finite_field_ext_pari.FiniteField_ext_pari
 (2**3,'a'))
 [0, 1, a, a + 1, a^2, a^2 + 1, a^2 + a, a^2 + a + 1]
 sage: list(sage.rings.finite_field.FiniteField_givaro(2**3))
 [0, a, a^2, a + 1, a^2 + a, a^2 + a + 1, a^2 + 1, 1]
 sage: list(sage.rings.finite_field_ntl_gf2e.FiniteField_ntl_gf2e
 (2**3,'a'))
 [0, 1, a, a + 1, a^2, a^2 + 1, a^2 + a, a^2 + a + 1]

 I think we should change the behavior for FiniteField_givaro, but
 maybe it's better to give the choice between the two behavior. Do you
 think it's useful to keep both? Which one would you prefer for
 default?

 By default, I'd prefer whatever is fastest to compute for a given
 representation.

 - Robert


 


--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: polynomial substitution

2009-09-03 Thread Michael Brickenstein

I forwarded it to our team list.
I suppose, that your homomorphism uses Singulars map internally.
That should be a good solution for more than two parallel
substitutions.
Michael

On 3 Sep., 08:18, William Stein wst...@gmail.com wrote:
 Hi Martin (and Sage-devel),

 I discovered that polynomial substitution is badly inconsistent between the
 symbolic ring and multivariate polynomials:

 sage: R.x,y = QQ[]
 sage: f = x + 2*y
 sage: f.subs(x=y,y=x)
 3*y
 sage: var('x,y')
 sage: f = x + 2*y
 sage: f.subs(x=y,y=x)
 2*x + y

 Seehttp://trac.sagemath.org/sage_trac/ticket/6873for more and a proposal
 about how to solve this.

 William

 --
 William Stein
 Associate Professor of Mathematics
 University of Washingtonhttp://wstein.org
--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: base_ring()

2009-09-03 Thread javier


On Sep 3, 9:36 am, William Stein wst...@gmail.com wrote:
 Sage has the Gaussian integers, and I'm sure the basic arithmetic and
 functionality is as good or better than Mathematica already.

Sure, what I meant (sorry if I wasn't very clear) is to make an
straightforward way to access it, kind of

R = GaussianIntegers()

in which you could factor directly the elements without needing to
define the ideals generated by them. Functionality is of course
equivalent to what we already have, just thought it would be nice
(maybe just for marketing reasons) to be able to do something like

(1 + I).is_prime()

Cheers
Javier
--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: polynomial substitution

2009-09-03 Thread Martin Albrecht

On Thursday 03 September 2009, William Stein wrote:
 Hi Martin (and Sage-devel),

 I discovered that polynomial substitution is badly inconsistent between the
 symbolic ring and multivariate polynomials:

 sage: R.x,y = QQ[]
 sage: f = x + 2*y
 sage: f.subs(x=y,y=x)
 3*y
 sage: var('x,y')
 sage: f = x + 2*y
 sage: f.subs(x=y,y=x)
 2*x + y

 See http://trac.sagemath.org/sage_trac/ticket/6873 for more and a proposal
 about how to solve this.

FWIW this behaviour is documented:

.. note::

   The evaluation is performed by evaluating every
   ``variable:value`` pair separately.  This has side effects
   if e.g. x=y, y=z is provided. If x=y is evaluated first,
   all x variables will be replaced by z eventually.

Also, I think that ticket is dupe of

   http://trac.sagemath.org/sage_trac/ticket/6482

Still, it needs to be addressed.

Cheers,
Martin

-- 
name: Martin Albrecht
_pgp: http://pgp.mit.edu:11371/pks/lookup?op=getsearch=0x8EF0DC99
_otr: 47F43D1A 5D68C36F 468BAEBA 640E8856 D7951CCF
_www: http://www.informatik.uni-bremen.de/~malb
_jab: martinralbre...@jabber.ccc.de



--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: base_ring()

2009-09-03 Thread John Cremona

2009/9/3 javier vengor...@gmail.com:


 On Sep 3, 9:36 am, William Stein wst...@gmail.com wrote:
 Sage has the Gaussian integers, and I'm sure the basic arithmetic and
 functionality is as good or better than Mathematica already.

 Sure, what I meant (sorry if I wasn't very clear) is to make an
 straightforward way to access it, kind of

 R = GaussianIntegers()

 in which you could factor directly the elements without needing to
 define the ideals generated by them. Functionality is of course
 equivalent to what we already have, just thought it would be nice
 (maybe just for marketing reasons) to be able to do something like

 (1 + I).is_prime()

I always thought that Maple's and Mathematica's ability to work
directly with Gaussian Integers was just that, a marketing ploy,
giving certain customers the impression of very fancy capabilities
with algebraic numbers.  But of course number theorists know that this
is just one interesting ring o algebraic integers, certainly the
easiest to define, but not exactly typical.  A number theorist
requires far more than that -- as Sage does provide -- and for others
is this not just a curiosity?  Maybe a useful one for teaching,
though, and implementing this would certainly be possible.

John


 Cheers
 Javier
 


--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: Fwd: Conference/workshop on Industrial Applications and Prospects of Computer Algebra

2009-09-03 Thread Martin Albrecht

So, does anyone around here want to give a talk or an exhibition or something 
at this conference by the Fachgruppe Computeralgebra in Germany? I think a 
quick 'I might be interested' would suffice. I can also ask for more details 
if that is what is required.

Cheers,
Martin

-- 
name: Martin Albrecht
_pgp: http://pgp.mit.edu:11371/pks/lookup?op=getsearch=0x8EF0DC99
_otr: 47F43D1A 5D68C36F 468BAEBA 640E8856 D7951CCF
_www: http://www.informatik.uni-bremen.de/~malb
_jab: martinralbre...@jabber.ccc.de



--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: [fricas-devel] Re: Aldor interface

2009-09-03 Thread Ralf Hemmecke

  But after including '-lm' it fails again with the following error:

Bill, could you send me the exact list of commands to arrive at this 
error. Maybe you even have the full log of this 'make'.

Are you sure that you have the files lang.as etc. from the Aldor.org 
server? Actually these files could be distributed (maybe as a separate 
spkg because of license issues) so that there would be no need for 
internet access at build time.

Ralf

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: Fwd: Conference/workshop on Industrial Applications and Prospects of Computer Algebra

2009-09-03 Thread Serge A. Salamanka

I might be interested.
But I don't feel I can talk to industrials about Sage yet.

#Serge

Martin Albrecht пишет:
 So, does anyone around here want to give a talk or an exhibition or something 
 at this conference by the Fachgruppe Computeralgebra in Germany? I think a 
 quick 'I might be interested' would suffice. I can also ask for more details 
 if that is what is required.
 
 Cheers,
 Martin
 

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: [fricas-devel] Re: Aldor interface

2009-09-03 Thread Bill Page

Ralf,

I am sorry, I don't the logs to send but if you have any problems with
the instructions below, then I can reproduce and send them later.

Assuming that you already have Aldor and Sage installed, the commends:

$ cd ~/sage-4.1.1
$ wget http://www.mediafire.com/file/im5zd201mh0/fricas-1.0.7.p0.spkg
$ ./sage -f fricas-1.0.7.spkg

Produces the error:  undefined reference to `log' . (about 15 minutes)

After the failure, follow the instructions printed by Sage to enter
the Sage shell - the environment in which Sage and all it's spkg's
run. As indicated 'cd' to the fricas-1.0.7 directory inside Sage.

Now changing

CLIQUEOPTS=-mno-abbrev -mno-mactext -laldor -lm -fx

in the file './src/src/aldor/Makefile.in' and re-running the biuld via

  ./spkg-install

produces the error I showed in my previous email.

Except for the  undefined reference to `log'  message, the same
error occurs outside of Sage. To reproduce do this:

First install ECL 9.8.4, then build FriCAS from source using ecl in
the usual way. E.g

  $ svn update ~/fricas
  $ mkdir ~/fricas-build
  $ cd ~/fricas-build
  $ ../fricas/configure --with-lisp=ecl

After it finishes run the command:

 $ ../fricas/src/scripts/mkdist.sh --copy_lisp

The result will be a new sub-directory named 'dist' in your build
directory. This directory is identical to the 'src' directory in the
Sage fricas-1.0.7 directory (except a little newer). Copy the whole
sub-directory somewhere, e.g.

  $ cp -r dist ~/fricas-dist
  $ cd ~/fricas-dist

Now build FriCAS in the usual way

  $ ./configure --with-lisp=ecl
  $ make

It fails at:

echo ')lisp (quit)'  tmp/mko_lang.lsp
# The .ao file will be built via Makefile2.
aldor -flsp=lsp/lang.lsp ao/lang.ao
#1 (Fatal Error) Could not open file `ao/lang.ao'.

The file '~/fricas-dist/src/aldor/tmp/mko_lang.lsp' refers to 'lsp/lang.lsp':

$ cat ~/fricas-dist/src/aldor/tmp/mko_lang.lsp

)lisp (compile-file /home/wspage/fricas-dist/src/aldor/lsp/lang.lsp
:output-file /home/wspage/fricas-dist/src/aldor/lib/lang.fas)
)lisp (quit)
wsp...@debian:~/fricas-dist/src/aldor$

---

but the lsp directory only contains 'runtime.lsp'

$ ls -l /home/wspage/fricas-dist/src/aldor/lsp
total 392
-rw-r--r-- 1 wspage wspage 395221 2009-09-02 21:48 runtime.lsp

Although the 'lang.as' file is present:

 $ cd ~/fricas-dist
 $ find . -name lang.as
./src/aldor/lang.as

I don't think there was any problem with access to svn for these
files. But maybe in the future it would be possible to just distribute
the cached lisp files generated by Aldor the same way as those
generated by FriCAS? I don't see how that would violate any licenses.

Please let me know if you would still like me to produce and send the log.

Regards,
Bill Page.

On Thu, Sep 3, 2009 at 6:16 AM, Ralf Hemmecke wrote:

   But after including '-lm' it fails again with the following error:

 Bill, could you send me the exact list of commands to arrive at this
 error. Maybe you even have the full log of this 'make'.

 Are you sure that you have the files lang.as etc. from the Aldor.org
 server? Actually these files could be distributed (maybe as a separate
 spkg because of license issues) so that there would be no need for
 internet access at build time.


--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: Fwd: Conference/workshop on Industrial Applications and Prospects of Computer Algebra

2009-09-03 Thread Harald Schilly

On Sep 3, 10:50 am, Martin Albrecht m...@informatik.uni-bremen.de
wrote:
 So, does anyone around here want to give a talk or an exhibition or 
 something...

I'm interested.
This might be useful for Sage in several ways: New contacts in Germany
(roughly #2 in the stats), improve our skills of communicating Sage:
http://groups.google.com/group/sage-marketing (poster, fact sheet,
stickers, etc.) and it's an additional selling point for Sage to be
represented at an event with industry background.

H
--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: base_ring()

2009-09-03 Thread kcrisman



 is this not just a curiosity?  Maybe a useful one for teaching,
 though, and implementing this would certainly be possible.

Very useful.  I had to resort to some annoying crutches (i.e., using
the theorem in the code instead of discovering the theorem via the
demonstration of the code) to do stuff with Gaussian integers last
spring in my undergraduate course.   In particular,

(1 + I).is_prime()

would have been really useful, but was not available.  I realize that
in the symbolic ring it is not clear what should be prime, but then
again

sage: is_prime(SR(3))
True

yet in theory it might not be a generator of a prime ideal depending
on what else is in the symbolic ring:

sage: 1/3 in SR
True

So anything that gives easy access to this particular number field
*and* its elements being treated as generators of the ideals would be
very nice, for instance for things like Gaussian constellations etc.
If there are any other rings of integers of number fields that show up
a lot they could have shortcuts too, maybe Cyclotomic_Integers(n) or
something, in the way Javier points out.

- kcrisman
--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: base_ring()

2009-09-03 Thread John H Palmieri

On Sep 3, 12:36 am, William Stein wst...@gmail.com wrote:

 Sage has the Gaussian integers, and I'm sure the basic arithmetic and
 functionality is as good or better than Mathematica already.

 sage: R.I = ZZ[sqrt(-1)]; R
 Order in Number Field in I with defining polynomial x^2 + 1

Okay, this looks like a bug to me:

--
| Sage Version 4.1.1, Release Date: 2009-08-14   |
| Type notebook() for the GUI, and license() for information.|
--
sage: I
I
sage: R.I = ZZ[sqrt(-1)]
sage: I
1
sage: I^2
1

Why is I equal to 1 all of a sudden?  Same problem here:

sage: reset()
sage: R.a = ZZ[sqrt(-5)]
sage: a
1
sage: R.1
a
sage: R.1 == a
False
sage: (R.1)^2
-5
sage: R.inject_variables()
Defining a
sage: a
1


Ouch.
--
John

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: base_ring()

2009-09-03 Thread William Stein
On Thu, Sep 3, 2009 at 9:15 AM, John H Palmieri jhpalmier...@gmail.comwrote:


 On Sep 3, 12:36 am, William Stein wst...@gmail.com wrote:
 
  Sage has the Gaussian integers, and I'm sure the basic arithmetic and
  functionality is as good or better than Mathematica already.
 
  sage: R.I = ZZ[sqrt(-1)]; R
  Order in Number Field in I with defining polynomial x^2 + 1

 Okay, this looks like a bug to me:

 --
 | Sage Version 4.1.1, Release Date: 2009-08-14   |
 | Type notebook() for the GUI, and license() for information.|
 --
 sage: I
 I
 sage: R.I = ZZ[sqrt(-1)]
 sage: I
 1
 sage: I^2
 1

 Why is I equal to 1 all of a sudden?  Same problem here:

 sage: reset()
 sage: R.a = ZZ[sqrt(-5)]
 sage: a
 1
 sage: R.1
 a
 sage: R.1 == a
 False
 sage: (R.1)^2
 -5
 sage: R.inject_variables()
 Defining a
 sage: a
 1


 Ouch.
 --


it's actually not a bug; it's confusing (in this particular situation)
documented behavior.  It's clearly confusing.

What is happening is that R = ZZ[blah, blahs] constructs the smallest
*order* that contains blahs.  These aren't in general monogenic (generated
by one element), so R.gens() is just a ZZ basis for that order.  So:

sage: ZZ[sqrt(-5)]
Order in Number Field in a with defining polynomial x^2 + 5
sage: ZZ[sqrt(-5)].gens()
[1, a]
sage: R.a,b = ZZ[sqrt(-5)]
sage: b^2
-5

Obviously this is confusing in this special cases, as we were both
confused.  Number fields are monogenic so work as expected:

sage: R.I = QQ[sqrt(-1)]
sage: I^2
-1
sage: R.gens()
(I,)

William

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: base_ring()

2009-09-03 Thread John Cremona

2009/9/3 John H Palmieri jhpalmier...@gmail.com:

 On Sep 3, 12:36 am, William Stein wst...@gmail.com wrote:

 Sage has the Gaussian integers, and I'm sure the basic arithmetic and
 functionality is as good or better than Mathematica already.

 sage: R.I = ZZ[sqrt(-1)]; R
 Order in Number Field in I with defining polynomial x^2 + 1

 Okay, this looks like a bug to me:

 --
 | Sage Version 4.1.1, Release Date: 2009-08-14                       |
 | Type notebook() for the GUI, and license() for information.        |
 --
 sage: I
 I
 sage: R.I = ZZ[sqrt(-1)]
 sage: I
 1
 sage: I^2
 1

 Why is I equal to 1 all of a sudden?  Same problem here:

Here is the reason, which caught me out also.   ZZ[sqrt(-1)] is an
order, and has two gens, namely its ZZ-module generators:

sage: R = ZZ[sqrt(-1)]
sage: R.gens()
[1, I]
sage: R.one,I = ZZ[sqrt(-1)]
sage: one
1
sage: I
I
sage: I^2
-1

So, R needs two names, you only gave it one.

I guess WAS is about to say the same thing but I'll post anyway...

John



 sage: reset()
 sage: R.a = ZZ[sqrt(-5)]
 sage: a
 1
 sage: R.1
 a
 sage: R.1 == a
 False
 sage: (R.1)^2
 -5
 sage: R.inject_variables()
 Defining a
 sage: a
 1


 Ouch.
 --
 John

 


--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] symbolic variable treated as sqrt(-1) when it shouldn't be

2009-09-03 Thread William Stein

Hi Sage-Devel,

What do you think of this:

sage: var('x, i')
sage: solve(x^2 + i == 0, x)
[x == -sqrt(-I), x == sqrt(-I)]

Basically, I make a purely symbolic variable which I happen to call
i, and it gets treated somewhere (presumably in Maxima) as if it
were sqrt(-1).

Here is another instance of this:

sage: var('i')
i
sage: a = i^2
sage: a
i^2
sage: a.simplify_full()
-1

So Ginac treats things fine, but our use of Maxima messes it up.

This came up for me just now when doing some symbolic calculation with
a quaternion algebra where the generators are called i,j,k, and this
i has nothing to do with sqrt(-1).

Thoughts?

William


--
William Stein
Associate Professor of Mathematics
University of Washington
http://wstein.org

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] back ticks versus $ signs

2009-09-03 Thread William Stein

Hi,

I've been spending the last few days going between writing a lot of
code with very math heavy Sphinx docstrings containing many backticks,
and writing LaTeX documents (papers/notes/etc.) using $ signs for math
mode.  It is driving me totally crazy!  I constantly accidentally put
$'s in my Spinx docstrings and now I'm starting to put back ticks ` in
my LaTeX documents.

Is anybody else annoyed by this?   I am very tempted to change Sage so
that $ signs can be used as a synonym for backquotes in docstrings.  I
would leave backticks, but make it so $'s just get converted to
backticks, plus maybe some marker to leave $'s as $'s (e.g., whatever
one would currently do to enter a backtick in Sphinx).

   [ ] Yes, give me $'s!

   [ ] No, this doesn't bug me; let's keep ReST/Sphinx in Sage pure.


 -- William





-- 
William Stein
Associate Professor of Mathematics
University of Washington
http://wstein.org

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: List of doctest failures in current Mandriva sagemath

2009-09-03 Thread Paulo César Pereira de Andrade

2009/9/2 Martin Albrecht m...@informatik.uni-bremen.de:

  doc/en/constructions/rings.rst +58
     sage: R = singular.ring(97, '(a,b,c,d)', 'lp')
     sage: I = singular.ideal(['a+b+c+d', 'ab+ad+bc+cd',
  'abc+abd+acd+bcd', 'abcd-1'])
     sage: R
  Expected:
     //   characteristic : 97
     //   number of vars : 4
     //        block   1 : ordering lp
     //                  : names    a b c d
     //        block   2 : ordering C
  Got:
     //   characteristic : 97
     //   number of vars : 4
     //        block   1 : ordering lp
     //                  : names    abcd
     //        block   2 : ordering C
  * The sage spkg don't have a patch to separate the names, so I am
  assuming it is a minor change in singular

 looks safe

 Yes, this was fixed in Singular recently, I assume Mandriva only needs to
 update to the newest upstream release.

  I tried again a newer singular, but singular-3-1-0-4, which is the latest one
api/abi compatible with sage. I am preferring to package upstream, and
then apply sage patches as appropriate. I will check if I can make a simple
patch make singular provide the result expected by sage.

  rings/polynomial/toy_d_basis.py +171
         sage: from sage.rings.polynomial.toy_d_basis import gpol
         sage: P.x, y, z = PolynomialRing(IntegerRing(), 3, order='lex')
         sage: f = x^2 - 1
         sage: g = 2*x*y - z
         sage: gpol(f,g)
  Expected:
     x^2*y - y
  Got:
     x^2*y - x*z + y
  * Not sure what is the cause, neither if this is an alternate correct
  result...]

 Martin -- any thoughts?

 Here is what gpol does

  a1,a2 = g1.lc(),g2.lc()# a1 = 1, a2 = 2
  a, c1, c2 = xgcd(a1,a2) # (1,0,1) - this is not unique
  t1,t2 = g1.lm(), g2.lm() # x^2, x*y
  t = t1.parent().monomial_lcm(t1,t2) # x^2*y
  s1,s2 = t//t1, t//t2 # y, x
  return c1*s1*g1 + c2*s2*g2 # 0*y*g1 + 1*x*g2

 I guess xgcd changed (e.g. (1,-1,1)) and thus the result is different. So it
 seems also correct.

  Many thanks for the review. About quaddouble, since only sagemath requires
it, I packaged the sage spkg in Mandriva. But the package is kind problematic,
as it has only a static library, and the sage spkg fails to build the fortran
bindings in x86_64. Anyway, if sage stops using it, then it can be dropped
from Mandriva later.

  Since there is still some time before Mandriva 2010.0, I am also updating the
package to ship sage 4.1.1.

 Cheers,
 Martin

Paulo

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: back ticks versus $ signs

2009-09-03 Thread Tom Boothby

On Thu, Sep 3, 2009 at 12:09 PM, William Steinwst...@gmail.com wrote:

 Hi,

 I've been spending the last few days going between writing a lot of
 code with very math heavy Sphinx docstrings containing many backticks,
 and writing LaTeX documents (papers/notes/etc.) using $ signs for math
 mode.  It is driving me totally crazy!  I constantly accidentally put
 $'s in my Spinx docstrings and now I'm starting to put back ticks ` in
 my LaTeX documents.

 Is anybody else annoyed by this?   I am very tempted to change Sage so
 that $ signs can be used as a synonym for backquotes in docstrings.  I
 would leave backticks, but make it so $'s just get converted to
 backticks, plus maybe some marker to leave $'s as $'s (e.g., whatever
 one would currently do to enter a backtick in Sphinx).

   [ ] Yes, give me $'s!

   [ ] No, this doesn't bug me; let's keep ReST/Sphinx in Sage pure.

[x] Yes, this bugs me; but let's keep ReST/Sphinx in Sage pure.



  -- William





 --
 William Stein
 Associate Professor of Mathematics
 University of Washington
 http://wstein.org

 


--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: back ticks versus $ signs

2009-09-03 Thread Ondrej Certik

On Thu, Sep 3, 2009 at 12:09 PM, William Steinwst...@gmail.com wrote:

 Hi,

 I've been spending the last few days going between writing a lot of
 code with very math heavy Sphinx docstrings containing many backticks,
 and writing LaTeX documents (papers/notes/etc.) using $ signs for math
 mode.  It is driving me totally crazy!  I constantly accidentally put
 $'s in my Spinx docstrings and now I'm starting to put back ticks ` in
 my LaTeX documents.

 Is anybody else annoyed by this?   I am very tempted to change Sage so
 that $ signs can be used as a synonym for backquotes in docstrings.  I
 would leave backticks, but make it so $'s just get converted to
 backticks, plus maybe some marker to leave $'s as $'s (e.g., whatever
 one would currently do to enter a backtick in Sphinx).

I am also writing lots of formulas using rest, e.g.:

http://certik.github.com/mhd-hermes/sphinx-doc/physics.html

and it bugs me that I have to type

:math:`\eta`

instead of just $\eta$. So how about submitting a patch to sphinx fixing it?

Ondrej

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: back ticks versus $ signs

2009-09-03 Thread Robert Bradshaw

On Thu, 3 Sep 2009, William Stein wrote:


 Hi,

 I've been spending the last few days going between writing a lot of
 code with very math heavy Sphinx docstrings containing many backticks,
 and writing LaTeX documents (papers/notes/etc.) using $ signs for math
 mode.  It is driving me totally crazy!  I constantly accidentally put
 $'s in my Spinx docstrings and now I'm starting to put back ticks ` in
 my LaTeX documents.

 Is anybody else annoyed by this?   I am very tempted to change Sage so
 that $ signs can be used as a synonym for backquotes in docstrings.  I
 would leave backticks, but make it so $'s just get converted to
 backticks, plus maybe some marker to leave $'s as $'s (e.g., whatever
 one would currently do to enter a backtick in Sphinx).

   [X] Yes, give me $'s!

   [ ] No, this doesn't bug me; let's keep ReST/Sphinx in Sage pure.

I've been annoyed by this ever since we switched over to ReST.

- Robert


--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: back ticks versus $ signs

2009-09-03 Thread William A. Stein


On Sep 3, 2009, at 12:28 PM, Ondrej Certik wrote:


 On Thu, Sep 3, 2009 at 12:09 PM, William Steinwst...@gmail.com  
 wrote:

 Hi,

 I've been spending the last few days going between writing a lot of
 code with very math heavy Sphinx docstrings containing many  
 backticks,
 and writing LaTeX documents (papers/notes/etc.) using $ signs for  
 math
 mode.  It is driving me totally crazy!  I constantly accidentally put
 $'s in my Spinx docstrings and now I'm starting to put back ticks `  
 in
 my LaTeX documents.

 Is anybody else annoyed by this?   I am very tempted to change Sage  
 so
 that $ signs can be used as a synonym for backquotes in  
 docstrings.  I
 would leave backticks, but make it so $'s just get converted to
 backticks, plus maybe some marker to leave $'s as $'s (e.g., whatever
 one would currently do to enter a backtick in Sphinx).

 I am also writing lots of formulas using rest, e.g.:

 http://certik.github.com/mhd-hermes/sphinx-doc/physics.html

 and it bugs me that I have to type

 :math:`\eta`

 instead of just $\eta$. So how about submitting a patch to sphinx  
 fixing it?

 Ondrej


That's a good idea.  It would certainly be better than having to  
change Sage -- it would keep things pure, but allow $'s, and even  
benefit you.  Great idea.   It's hard to argue with that.

  -- William

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: Fwd: Conference/workshop on Industrial Applications and Prospects of Computer Algebra

2009-09-03 Thread Martin Albrecht

 I'm interested.
 This might be useful for Sage in several ways: New contacts in Germany
 (roughly #2 in the stats), improve our skills of communicating Sage:
 http://groups.google.com/group/sage-marketing (poster, fact sheet,
 stickers, etc.) and it's an additional selling point for Sage to be
 represented at an event with industry background.

Hi,

while I am in principle interested too, I can't really commit to take care of 
this at the moment. Harald and Serge, if you don't mind I will put you in 
contact with Michael Hofmeister so that you guys can work out the details?

Cheers,
Martin

-- 
name: Martin Albrecht
_pgp: http://pgp.mit.edu:11371/pks/lookup?op=getsearch=0x8EF0DC99
_otr: 47F43D1A 5D68C36F 468BAEBA 640E8856 D7951CCF
_www: http://www.informatik.uni-bremen.de/~malb
_jab: martinralbre...@jabber.ccc.de



--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: symbolic variable treated as sqrt(-1) when it shouldn't be

2009-09-03 Thread kcrisman



On Sep 3, 2:28 pm, William Stein wst...@gmail.com wrote:
 Hi Sage-Devel,

 What do you think of this:

 sage: var('x, i')
 sage: solve(x^2 + i == 0, x)
 [x == -sqrt(-I), x == sqrt(-I)]

 Basically, I make a purely symbolic variable which I happen to call
 i, and it gets treated somewhere (presumably in Maxima) as if it
 were sqrt(-1).

 Here is another instance of this:

 sage: var('i')
 i
 sage: a = i^2
 sage: a
 i^2
 sage: a.simplify_full()
 -1

 So Ginac treats things fine, but our use of Maxima messes it up.

 This came up for me just now when doing some symbolic calculation with
 a quaternion algebra where the generators are called i,j,k, and this
 i has nothing to do with sqrt(-1).

 Thoughts?

 William


I see your point.  I guess to me it's another instance of the should
x be predefined question - on the whole, it's better to make this
available.  It is also annoying when doing [f(i) for i in indexset],
but unless we can come up with another way to represent this, it will
be hard to do things with complexes very easily.  Luckily for me, I
don't usually need that, but others may very often.  Does this happen
with 'e' as well, or is that defined as a constant rather than a
variable?  It seems like both are symbolic.expression.Expression.

What do the other major systems do with this - do they insist on sqrt
(-1) or CC(i) or something like that?  If everyone expects this coming
in, it is an argument for it - not decisive, but a significant
argument.

- kcrisman
--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: symbolic variable treated as sqrt(-1) when it shouldn't be

2009-09-03 Thread William A. Stein


On Sep 3, 2009, at 12:49 PM, kcrisman wrote:




 On Sep 3, 2:28 pm, William Stein wst...@gmail.com wrote:
 Hi Sage-Devel,

 What do you think of this:

 sage: var('x, i')
 sage: solve(x^2 + i == 0, x)
 [x == -sqrt(-I), x == sqrt(-I)]

 Basically, I make a purely symbolic variable which I happen to call
 i, and it gets treated somewhere (presumably in Maxima) as if it
 were sqrt(-1).

 Here is another instance of this:

 sage: var('i')
 i
 sage: a = i^2
 sage: a
 i^2
 sage: a.simplify_full()
 -1

 So Ginac treats things fine, but our use of Maxima messes it up.

 This came up for me just now when doing some symbolic calculation  
 with
 a quaternion algebra where the generators are called i,j,k, and  
 this
 i has nothing to do with sqrt(-1).

 Thoughts?

 William


 I see your point.  I guess to me it's another instance of the should
 x be predefined question - on the whole, it's better to make this
 available.


I think my email must have not been clear.  I think it's an instance  
of a *HUGE BUG* in Sage.  No more, no less.It's a bug, because  
irregardless of anything being predefined, it makes no sense that  
simplifying via *maxima* would just happen to decide that the formal  
variable i is sqrt(-1), even though it isn't with Ginac.

William 


  It is also annoying when doing [f(i) for i in indexset],
 but unless we can come up with another way to represent this, it will
 be hard to do things with complexes very easily.  Luckily for me, I
 don't usually need that, but others may very often.  Does this happen
 with 'e' as well, or is that defined as a constant rather than a
 variable?  It seems like both are symbolic.expression.Expression.

 What do the other major systems do with this - do they insist on sqrt
 (-1) or CC(i) or something like that?  If everyone expects this coming
 in, it is an argument for it - not decisive, but a significant
 argument.

 - kcrisman
 


--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: symbolic variable treated as sqrt(-1) when it shouldn't be

2009-09-03 Thread Jason Grout

William Stein wrote:
 Hi Sage-Devel,
 
 What do you think of this:


I think you are right that this is a huge bug in our interface to maxima.

Jason



-- 
Jason Grout


--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: back ticks versus $ signs

2009-09-03 Thread John Cremona

I believe that people rather than abstractions should take priority.
We are used to using $...$ for maths, so why should we not make the
docs markup system we use adapt to us rather than the other way round?
 I find the view 'let's keep ReST/Sphinx in Sage pure ' very hard to
understand!

2009/9/3 William A. Stein wst...@gmail.com:


 That's a good idea.  It would certainly be better than having to
 change Sage -- it would keep things pure, but allow $'s, and even
 benefit you.  Great idea.   It's hard to argue with that.

I could not work out which idea is getting this thumbs up?  If we can
arrange for all single $ to be changed into ` that's fine by me.  I
have never used Ondrej's :math: in front, but maybe I should have.

John

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: back ticks versus $ signs

2009-09-03 Thread Rob Beezer

On Sep 3, 1:22 pm, John Cremona john.crem...@gmail.com wrote:
 I have never used Ondrej's :math: in front, but maybe I should have.

I recall seeing somewhere that in ReST/Sphinx you can configure a
default mode for the backticks, so I think Ondrej is writing docs
for one his other systems and he *must* use  math:`x^2` to get LaTeX
output.  However, Sage's installation has chosen to configure  the
defaults so that just `x^2` is treated as being in math mode.  So in
one sense, Sage already makes it easy to get math into the docs, since
we don't have to prepend with math: .  Having to add math: would make
William more totally crazy, but would perhaps reduce the confusion.
Not a vote, not even a suggestion.  Just some background (if I'm even
remembering right).

Rob
--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: back ticks versus $ signs

2009-09-03 Thread Nick Alexander

  [X] Yes, give me $'s!

  [ ] No, this doesn't bug me; let's keep ReST/Sphinx in Sage pure.

 I've been annoyed by this ever since we switched over to ReST.

I also have been annoyed by this.

Nick

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: back ticks versus $ signs

2009-09-03 Thread Tom Boothby

On Thu, Sep 3, 2009 at 1:22 PM, John Cremonajohn.crem...@gmail.com wrote:

 I believe that people rather than abstractions should take priority.
 We are used to using $...$ for maths, so why should we not make the
 docs markup system we use adapt to us rather than the other way round?
  I find the view 'let's keep ReST/Sphinx in Sage pure ' very hard to
 understand!

In general, Sage has gotten a lot of flak for breaking compatibility,
not upstreaming, etc.  So, I think we should try and avoid it.  If
nothing else, it increases the amount of effort required to upgrade.
OTOH, I'm hugely in favor of making this change to ReST/Sphinx, and
upstreaming it.


 2009/9/3 William A. Stein wst...@gmail.com:


 That's a good idea.  It would certainly be better than having to
 change Sage -- it would keep things pure, but allow $'s, and even
 benefit you.  Great idea.   It's hard to argue with that.

 I could not work out which idea is getting this thumbs up?  If we can
 arrange for all single $ to be changed into ` that's fine by me.  I
 have never used Ondrej's :math: in front, but maybe I should have.

 John

 


--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: back ticks versus $ signs

2009-09-03 Thread John H Palmieri

On Sep 3, 1:40 pm, Rob Beezer goo...@beezer.cotse.net wrote:
 On Sep 3, 1:22 pm, John Cremona john.crem...@gmail.com wrote:

  I have never used Ondrej's :math: in front, but maybe I should have.

 I recall seeing somewhere that in ReST/Sphinx you can configure a
 default mode for the backticks,

Right: in the file SAGE_ROOT/devel/sage/doc/common/conf.py, there are
the lines

# The reST default role (used for this markup: `text`) to use for all
documents.
default_role = 'math'

So in Sage docstrings you don't need :math:.

  John

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Organizing Sage worksheets: tags or categories?

2009-09-03 Thread Brian Granger
Hi,

Is there any way of organizing worksheets on a Sage notebook server?  If you
have many worksheets, it can be difficult to find them
and it would be nice to be able to organize them using tags, categories or
folders.  One example of this would be if wanted to write a chapter based
book
using the notebooks.  Then all the chapters could be a worksheet and all the
worksheets could go into a single folder/tag.

Thanks!

Brian

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: Organizing Sage worksheets: tags or categories?

2009-09-03 Thread William A. Stein


On Sep 3, 2009, at 2:17 PM, Brian Granger wrote:

 Hi,

 Is there any way of organizing worksheets on a Sage notebook  
 server?  If you have many worksheets, it can be difficult to find them
 and it would be nice to be able to organize them using tags,  
 categories or folders.  One example of this would be if wanted to  
 write a chapter based book
 using the notebooks.  Then all the chapters could be a worksheet and  
 all the worksheets could go into a single folder/tag.

No, there is no way to organize worksheets.   I'll implement something  
next month.  What should my highest priority be?

In practice, what I do is put something helpful in the title (a sort  
of tag), then use the text search in the upper right to locate all  
worksheets with that in them.

William

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: back ticks versus $ signs

2009-09-03 Thread David Roe
   [X] Yes, give me $'s!
 
   [ ] No, this doesn't bug me; let's keep ReST/Sphinx in Sage pure.


David

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: [fricas-devel] Re: Aldor interface

2009-09-03 Thread Ralf Hemmecke

Hi Bill,

On 09/03/2009 02:48 PM, Bill Page wrote:
 Ralf,
 
 I am sorry, I don't the logs to send but if you have any problems with
 the instructions below, then I can reproduce and send them later.
 
 Assuming that you already have Aldor and Sage installed, the commends:
 
 $ cd ~/sage-4.1.1
 $ wget http://www.mediafire.com/file/im5zd201mh0/fricas-1.0.7.p0.spkg
 $ ./sage -f fricas-1.0.7.spkg
 
 Produces the error:  undefined reference to `log' . (about 15 minutes)

Your wget does not quite work that way, but I got the file anyway from 
there to my ~/scratch directory.

Then I issued sage -f fricas-1.0.7.spkg inside ~/scratch. sage is in 
my PATH.

That seems to extract and then starts doing something, but without 
success. I have sage 4.1. Do I really need 4.1.1?

Is it relevant whether or not I run on a 32bit system?

I don't have ecl on my system. Shouldn't the fricas spkg just use the 
lisp provided by sage? Or do I have to install ECL?

Ralf

...
fricas-1.0.7.p0/src/src/ChangeLog.bu 

fricas-1.0.7.p0/src/confignotes.tex 

Finished extraction 

 

Host system 

uname -a: 

Linux woodpecker 2.6.28-15-generic #49-Ubuntu SMP Tue Aug 18 18:40:08 
UTC 2009 i686 GNU/Linux 

 

 

GCC Version 

gcc -v 

Using built-in specs. 

Target: i486-linux-gnu 

Configured with: ../src/configure -v --with-pkgversion='Ubuntu 
4.3.3-5ubuntu4' --with-bugurl=file:///usr/share/doc/gcc-4.3/README.Bugs 
--enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr 
--enable-shared --with-system-zlib --libexecdir=/usr/lib 
--without-included-gettext --enable-threads=posix --enable-nls 
--with-gxx-include-dir=/usr/include/c++/4.3 --program-suffix=-4.3 
--enable-clocale=gnu --enable-libstdcxx-debug --enable-objc-gc 
--enable-mpfr --enable-targets=all --with-tune=generic 
--enable-checking=release --build=i486-linux-gnu --host=i486-linux-gnu 
--target=i486-linux-gnu
Thread model: posix 

gcc version 4.3.3 (Ubuntu 4.3.3-5ubuntu4) 

 

checking build system type... i686-pc-linux 

checking host system type... i686-pc-linux 

checking target system type... i686-pc-linux 

checking for make... make 

checking for gcc... gcc 

checking for C compiler default output file name... a.out 

checking whether the C compiler works... yes 

checking whether we are cross compiling... no 

checking for suffix of executables... 

checking for suffix of object files... o 

checking whether we are using the GNU C compiler... yes 

checking whether gcc accepts -g... yes 

checking for gcc option to accept ISO C89... none needed 

checking for a BSD-compatible install... /usr/bin/install -c 

checking for touch... touch 

checking for mktemp... mktemp 

checking for gawk... gawk 

checking for gtar... no 

checking for tar... tar 

checking for gpatch... no 

checking for patch... patch 

checking for ranlib... ranlib 

checking for ar... ar 

checking for latex... /usr/bin/latex 

checking for makeindex... makeindex 

checking for notangle... notangle 

checking for noweave... noweave 

checking Lisp implementation... ECL (Embeddable Common-Lisp) 9.4.1 

Copyright (C) 1984 Taiichi Yuasa and Masami Hagiya 

Copyright (C) 1993 Giuseppe Attardi 

Copyright (C) 2000 Juan J. Garcia-Ripoll 

ECL is free software, and you are welcome to redistribute it 

under certain conditions; see file 'Copyright' for details. 

Type :h for Help.  Top level. 

  

;;; Loading 
/home/hemmecke/software/sage/spkg/build/fricas-1.0.7.p0/src/config.lisp 

Filesystem error with pathname #PSYS:cmp.NEWEST. 

Either 

  1) the file does not exist, or 

  2) we are not allow to access the file, or 

  3) the pathname points to a broken symbolic link. 

Broken at SI:BYTECODES.No restarts available. 

Broken at SI:BYTECODES. File: 
#P/home/hemmecke/software/sage-4.1-linux-Ubuntu_9.04-i686-Linux/spkg/build/fricas-1.0.7.p0/src/config.lisp
 
(Form #1)
 
configure: error: Unable to determine Lisp flavor
***
Failed to configure FriCAS.
***

real0m5.143s
user0m0.736s
sys 0m0.548s
sage: An error occurred while installing fricas-1.0.7.p0
Please email sage-devel http://groups.google.com/group/sage-devel
explaining the problem and send the relevant part of
of /home/hemmecke/software/sage/install.log.  Describe your computer, 
operating system, etc.
If you want to try to fix the problem, yourself *don't* just cd to
/home/hemmecke/software/sage/spkg/build/fricas-1.0.7.p0 and type 'make'.
Instead type /home/hemmecke/software/sage/sage -sh
in order to set all environment variables correctly, then cd to
/home/hemmecke/software/sage/spkg/build/fricas-1.0.7.p0
(When you are done debugging, you can type exit to leave the
subshell.)


[sage-devel] Re: Aldor interface

2009-09-03 Thread Nils Bruin

On Sep 3, 2:32 pm, Ralf Hemmecke r...@hemmecke.de wrote:

 That seems to extract and then starts doing something, but without
 success. I have sage 4.1. Do I really need 4.1.1?

 Is it relevant whether or not I run on a 32bit system?

 I don't have ecl on my system. Shouldn't the fricas spkg just use the
 lisp provided by sage? Or do I have to install ECL?

sage does ship with ecl, but 4.1.1 ships with a rather old version,
which may be the problem.
 Upgrade is in progress. You could do

sh$ sage -i -s http://sage.math.washington.edu/home/ghitza/ecl-9.8.4.spkg


--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: [fricas-devel] Re: Aldor interface

2009-09-03 Thread Bill Page

Ralf,

On Thu, Sep 3, 2009 at 5:32 PM, Ralf Hemmecke wrote:

 On 09/03/2009 02:48 PM, Bill Page wrote:
 I am sorry, I don't the logs to send but if you have any problems with
 the instructions below, then I can reproduce and send them later.

 Assuming that you already have Aldor and Sage installed, the commends:

 $ cd ~/sage-4.1.1
 $ wget http://www.mediafire.com/file/im5zd201mh0/fricas-1.0.7.p0.spkg
 $ ./sage -f fricas-1.0.7.spkg

 Produces the error:  undefined reference to `log' . (about 15 minutes)

 Your wget does not quite work that way, but I got the file anyway from
 there to my ~/scratch directory.


Ok, sorry. I guess it is on some kind of sharing site that forces
you to read annoying advertisements or something. I don't know why the
developer did not put it directly on the sage site.

 Then I issued sage -f fricas-1.0.7.spkg inside ~/scratch. sage is in
 my PATH.

 That seems to extract and then starts doing something, but without
 success. I have sage 4.1. Do I really need 4.1.1?


I don't think so. I think 4.1 should be ok. But for sure you do need a
version of Sage where ECL is the default lisp.

 Is it relevant whether or not I run on a 32bit system?


No, I don't think so.

 I don't have ecl on my system. Shouldn't the fricas spkg just use the
 lisp provided by sage?

Yes. Your log shows that it found ECL (Embeddable Common-Lisp) 9.4.1.

 Or do I have to install ECL?


No, it is not necessary to install ECL separately  to install FriCAS in Sage.

But as Nils pointed out, ECL 9.4.1 is now also a little old. I think
Waldek mentioned earlier that he had a problem building FriCAS with
9.4.1 or similar version.  I had forgotten that for other reasons I
had already upgraded the ECL version in version 4.1.1 of Sage that I
have installed on my system. You should definitely ECL also upgrade
via

sage -i -s http://sage.math.washington.edu/home/ghitza/ecl-9.8.4.spkg

 ...

Regards,
Bill Page.

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: back ticks versus $ signs

2009-09-03 Thread gsw


 and it bugs me that I have to type

 :math:`\eta`

 instead of just $\eta$. So how about submitting a patch to sphinx fixing it?

+1

Cheers,
Georg


 Ondrej
--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: back ticks versus $ signs

2009-09-03 Thread John H Palmieri

On Sep 3, 12:37 pm, William A. Stein wst...@gmail.com wrote:
 On Sep 3, 2009, at 12:28 PM, Ondrej Certik wrote:

  So how about submitting a patch to sphinx  
  fixing it?

  Ondrej

 That's a good idea.  It would certainly be better than having to  
 change Sage -- it would keep things pure, but allow $'s, and even  
 benefit you.  Great idea.   It's hard to argue with that.

Well, dollar signs are mentioned (briefly) in the Sphinx
documentation, in the part about writing extensions.  So we could
write an extension for Sphinx which replaces $ with `, or
optionally replaces $blah$ with :math:`blah`.  I don't want to
make it too fancy, so it ought to be a pretty simple regular
expression search and replace.  How does that sound?

More precisely: we can have a Sphinx extension with a configurable
option; set one way, it will replace $blah$ with `blah` (and
replace \$ with $).  Set the other way, it will replace $blah$
with :math:`blah` (and replace \$ with $).

What else should we do?  Do we have to deal with $$ blah $$?  \
[ blah \]?  I don't want this to be too involved, or we'll end up
writing a LaTeX compiler.

  John

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: symbolic variable treated as sqrt(-1) when it shouldn't be

2009-09-03 Thread William Stein

2009/9/3 Golam Mortuza Hossain gmhoss...@gmail.com:

 Hi,

 On Thu, Sep 3, 2009 at 5:00 PM, William A. Steinwst...@gmail.com wrote:
 sage: var('i')
 i
 sage: a = i^2
 sage: a.simplify_full()
 -1
 I think my email must have not been clear.  I think it's an instance
 of a *HUGE BUG* in Sage.  No more, no less.    It's a bug, because
 irregardless of anything being predefined, it makes no sense that
 simplifying via *maxima* would just happen to decide that the formal
 variable i is sqrt(-1), even though it isn't with Ginac.

 This seems to be a problem with the way Sage convert back
 maxima-returned string intro SR. So Maxima is NOT doing anything
 wrong.

 ---
 sage: from sage.calculus.calculus import 
 symbolic_expression_from_maxima_string
 sage: symbolic_expression_from_maxima_string('%i')
 I
 sage: symbolic_expression_from_maxima_string('i')
 I
 ---

 So as you see, we are converting both '%i' and 'i' to  imaginary 'I' 


Yes, that completely nails down the bug.  Thanks.  This is now 6882:

http://trac.sagemath.org/sage_trac/ticket/6882

William

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: Organizing Sage worksheets: tags or categories?

2009-09-03 Thread William Stein

2009/9/3 Brian Granger ellisonbg@gmail.com:

  Is there any way of organizing worksheets on a Sage notebook
  server?  If you have many worksheets, it can be difficult to find them
  and it would be nice to be able to organize them using tags,
  categories or folders.  One example of this would be if wanted to
  write a chapter based book
  using the notebooks.  Then all the chapters could be a worksheet and
  all the worksheets could go into a single folder/tag.

 No, there is no way to organize worksheets.   I'll implement something
 next month.  What should my highest priority be?


 Thanks, that would be fantastic!  I think the simplest thing to implement is 
 a tag/label based system like gmail has.  That is nice because you can have 
 multiple tags/labels on a single worksheet.  The thing that would make this 
 most useful is if the tag could be embedded into the url:

 mysagenbserver.com/bgranger/tags/physics  # Show all my notebooks with 
 'physics' in tags
 mysagenbserver.com/pub/tags/physics # Show all published notebooks with 
 'physics' in tags

 That way it would be very simple to organize notebooks for 
 classes/topics/etc. by tag and share them with other people (like students).


 In practice, what I do is put something helpful in the title (a sort
 of tag), then use the text search in the upper right to locate all
 worksheets with that in them.

 OK, that will get me by for now.

 Cheers,

 Brian

 PS - I am currently in the process of getting some servers for our department 
 - one of the main uses will be to run sage notebook servers for our Physics 
 classes here at Cal Poly.



Here's my scraps of notes related to notebook work for Oct - Dec, by the way:

http://sage.math.washington.edu/home/wstein/tmp/sageuse/

William

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: Organizing Sage worksheets: tags or categories?

2009-09-03 Thread Brian Granger
  Is there any way of organizing worksheets on a Sage notebook
  server?  If you have many worksheets, it can be difficult to find them
  and it would be nice to be able to organize them using tags,
  categories or folders.  One example of this would be if wanted to
  write a chapter based book
  using the notebooks.  Then all the chapters could be a worksheet and
  all the worksheets could go into a single folder/tag.

 No, there is no way to organize worksheets.   I'll implement something
 next month.  What should my highest priority be?


Thanks, that would be fantastic!  I think the simplest thing to implement is
a tag/label based system like gmail has.  That is nice because you can have
multiple tags/labels on a single worksheet.  The thing that would make this
most useful is if the tag could be embedded into the url:

mysagenbserver.com/bgranger/tags/physics  # Show all my notebooks with
'physics' in tags
mysagenbserver.com/pub/tags/physics # Show all published notebooks with
'physics' in tags

That way it would be very simple to organize notebooks for
classes/topics/etc. by tag and share them with other people (like students).


 In practice, what I do is put something helpful in the title (a sort
 of tag), then use the text search in the upper right to locate all
 worksheets with that in them.


OK, that will get me by for now.

Cheers,

Brian

PS - I am currently in the process of getting some servers for our
department - one of the main uses will be to run sage notebook servers for
our Physics classes here at Cal Poly.






 William

 


--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: Organizing Sage worksheets: tags or categories?

2009-09-03 Thread Pat LeSmithe

William Stein wrote:
 Here's my scraps of notes related to notebook work for Oct - Dec, by the way:
 http://sage.math.washington.edu/home/wstein/tmp/sageuse/

Assuming it's OK, I've started to organize / summarize ideas.txt at

http://wiki.sagemath.org/SageUsability

Please feel free to amend, annotate, append, etc.


--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: back ticks versus $ signs

2009-09-03 Thread Jason Grout

John H Palmieri wrote:
 On Sep 3, 12:37 pm, William A. Stein wst...@gmail.com wrote:
 On Sep 3, 2009, at 12:28 PM, Ondrej Certik wrote:

 So how about submitting a patch to sphinx  
 fixing it?
 Ondrej
 That's a good idea.  It would certainly be better than having to  
 change Sage -- it would keep things pure, but allow $'s, and even  
 benefit you.  Great idea.   It's hard to argue with that.
 
 Well, dollar signs are mentioned (briefly) in the Sphinx
 documentation, in the part about writing extensions.  So we could
 write an extension for Sphinx which replaces $ with `, or
 optionally replaces $blah$ with :math:`blah`.  I don't want to
 make it too fancy, so it ought to be a pretty simple regular
 expression search and replace.  How does that sound?
 
 More precisely: we can have a Sphinx extension with a configurable
 option; set one way, it will replace $blah$ with `blah` (and
 replace \$ with $).  Set the other way, it will replace $blah$
 with :math:`blah` (and replace \$ with $).
 
 What else should we do?  Do we have to deal with $$ blah $$?  \
 [ blah \]?  I don't want this to be too involved, or we'll end up
 writing a LaTeX compiler.


Would it be too hard to make a more general (and useful) 
custom-delimiter extension, that would allow a person to specify a 
right and left delimiter that is just textually replaced with the mode 
of their choice?  Our configuration would look something like:

right_delimiter='$'
left_delimiter='$'
mode=math


Jason



-- 
Jason Grout


--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: back ticks versus $ signs

2009-09-03 Thread John H Palmieri

On Sep 3, 5:54 pm, Jason Grout jason-s...@creativetrax.com wrote:
 John H Palmieri wrote:
  On Sep 3, 12:37 pm, William A. Stein wst...@gmail.com wrote:
  On Sep 3, 2009, at 12:28 PM, Ondrej Certik wrote:

  So how about submitting a patch to sphinx  
  fixing it?
  Ondrej
  That's a good idea.  It would certainly be better than having to  
  change Sage -- it would keep things pure, but allow $'s, and even  
  benefit you.  Great idea.   It's hard to argue with that.

  Well, dollar signs are mentioned (briefly) in the Sphinx
  documentation, in the part about writing extensions.  So we could
  write an extension for Sphinx which replaces $ with `, or
  optionally replaces $blah$ with :math:`blah`.  I don't want to
  make it too fancy, so it ought to be a pretty simple regular
  expression search and replace.  How does that sound?

  More precisely: we can have a Sphinx extension with a configurable
  option; set one way, it will replace $blah$ with `blah` (and
  replace \$ with $).  Set the other way, it will replace $blah$
  with :math:`blah` (and replace \$ with $).

  What else should we do?  Do we have to deal with $$ blah $$?  \
  [ blah \]?  I don't want this to be too involved, or we'll end up
  writing a LaTeX compiler.

 Would it be too hard to make a more general (and useful)
 custom-delimiter extension, that would allow a person to specify a
 right and left delimiter that is just textually replaced with the mode
 of their choice?  Our configuration would look something like:

 right_delimiter='$'
 left_delimiter='$'
 mode=math

Since writing my previous message, I realized that it's easier to not
write our own extension but instead to work with Sphinx's autodoc
extension.  The autodoc extension is what extracts the docstrings to
create the reference manual, and it can be configured to pass the
docstrings to user-defined functions for preprocessing.  I think
that's the right thing for us to do: search for $ and replace it
with `.

So while I think that we could make custom delimiters work, the whole
thing won't be a stand-alone extension, so this approach may not be
that useful.  But I'll try to play with it.

  John

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] searching google groups

2009-09-03 Thread Jason Grout

Every time (that I can remember) that I've tried searching google groups 
online for a post, I've given up in frustration and gone back to 
searching in thunderbird (I follow sage-devel from gmane).  Just now, I 
tried to find a specific thread.  When keywords didn't work, I quickly 
found the thread in thunderbird and typed the subject on the thread into 
the search box at http://groups.google.com/group/sage-devel.  Google 
*still* couldn't find any related messages.  Can anyone tell me how to 
find a post with title wysiwyg mathematics, posted by me, on 2 Jul 
2009, without paging back through every post since then to find it in 
the chronological listings?  How do other people manage to search for 
messages?

I know what the message says, thanks to Thunderbird; I just want to link 
to it.  I found the message pretty easily on gmane; I might just start 
linking there.

If you can find any easy way to find this message on google groups, 
please let me know for future searches!

http://article.gmane.org/gmane.comp.mathematics.sage.devel/27294/match=wysiwyg+mathematics

Thanks,

Jason

-- 
Jason Grout


--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: searching google groups

2009-09-03 Thread John H Palmieri

On Sep 3, 7:12 pm, Jason Grout jason-s...@creativetrax.com wrote:
 Every time (that I can remember) that I've tried searching google groups
 online for a post, I've given up in frustration and gone back to
 searching in thunderbird (I follow sage-devel from gmane).  Just now, I
 tried to find a specific thread.  When keywords didn't work, I quickly
 found the thread in thunderbird and typed the subject on the thread into
 the search box athttp://groups.google.com/group/sage-devel.  

In that search box, type

  wysiwyg mathematics group:sage-devel

and then hit the Search Groups button (rather than the Search this
group button).  Someone suggested this a month or two ago, and it
seems to work pretty well. You can do the same search from the main
Google groups page, http://groups.google.com/.

  John

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Sage 4.1.2.alpha0 released

2009-09-03 Thread Minh Nguyen

Hi folks,

This is the first alpha release of Sage 4.1.2. Source and the
sage.math binary are available at

http://sage.math.washington.edu/home/mvngu/release/upgrade/sage-4.1.2.alpha0.tar
http://sage.math.washington.edu/home/mvngu/release/upgrade/sage-4.1.2.alpha0-sage.math.washington.edu-x86_64-Linux.tar.gz

The upgrade path is

http://sage.math.washington.edu/home/mvngu/release/upgrade/sage-4.1.2.alpha0/

These three URLs can also be found on the milestone page for sage-4.1.2:

http://trac.sagemath.org/sage_trac/milestone/sage-4.1.2

Please test and report all problems.

We updated four standard packages:

* ecl-9.8.4.spkg
* maxima-5.19.1.p0.spkg
* mpmath-0.13.spkg
* singular-3-1-0-4-20090818.spkg

and two optional packages:

* cbc-2.3.spkg
* glpk-4.38.p0.spkg

Due to 32- versus 64-bit issues with cliquer, sage-4.1.2.alpha0 fails
to compile from source on some platforms. If you are upgrading or
building in 64-bit mode on OS X 10.5.8, you might need to install
Michael Abshoff's Fortran spkg. Instructions can be found at

http://mvngu.wordpress.com/2009/09/02/compile-sage-4-1-in-64-bit-mode-on-os-x-10-5-8/

When building Sage 4.1.2.alpha0 in 64-bit mode on OS X 10.5.8,
ecl-9.8.4.spkg may fail to build because its configure script claims
that GMP is not found. You might get an error message like so:

checking for __gmpz_init in -lgmp... no
configure: error: System gmp library requested but not found.
Failed to configure ECL ... exiting

real0m3.058s
user0m1.077s
sys 0m1.950s
sage: An error occurred while installing ecl-9.8.4

Sage 4.1.2.alpha0 fails to build on Fedora 9 x86_64 with GCC 4.4.1
(eno) due to an error building mpmath-0.13.spkg. It also fails to
build on openSUSE 11.1 x86_64 with GCC 4.4.1 (menas) due to an error
building cliquer on 64-bit platforms.

The following tickets were closed as being confirmed fixed in Sage
4.1.1 or the issue under consideration was fixed by another ticket.

#1343: singular factorize is randomly slow [confirmed as fixed in Sage 4.1.1]
#3895: sage-notebook-insecure ImportError [confirmed as fixed in Sage 4.1.1]
#4622: certain input for variety() crashes Singular [reported
upstream] [confirmed as fixed in Sage 4.1.1]
#6782: doctest failure in doc/en/constructions/calculus.rst due to
upgrade to Maxima 5.19.1 [fixed by #6699]
#6783: fix doctest failures in doc/en/constructions/linear_algebra.rst
due to upgrade to Maxima 5.19.1 [fixed by #6699]
#6784: fix doctest failures in
doc/en/constructions/interface_issues.rst due to upgrade to Maxima
5.19.1 [fixed by #6699]
#6785: fix doctest failure in doc/en/constructions/plotting.rst due to
upgrade to Maxima 5.19.1 [fixed by #6699]
#6786: fix doctest failures in doc/en/tutorial/tour_algebra.rst due to
upgrade to Maxima 5.19.1 [fixed by #6699]
#6787: fix doctest failures in doc/en/tutorial/interfaces.rst due to
upgrade to Maxima 5.19.1 [fixed by #6699]
#6789: fix doctest failures in symbolic/expression.pyx due to upgrade
to Maxima 5.19.1 [fixed by #6699]
#6792: fix doctest failures in doc/fr/tutorial/interfaces.rst due to
upgrade to Maxima 5.19.1 [fixed by #6699]

The following tickets were merged in Sage 4.1.2.alpha0:

#3108: John Cremona: implement additive_order for elliptic curve
points [Reviewed by Chris Wuthrich]
#4135: Timothy Clemans: notebook -- user management features [Reviewed
by Tim Dumol, Dan Drake]
#4822: John Cremona: Tweak to the error message for EllipticCurve
[Reviewed by Chris Wuthrich]
#5600: Nicolas M. Thiéry: Cleanup of integer compositions [Reviewed by
Dan Drake, Jason Bandlow, Minh Van Nguyen]
#5660: John Cremona: count_points(1) for elliptic curves over finite
fields is stupid [Reviewed by Alex Ghitza]
#5726: John Palmieri: Definition: missing/wrong/messed up both in
notebook and command line in different ways for both python and cython
code (frickin') [Reviewed by Tim Dumol]
#5857: John Cremona: E.list() for E an elliptic curve over a finite
field is broken [Reviewed by Alex Ghitza, Minh Van Nguyen]
#5958: John Perry: MPolynomial_polydict.factor() should accept proof
parameter [Reviewed by Martin Albrecht]
#6253: Nicolas M. Thiéry: Constant functions [Reviewed by Florent
Hivert, Minh Van Nguyen]
#6287: Adam Webb: sage -lisp should run ECL [Reviewed by Franco Saliola]
#6294: Adam Webb: lisp command in sage is now totally broken (because
of ecl switch) [Reviewed by Tim Dumol]
#6384: Chris Wuthrich: elliptic curve -- isogeny function is not
robust -- it doesn't check validity of its input [Reviewed by John
Cremona, Minh Van Nguyen]
#6402: David Loeffler: Fix bugs + improve documentation for
overconvergent modular forms [Reviewed by Alex Ghitza, Minh Van
Nguyen]
#6447: Bill Cauchois: Add a canvas renderer for 3D plotting
[Reviewed by David Joyner, William Stein]
#6461: Minh Van Nguyen: Schaefer's Simplified Data Encryption Standard
for educational purposes [Reviewed by Martin Albrecht, William Stein]
#6464: Jin-yeong Bak (NoSyu): notebook: Unicode in notebook
worksheets [Reviewed by Peter Mora, 

[sage-devel] Re: Organizing Sage worksheets: tags or categories?

2009-09-03 Thread William Stein

2009/9/3 Pat LeSmithe qed...@gmail.com:

 William Stein wrote:
 Here's my scraps of notes related to notebook work for Oct - Dec, by the way:
 http://sage.math.washington.edu/home/wstein/tmp/sageuse/

 Assuming it's OK, I've started to organize / summarize ideas.txt at

 http://wiki.sagemath.org/SageUsability

 Please feel free to amend, annotate, append, etc.

Wow, thanks!!

William

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: searching google groups

2009-09-03 Thread William Stein

On Thu, Sep 3, 2009 at 7:12 PM, Jason Groutjason-s...@creativetrax.com wrote:

 Every time (that I can remember) that I've tried searching google groups
 online for a post, I've given up in frustration and gone back to
 searching in thunderbird (I follow sage-devel from gmane).  Just now, I
 tried to find a specific thread.  When keywords didn't work, I quickly
 found the thread in thunderbird and typed the subject on the thread into
 the search box at http://groups.google.com/group/sage-devel.  Google
 *still* couldn't find any related messages.  Can anyone tell me how to
 find a post with title wysiwyg mathematics, posted by me, on 2 Jul
 2009, without paging back through every post since then to find it in
 the chronological listings?  How do other people manage to search for
 messages?

If you go to the search box at

http://groups.google.com/group/sage-devel

and type

   wysiwyg mathematics

into it, then click Search Groups, then Google instantly finds the
message you want as the first hit.

William


 I know what the message says, thanks to Thunderbird; I just want to link
 to it.  I found the message pretty easily on gmane; I might just start
 linking there.

 If you can find any easy way to find this message on google groups,
 please let me know for future searches!

 http://article.gmane.org/gmane.comp.mathematics.sage.devel/27294/match=wysiwyg+mathematics

 Thanks,

 Jason

 --
 Jason Grout


 




-- 
William Stein
Associate Professor of Mathematics
University of Washington
http://wstein.org

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Embedded SVG editor in the notebook?

2009-09-03 Thread Pat LeSmithe

I noticed SVG-edit, a Scalable Vector Graphics (SVG) editor that works
entirely in capable browsers [1]:

http://code.google.com/p/svg-edit/

Stable and beta demos:

http://svg-edit.googlecode.com/svn/tags/stable/editor/svg-editor.html
http://svg-edit.googlecode.com/svn/trunk/editor/svg-editor.html

Compared to Inkscape, it's quite light, but this may be an advantage.
It does appear to be actively developed.  Are there other or better
examples?

Not impossible uses in Sage:

 * Draw diagrams.
 * Annotate images.
 * Manipulate graphs.
 * Put cells anywhere.
 * Add audio and video.

Can jsMath render expressions as SVG groups?  I think this depends
partly on font support.

By the way, how about syntax highlighting for equations?  jsMath can
easily do color:

http://www.math.union.edu/~dpvc/jsMath/examples/extensions.html

Would this be useful for teaching?  I'm not sure about how to add color
attributes to symbolic variables.


[1] IE supports Vector Markup Language (VML) instead of SVG.  The svgweb
project aims to set up Flash as a non-native SVG renderer:

http://code.google.com/p/svgweb/


--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: Embedded SVG editor in the notebook?

2009-09-03 Thread William A. Stein


On Sep 3, 2009, at 10:17 PM, Pat LeSmithe wrote:


 I noticed SVG-edit, a Scalable Vector Graphics (SVG) editor that works
 entirely in capable browsers [1]:

 http://code.google.com/p/svg-edit/

 Stable and beta demos:

 http://svg-edit.googlecode.com/svn/tags/stable/editor/svg-editor.html
 http://svg-edit.googlecode.com/svn/trunk/editor/svg-editor.html

 Compared to Inkscape, it's quite light, but this may be an advantage.
 It does appear to be actively developed.  Are there other or better
 examples?

That is absolutely amazing!!  Wow.


 Not impossible uses in Sage:

 * Draw diagrams.
 * Annotate images.
 * Manipulate graphs.
 * Put cells anywhere.
 * Add audio and video.

Yes indeed.  This would be very nice, since one could say draw a plot,  
then edit it to fine tune things and add extra annotation.

Also, it would just be very nice having an easy scratchpad anywhere in  
an worksheet.

Very cool.

William


 Can jsMath render expressions as SVG groups?  I think this depends
 partly on font support.

 By the way, how about syntax highlighting for equations?  jsMath can
 easily do color:

 http://www.math.union.edu/~dpvc/jsMath/examples/extensions.html

 Would this be useful for teaching?  I'm not sure about how to add  
 color
 attributes to symbolic variables.


 [1] IE supports Vector Markup Language (VML) instead of SVG.  The  
 svgweb
 project aims to set up Flash as a non-native SVG renderer:

 http://code.google.com/p/svgweb/


 


--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---



[sage-devel] Re: Sage 4.1.2.alpha0 released

2009-09-03 Thread Minh Nguyen

On Fri, Sep 4, 2009 at 1:05 PM, Minh Nguyennguyenmi...@gmail.com wrote:
 Hi folks,

 This is the first alpha release of Sage 4.1.2. Source and the
 sage.math binary are available at

 http://sage.math.washington.edu/home/mvngu/release/upgrade/sage-4.1.2.alpha0.tar
 http://sage.math.washington.edu/home/mvngu/release/upgrade/sage-4.1.2.alpha0-sage.math.washington.edu-x86_64-Linux.tar.gz

 The upgrade path is

 http://sage.math.washington.edu/home/mvngu/release/upgrade/sage-4.1.2.alpha0/

You can also try out the notebook of this alpha version at

http://alpha.sagenb.org

-- 
Regards
Minh Van Nguyen

--~--~-~--~~~---~--~~
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an 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
-~--~~~~--~~--~--~---