Re: [sage-devel] Re: Literal matrix syntax

2012-01-26 Thread daly
On Thu, 2012-01-26 at 02:06 -0800, David Roe wrote:
  As for global defaults, it's nice for both examples and debugging for
  there to be as little global state as possible, and someone who wants
  RDF for reals probably wants CDF for complexes. The consistency
  argument is a good one, but changing matrix(...) would be much more
  invasive, and both defaults have their pros and cons, so the simpler
  syntax could be used for the simpler (i.e. more basic user that
  doesn't want to care about baserings but just wants to slice and dice
  some matrices) default.
 
 I agree that having very little global state is good, but right now I
 don't think that Sage is succeeding very well in our mission to
 provide a viable alternative to Matlab.  I would like to see more
 users to Sage who care about floating point linear algebra, and I
 think it's worth having some global state if we can attract such
 people by making it easier to create matrices with floats.
 David
 

Axiom associates the target type of the input so you type
a:Matrix(Integer) := [[1]]
or 
b:Matrix(Float) := [[1.1]]

or for larger values
c:Matrix(Integer) := [[1,2,3],[4,5,6]]
d:Matrix(Float) := [[1.1,2.1,3.1],[4.1,5.1,6.1]]

Tim Daly



-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Literal matrix syntax

2012-01-26 Thread daly
On Thu, 2012-01-26 at 02:24 -0800, Robert Bradshaw wrote:
 On Thu, Jan 26, 2012 at 2:16 AM, daly d...@axiom-developer.org wrote:
  On Thu, 2012-01-26 at 02:06 -0800, David Roe wrote:
   As for global defaults, it's nice for both examples and debugging for
   there to be as little global state as possible, and someone who wants
   RDF for reals probably wants CDF for complexes. The consistency
   argument is a good one, but changing matrix(...) would be much more
   invasive, and both defaults have their pros and cons, so the simpler
   syntax could be used for the simpler (i.e. more basic user that
   doesn't want to care about baserings but just wants to slice and dice
   some matrices) default.
 
  I agree that having very little global state is good, but right now I
  don't think that Sage is succeeding very well in our mission to
  provide a viable alternative to Matlab.  I would like to see more
  users to Sage who care about floating point linear algebra, and I
  think it's worth having some global state if we can attract such
  people by making it easier to create matrices with floats.
  David
 
 
  Axiom associates the target type of the input so you type
  a:Matrix(Integer) := [[1]]
  or
  b:Matrix(Float) := [[1.1]]
 
  or for larger values
  c:Matrix(Integer) := [[1,2,3],[4,5,6]]
  d:Matrix(Float) := [[1.1,2.1,3.1],[4.1,5.1,6.1]]
 
 One can always make it explicit, e.g. matrix(QQ, [[1,2],[3,4]]) or
 (hypothetically) [1, 2; 3, 4; base_ring=QQ]; the question is about
 what to do in the implicit case. IMHO, the current default doesn't
 suit many users well, in particular it does disservice to those users
 who wouldn't even think to specify the basering.

Sorry, I was unclear. Axiom associates the type with the target, so

a:= [[1,2,3],[4,5,6]]  == List List Integer
b:Matrix(Float)== Type: Void
c:Matrix(Integer)  == Type: Void
d:Matrix(RomanNumeral) == Type: Void
e:Matrix(Fraction(Integer) == Type: Void
b:=a
   + 1.0 2.0 3.0 +
   | |
   + 4.0 5.0 6.0 +
   == Type: Matrix Float
so the line b:Matrix(Float) means that the symbol
'b' expects to hold something of the type Matrix(Float).
The assignment b:=a assigned a List(List(Integer)) to
the type of 'b' which causes an implicit coerce to the
target type.

c:=a
   + 1 2 3 +
   |   |
   + 4 5 6 +
   == Type: Matrix Integer
Working from the same List(List(Integer)) we get a
different base ring of the matrix.

d:=a
   + I   II   III+
   | |
   + IV   V   VI +
   == Type: Matrix RomanNumeral

I don't know how Sage handles the 'd:=a' case above.

e:=a
   + 1 2 3 +
   |   |
   + 4 5 6 +
   == Type: Matrix Fraction Integer

Notice the output of the assignment 'c:=a' and 'e:=a'
APPEAR to be the same but this is only because the
denominator is 1.

e:=[[1/2, 1/3, 1/4],[1/5,1/6,1/7]]
   + 1 1 1+
   | - - -|
   | 2 3 4|
   |  |
   | 1 1 1|
   | - - -|
   + 5 6 7+

It seems that if you have many possible base rings 
(which Axiom has) you need either an explicit coerce
when the object is created or you need to know how to
coerce a general input type (in this case, list) into
the target type.

So I am suggesting that a clean syntax is possible if
the base ring is associated with the target symbol, not
with the input tokens.

Tim Daly



-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Literal matrix syntax

2012-01-26 Thread daly
On Thu, 2012-01-26 at 03:05 -0800, David Roe wrote:
  So I am suggesting that a clean syntax is possible if
  the base ring is associated with the target symbol, not
  with the input tokens.
 
 Apprently in Axiom you can statically type variable names, whereas in
 Python a variable is dynamically typed: you can't specify that a
 should hold an Integer for example.
 
 sage: a = 4; type(a)
 type 'sage.rings.integer.Integer'
 sage: a = 4/3; type(a)
 type 'sage.rings.rational.Rational'
 David
 
The fact that the type is different seems to imply
that Sage must manipulate the input somehow. Python
does not know about rings. How is this done? Could
the processing allow you to specify the type of the
target with a particular syntax? All you need to do
is keep a hash table of the specified target type.
If the symbol is not found then do the usual process
else use the specified target type.

Tim Daly



-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Two articles of interest to Sage in latest Notices

2012-01-19 Thread daly
On Wed, 2012-01-18 at 23:45 +0100, Burcin Erocal wrote:
 On Wed, 18 Jan 2012 12:26:33 -0800 (PST)
 kcrisman kcris...@gmail.com wrote:
  
  Publishing Computational Mathematics, by Tim Daly (of Axiom, a
  frequent contributor on sage-devel)
  http://www.ams.org/notices/201202/rtx120200320p.pdf
 
 Literate programming is not just adding comments to code, but here are
 a few numbers nevertheless...
 
 FriCAS (I couldn't find Axiom on ohloh.net):
   https://www.ohloh.net/p/fricas
# of lines of code: 1218007
# of comment lines:  205615

http://en.wikipedia.org/wiki/Axiom_computer_algebra_system
http://axiom-developer.org

Axiom has a project focus to become a literate program.
FriCAS has a project focus to compete with Mathematica.
Due to this philosophical difference the Axiom project
forked. 

New computational mathematics is always interesting but
it is more important to make sure that the code can be
modified and maintained without devoting your life to
the task. Projects die when the original authors leave.
Sourceforge has 100,000 piles of dead code. In order
to keep Axiom alive it must be possible to understand,
modify, and maintain it. I firmly believe that literate
programming is the only technology that can achieve this.

Axiom is being rewritten to be fully literate. The code
is being moved from a tree of little files to volumes
with a particular focus. There are currently 21 volumes.

These volumes contain actual executable source code which
is extracted at build time. So the code you see in the
books is the actual source code.

There are still many small files to rewrite and distribute
into their proper locations and there is still a great
deal of explanation to be added to the volumes. However,
this project has a 30 year horizon so this huge task
is right on schedule.

 
 Singular:
   https://www.ohloh.net/p/Singular
# of lines of code:  456764
# of comment lines:   73429
 
 Sage:
   https://www.ohloh.net/p/sage
# of lines of code:  474866
# of comment lines:  551813

Literate programming has nothing to do with comments.
They are completely orthogonal. Think of literate programs
as works of literature. You are telling a story (of why
the code exists and what you are trying to solve). You 
need to motivate the characters (so procedures need to be
introduced at the proper time in the explanation, not when
the compiler needs it). You are trying to write a story for
another human being, not code comments for the programmer.
Write down the theory behind the code.

The Hawaii test is a good benchmark. Can you bring a new
person on the project, give them the literate books, send 
them away to an all-expense paid, 2 week vacation to Hawaii,
and when they return they can maintain and modify the 
program as well as the original authors?

I have found 2 literate programs that I consider examples:
Lisp in Small Pieces by Queinnec (ISBN 0-521-56247-3)
Implementing Elliptic Curve Cryptography by Rosing
(ISBN 1-884777-69-4)

I claim that literate programming improves code in 3 ways:
A) the original programmer discovers errors while writing
   up the full explanation for peer review
B) peer reviewers gain a deep understanding of the problem
   and can critique the original motivation for the code
   including how well the implementation covers it.
C) future programmers can correctly modify and maintain
   the code in the spirit it was written.

All of these are just opinions at this point but they can
be tested. I am trying to find a university willing to
run a test of hypothesis B. Students would be given either
a literate program (e.g. Rosing's book) or the original
source code (e.g. Rosing's downloadable source) and asked
questions to test their comprehension, such as given
   #DEFINE NUMBITS 158
what is the significance of 158? Do you know?

Elliptic curve code uses modular polynomial arithmetic 
which Rosing explains but would be really hard to 
reverse engineer from the source code.

 
 Gap wasn't available for comment at the time of publication:
   https://www.ohloh.net/p/gap-system
 
 
 This is also a good occasion to paste sage -coverageall output from
 5.0.prealpha0:
 
 Overall weighted coverage score:  86.3%
 Total number of functions:  28917
 We need 1056 more function to get to 90% coverage.
 We need 2502 more function to get to 95% coverage.
 We need 3658 more function to get to 99% coverage.

Test coverage is an excellent idea. Commenting code is an
excellent idea. Choosing descriptive variable names is an
excellent idea. Code standards are an excellent idea. All
of these have nothing to do with a literate program.

Literate programming can be done in any language. 
I wrote an example using HTML:
http://axiom-developer.org/axiom-website/litprog.html

Are you creating computational mathematics useful for
future generations or will they start yet-another-
from-scratch-computer-algebra-system to replace Sage?

Raise your game. 
Make your code live.
Make

Re: [sage-devel] Re: Mathematica/Magma/Sage dictionaries ?

2011-12-13 Thread daly
On Tue, 2011-12-13 at 18:15 -0600, Jason Grout wrote:
 On 12/13/11 5:51 PM, Nathann Cohen wrote:
  Hello everybody !!!
 
  I have been contacted by an enlightened colleague who planned to teach a
  bit of Sage at the local university, instead of Magma and Mathematica as
  it was formerly done. Now, enthusiasm is a wonderful thing that can
  achieve many things by itself, and for instance to the scary task of
  translating a semester's worth of Magma/Mathematica exercises and
  lecture notes into Sage ones.
 
  But really.. Wouldn't it be much much easier if someone around here
  already knew of an index of equivalents between Mathematica/Sage or
  Magma/Sage ? :-)
 
 Great idea.  Tim Daly has long been asking people around here to 
 contribute to the Rosetta Stone [1].
 
 Jason
 
 
 
 [1] http://axiom-developer.org/axiom-website/rosetta.html or 
 http://www.univ-orleans.fr/EXT/ASTEX/astex/doc/en/rosetta/htmla/roseta.htm 
 -- I'm not sure where the original source is or how to add things to it.
 

wget http://axiom-developer.org/axiom-website/rosetta.tex
wget http://axiom-developer.org/axiom-website/rosettta.pdf

-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Code style guidelines

2011-10-24 Thread daly
diff has options to deal with whitespace.
-b --ignore-space-change
-w --ignore-all-space

Tim Daly

On Tue, 2011-10-25 at 07:35 +0200, Florent Hivert wrote:
 On Mon, Oct 24, 2011 at 11:20:47AM -0700, Keshav Kini wrote:
  Hmm. I have to say I'm surprised that people are advocating for using 
  trailing whitespace at all, as it seemed to me to be quite universally 
  reviled in the programming world. But on some reflection, the only real 
  problem with trailing whitespace - other than that it bloats files and that 
  it, er, grates on certain types of minds :) - is that people remove it 
  from, 
  or, though I imagine this is rare, add it to otherwise untouched lines. I 
  guess if hypothetically we had stuck to a no trailing whitespace policy 
  from day 1 of Sage development, such a policy would have minimized diff 
  cruft. But Sage's codebase is already so big that perhaps the best policy 
  is 
  just don't purposelessly add or remove whitespace to lines that you aren't 
  otherwise editing. As far as that goes, Jason's .emacs snippet seems 
  useful 
  for the developer's guide, indeed.
 
 +1 to this policy ! WE are trying to do that in the sage-combinat project.
 
 Systematically remove all trailing whitespaces creates a lot of conflicts in
 the patch queue so I'm strongly against it.
 
 Cheers,
 
 Florent
 


-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Multiple databases and sage

2011-10-19 Thread daly
On Wed, 2011-10-19 at 10:44 +0200, Paul-Olivier Dehaye wrote:
 Dear all,
 
 I am currently participating in a sage-based project that aims to
 integrate a lot of number theory databases (some of you know it, or
 are even participating!).  Some of the goals of the project are to
 display, search across or perform further computations on archived
 objects that come from very different sources. The variety of sources
 can be due to human factors (more than one person has data, or people
 have overlapping but not identical interest), historical reasons (a
 legacy table has since been expanded but should be kept for
 compatibility reasons), and most importantly mathematical reasons (the
 archived objects can be computed using very different constructions
 that current mathematical results do not know how to unify, but all
 these objects should really be looked at through the same lens
 sometimes).
 
 I expect these to be very common problems when trying to integrate
 mathematical data from various sources into sage, regardless of the
 area of mathematics.
 
 Does this sound familiar to anyone?
 
 Some participants of the sage-combinat project are pushing for the
 concept of Categories ( mathematical categories) as a way to
 exploit object-oriented programming to its fullest and organize code
 in a flexible and efficient way. Categories are then used to
 incorporate purely mathematical information (of the type a Field is a
 Ring), that Python can also understand and use to build a whole class
 hierarchy.

Axiom is based on a Category concept. Categories give a mathematical
structure to the results that make it possible to use the algebra
as a scaffold to organize the software. It has proven to be very
effective.

Can you point me at the sage-combinat project?

Tim Daly


-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Science Code Manifesto

2011-10-16 Thread daly
Hmmm. I did work at CMU last year on a Journal article.
It was based on about 3 years of research work. The article
was completed, submitted for review, and accepted. CMU
required that I sign over the copyright to them. Springer
required that I sign over the copyright to them, despite
an agreement between CMU and Springer. It turned out that
the agreement was between CMU and Springer USA but the
Journal is published by Springer Europe. 

Ultimately the two lawyers could not agree and my Journal
article was withdrawn during production. CMU now holds the
copyright. Three years of work and I have nothing, no rights
and no publication.

As a major advocate of Literate Programming I was hoping to
publish a follow-on paper that included the actual source
code. Why bother?

Tim Daly


On Sun, 2011-10-16 at 12:20 -0700, William Stein wrote:
 
 
 On Sunday, October 16, 2011, Dima Pasechnik dimp...@gmail.com wrote:
  Bill,
  are you sure that you have signed away to your employer rights to
 your ideas ?
 
 Technically Bill only said that Uni's consider employee work
 intellectual property, but he did not say they consider it *their*
 intellectual property...
 
  While some not so great universities are just degree-selling
 businesses, 
  last time I had to obtain a permission from my employer for
 publishing something, was still in Soviet Union!
  So I really don't see how results of work done by a faculty member
 are university property. 
   
 
  --
  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
  URL: http://www.sagemath.org
 
 
 -- 
 William Stein
 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
 URL: http://www.sagemath.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
URL: http://www.sagemath.org


Re: [sage-devel] Science Code Manifesto

2011-10-16 Thread daly
Oh, and as another aside, I left CMU in February (I'm now
unemployed) but the last effort we had was to release our
6 year research project as open source. That effort is tied
up in legal somewhere and has been since January. Since I'm
no longer there I expect the code will never see the light
of day. Which implies that I cannot use my last 6 years of
work. Technically I cannot complain as I knew the rules
while I worked there but it really does seem like a waste
of good research. Nobody will be able to build on the results,
which is a fundamental principle of scientific progress.

Tim Daly

On Sun, 2011-10-16 at 15:42 -0400, daly wrote:
 Hmmm. I did work at CMU last year on a Journal article.
 It was based on about 3 years of research work. The article
 was completed, submitted for review, and accepted. CMU
 required that I sign over the copyright to them. Springer
 required that I sign over the copyright to them, despite
 an agreement between CMU and Springer. It turned out that
 the agreement was between CMU and Springer USA but the
 Journal is published by Springer Europe. 
 
 Ultimately the two lawyers could not agree and my Journal
 article was withdrawn during production. CMU now holds the
 copyright. Three years of work and I have nothing, no rights
 and no publication.
 
 As a major advocate of Literate Programming I was hoping to
 publish a follow-on paper that included the actual source
 code. Why bother?
 
 Tim Daly
 
 
 On Sun, 2011-10-16 at 12:20 -0700, William Stein wrote:
  
  
  On Sunday, October 16, 2011, Dima Pasechnik dimp...@gmail.com wrote:
   Bill,
   are you sure that you have signed away to your employer rights to
  your ideas ?
  
  Technically Bill only said that Uni's consider employee work
  intellectual property, but he did not say they consider it *their*
  intellectual property...
  
   While some not so great universities are just degree-selling
  businesses, 
   last time I had to obtain a permission from my employer for
  publishing something, was still in Soviet Union!
   So I really don't see how results of work done by a faculty member
  are university property. 

  
   --
   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
   URL: http://www.sagemath.org
  
  
  -- 
  William Stein
  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
  URL: http://www.sagemath.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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Upstream projects

2011-09-05 Thread daly
On Mon, 2011-09-05 at 07:32 +0200, Julien Puydt wrote:
 Le 05/09/2011 02:41, leif a écrit :
  One shouldn't upgrade packages just for the sake of higher version
  numbers in Sage though, and there are packages where upgrading is
  indeed non-trivial, because of functional changes in upstream, or a
  lot of changes made by Sage to its current version.
 
 I can't help but notice that last part of the sentence is part of Dave 
 Neary's point.
 
 Snark on #sagemath
 
Tracking upstream changes and feeding back bug reports and fixes 
takes time. Axiom has only one upstream package (GCL) and it is
a major step to upgrade but it is done on a reasonably regular
basis. We are fortunate that Camm tests GCL's changes by, among
other things, compiling Axiom, Maxima, and other large packages.

The other advantage is that Common Lisp is a standard so it is
reasonably clear whether the failure is GCL or Axiom.

Historically Axiom was written in MacLisp, then LispVM, and
then Common Lisp. Since I had expertise in all three of these
languages I did a fair amount of the porting and rewriting to
Common Lisp. I have to say that it was not easy. The key advantage
of Common Lisp is that we could change LispVM functions into
either Common Lisp functions or macros without changing the
code everywhere. If the new function implemented the LispVM or
MacLisp semantics properly everything else just worked.

I see Sage efforts to keep up with OS changes (e.g. Lion) and
package changes (e.g. Maxima) but I am unaware of any work
to keep up with Python.

Python is up to version 3.2.2 which is incompatible with 2.7.
Plus, there is no standard for the language. It is clear that
Sage is losing ground on the upstream development path. What
happens when the python-based spkgs, such as SciPy, convert to 
3.x? The time will come when all published materials about
Python use 3.x syntax and semantics, at which point Sage will
no longer be programmed in Python. It happened to many
languages (e.g. Fortran, C, Lisp, etc.).

I don't believe that Python allows you to redefine standard 
Python functions and it doesn't have a macro facility so neither
path used by Axiom is available for Sage. 

As pointed out in the article, the longer this continues, the
harder, more expensive, and more disruptive the changes will be.

Tim Daly


-- 
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
URL: http://www.sagemath.org


[sage-devel] Upstream projects

2011-09-04 Thread daly
The Cost of Going it Alone by Dave Neary
http://blogs.gnome.org/bolsh/2011/09/01/the-cost-of-going-it-alone/


-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: MATLAB: viable alternative...?

2011-08-19 Thread daly
On Fri, 2011-08-19 at 05:27 -0700, leif wrote:
 ___
 * I vaguely remember to have once seen some [quite old?] list / table
 mapping Mma function names to Sage's, but I'm not aware it is part of
 the Sage distribution or prominently advertised. I may be wrong of
 course. ;-) 

There is http://axiom-developer.org/axiom-website/rosetta.pdf
which does not include Sage, although I'd be happy to replace
it with a newer version that does. I'm not enough of a Sage
person to do it properly.

Tim Daly


-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: MATLAB: viable alternative...?

2011-08-16 Thread daly
MIT's online linear algebra course with Gilbert Strang
mentions rref as one of the very first functions in Matlab.

On Tue, 2011-08-16 at 00:44 -0700, Rob Beezer wrote:
 On Aug 15, 11:38 pm, William Stein wst...@gmail.com wrote:
  It sound like it wouldn't be difficult for you to name one single
  Matlab matrix function that engineers would actually use that
  Numpy/Scipy doesn't have?  I wonder why it's not in numpy yet.
 
 Sorry, I couldn't parse that.  Did you mean would instead of
 wouldn't?  More directly - it appeared to me that the popular
 matrix decompositions in MATLAB were all (or almost all) available to
 be wrapped from SciPy/NumPy as Sage methods for RDF/CDF matrices.
 
  I know one example sort of like this, which is rref, for reduced row
  echelon form.  However, in a numerical setting, my understanding is
  that engineers would never ever use rref directly anyways.
  Nonetheless, Matlab has it and Numpy/Scipy don't, because there is no
  point in having it.
 
 I have to be careful, because I would not claim to be a numerical
 linear algebraist, so I am willing to be corrected - but I think an LU
 decomposition would be the first choice for an alternative to rref.
 It is basically what we used to call Gaussian elimination, rather than
 Gauss-Jordan elimination, but with more care about pivoting in a
 numerical setting.  Enabling LU decomposition for rectangular matrices
 (not just square), which is now possible in NumPy/SciPy, is a patch
 with a positive review (iirc) and I have posted a patch for an exact
 LU decomposition, which is able to run over generic rings twice as
 fast as echelon form (as theory would predict). Needs review.  An LU
 decomposition is the lever for a similar speedup (2x) in solve_left()
 over generic rings.
 
  Incidentally, as I discovered by putting this on a homework assignment
  for my class, it genuinely is really easy to implement rref in Numpy,
  and the result from almost anybody is very impressively fast, even in
  pure Python (Cython barely helps in this case, since Numpy is already
  so optimized).
 
 I would vote for not allowing a naive/classical rref algorithm from
 Sage to be applied to a matrix over RDF/CDF.
 
  Also, with your 75% above, do you mean when working with Sage
  matrices or Numpy arrays?
 
 Consider the primary numerical matrix decompositions - LU, QR, SVD,
 Cholesky, Schur.  Rough recollection - and it depends on patches in-
 progress - these are available in MATLAB, and almost all are also
 available for Sage RDF/CDF matrices (maybe just Cholesky needs
 attention).  Some are available for exact Sage matrices (modulo
 finding exact eigenvalues in some cases).  Along with straight-out
 numerical eigenvalues for Sage RDF/CDF matrices, and exact Jordan
 canonical form and exact rational canonical form (over *any* field),
 I'd posit roughly 75% coverage by Sage in this area, exact and RDF/CDF
 combined.  Maybe higher.
 
 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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Sage Pari

2011-07-27 Thread daly


  Again I have to credit Sebastian Pancratz and Fredrik Johansson here
  for raising the standard in flint. I thought I had been producing
  beautiful code until Sebastian started rewriting some of it for
  me. :-)

I downloaded Flint and looked at the source code and documentation.
First, I applaud you on the PDF. It looks very nice and it includes
quite a bit of information. I especially liked the hyperlinks to
Wolfram's site and the fact that you included a bibliography.
The inline mathematics is very useful (a TeX advantage).

As an experiment I tried to understand Bell Numbers, of which I
know nothing. Since the algorithm for bell_number_vec_recursive
is small I can see what is being computed. However, I also see that
bell_number_vec contains a magic number 7000 as the defining
value to split the computation. One advantage of a literate form
of the documentation would be the obvious need to explain this
number. The pdf simply says that it Automatically switches...
but not when or why.

The hard part of a fully literate document is the need to explain
the special tricks that make an algorithm fast. Mathematically
they might not matter but computational math hinges on the details.
Many an algorithm in Sage has been carefully tuned to get speed
and it is this careful tuning that makes the algorithm worthwhile.
It also makes it obscure. But this tuning includes crucial knowledge
that cannot be reverse-engineered and is only known to the author.
Eventually the author dies, as has happened with several Axiom authors.

If a future maintainer needed to port Flint to run on the ARM
or the Apple5 or the GPU/CPU/APU setup what are the critical things
to optimize? Is 7000 machine independent? Knowing these details is
the difference between a classroom algorithm and a world class one.
If I write Bell Numbers in Axiom, does 7000 matter?




The reason to favor a fully-embedded literate program is that you
can't ignore or hide any implementation detail. The magic number
7000 would cry out for an explanation. Keeping the code in one
file and the documentation in another file makes it trivial to 
skip details. A peer review of a literate program would certainly
notice that this was skipped.

I am tempted to make a literate paper about bell numbers that
is built on your code but I'd obviously make a fool of myself
in front of a crowd of number theorists :-) Never the less,
a small pamphlet on the implementation of Bell Numbers would
make a good starting example to critique. I would be willing
to provide the tools and techniques if you'd be willing to 
provide the explanations. Feel free to decline.

Tim Daly


-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Sage Pari

2011-07-27 Thread daly


 On Jul 27, 11:58 am, John Cremona john.crem...@gmail.com wrote:
  My innocent posting to sage-devel on this subject two days ago seems
  to have done something to increase the number of postings this month,
  even if a lot of the discussion has been much wider than the orginal
  title (Sage  Pari) suggests!

Well, credit is the coin of the realm in open source
so it is important to make sure that those who work get
recognized (paid). This is especially sensitive in an
academic environment. If you spend a year writing software
but don't publish then the tenure committee won't see any
of that work.

I managed to widen (hijack) this thread to the larger
topic of computational math and literate programming.
Apologies for that.

Tim Daly



-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Sage Pari

2011-07-26 Thread daly
 the standards for published mathematical software will help
us all in the long run. We can look forward to a time when we can
read, understand, and cite particular Pari and Sage algorithms which
are their actual implementations in literate form.

Tim Daly
d...@literatesoftware.com
d...@axiom-developer.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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Sage Pari

2011-07-26 Thread daly
 don't
know where to integrate literate tools into the process.

 
 
  Raising the standards for published mathematical software will help
  us all in the long run. We can look forward to a time when we can
  read, understand, and cite particular Pari and Sage algorithms which
  are their actual implementations in literate form.
 
 
 It's not the only important step that needs to be taken though.
 
 My epiphany regarding automated program checking came when I
 serendipitously encountered a fantastic book on Prolog on the exact
 same day that I sat down to implement Damas-Hindley-Milner type
 inference for an interpreter I have been writing. I marvel that a 20
 line implementation of the unification algorithm saves me so much
 hassle. After this little epiphany I have not had any problems seeing
 the future. Type inference and unification have been around for ages,
 but I feel like someone who has been in a time machine and returned
 and who has to sit around and watch the inevitable development of the
 compiler technology that I have already seen. Progress feels like a
 slow motion replay.
Ah, indeed. Another direction is the development of automated proofs.
I don't know about Sage but Axiom has an algebraic scaffold that
looks like it will allow us to attach definitions and theorems
(e.g. around Groups, Rings, Fields, etc) and then prove the 
algorithms that, say Ring, implements. I have had many discussions,
some with the people at UTexas, working on ACL2. There are other
efforts (e.g. COQ) in this same direction. 

The root question is How do we connect mathematical theory to 
computational mathematics in a rigorous, automatable way that
can be published and peer-reviewed?.

The task is too big and the goal is too distant for a single
leap. It would be better if we could begin to have something like
a Sage track (like HICSS tracks), that calls for, reviews, and
accepts literate software. Each example paper could slowly raise
the standards of good practice. Flint might be a good place to 
start.

Perhaps there is an ACM connection to this effort. (I am no 
longer an ACM member though). ACM might help sponsor some of
the presentations. NIST is also a potential partner as these
algorithm papers could become standards. Oak Ridge National
Labs has a numeric library interest and might be convinced to
help fund a literate form of the library.

Sage has a reach and connection with a large number of academic
researchers. It would certainly help a tenure review if the
software algorithms were in literate, peer-reviewed paper form.
This might help get tenure-track people more involved in the
creation of software since it seems that only papers count
in the tenure process. 

In any case, if the papers were literate then it would be clear
who, what, and how to cite prior work. Literate Pari papers
would be an obvious example.

Tim Daly



-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: LaTeX code to Sage expression?

2011-05-14 Thread daly
Since TeX is turing complete and allows macros,
would it be possible to create a set of macros
that are not ambiguous? For instance, an integral
macro that specifies the limits and differential
variable?

\integrate{0}{\infty}{r}{sin(\theta)}

In this case it seems to me that the latex macros
would closely approximate the actual linear input
to the CAS.

Tim Daly


On Sat, 2011-05-14 at 08:25 -0700, rjf wrote:
 Look at
 http://moralfiber.org/eylon/berkeley/cs282/
 to see a paper,
 Parsing Mathematics Typeset in TeX
 that  successfully parsed many many formulas
 from Gradshteyn and Rhyzik, a table of integrals.
 
 The result was Lisp, which presumably could be Maxima.
 If you have a result in Maxima, presumably Sage can make sense of it.
 
 Or the same design can directly produce whatever Sage-speak you had in
 mind.
 


-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: profiling Sage startup

2011-03-01 Thread daly
Sage could follow the same technique used by Gimp.
Gimp loads a huge number of files at startup and can
take over a minute to start on small systems. They
have a startup splash screen that shows the files
which are being loaded. That way the user sees progress
during startup.

-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Support contracts for commercial customers.

2011-02-26 Thread daly
On Sat, 2011-02-26 at 20:09 -0800, Nils Bruin wrote:
 On Feb 25, 10:52 pm, William Stein wst...@gmail.com wrote:
   2) Pay for advertising Sage in maths journals, New Scientist, or if
   deemed appropriate, anywhere where the 4 M's are advertised.
 
  b) Is 2) something that will annoy anybody reading this?  I could see
  somebody being annoyed that valuable Sage money is being spent on
  advertising.   (I personally think advertising is a good idea.)
 
 Do you have good reasons for thinking that? Not that you need them or
 need to share them. I am just wondering.
 I would personally like to see sage develop into a platform that I can
 use for my research needs. When I look at other programs that fit in
 that category (magma, kant/kash, pari, singular, gap, python, gcc), I
 notice that none of those feel the need to advertise. Is there
 something that sage might gain from advertising that those other
 programs wouldn't? Are those other projects missing opportunities?
 

Well, missing opportunities has a lot to do with project goals.

If you are advertising, what is it you are advertising? Are you 
trying to get more developers? Why not use sourceforge, etc to 
post help requests? Are you trying to get more users? Why not use
a direct phone/mail campaign to your likely targets, which for Sage
would be other schools and peers at other schools. A table at the
math conferences is a great idea and you should continue that.

If you are advertising to attract money then what would your ad
copy be about? Money only goes where it can grow. Why would someone
invest in Sage if it is not already a commercial entity? I am a
little unclear about the financial growth potential of any open
source computational mathematics package. What is the business
plan? What is the elevator pitch? What are the 3 year payback
goals? Is it 1) advertise 2)... 3) profit!

If you are advertising to attract attention then Google might not
be the best place. Most universities probably already have MMA and
Maple so professors and students know about them. If they are using
these tools in class they are probably already aware of what is
available. I know that when I taught, say compilers, I reviewed
pretty much every compiler textbook I could find. I doubt that
a professor is going to be swayed by a Google ad. I could be wrong
in an individual instance but less likely to be wrong in the general
case.

Are you advertising to a particular niche market? For instance,
Mathcad is very engineering oriented and has a lot of special
purpose packages such as a way to get GPIB data off your spiffy
HP equipment. Lab guys love it and will pay for this ability.
Sage has no GPIB support.

Some projects, like Axiom, are not missing opportunities since
there is nothing about the project goals that would make a Google
ad relevant. What Sage project goals require ads? Is Sage really
ready to compete head-to-head with MMA and Maple? Would Sage know
what to do with ten thousand end-users (students) demanding support?

Personally I would love to see Sage win big because I fear the
dark ages that will occur when MMA and Maple disappear. You
might not think this could happen but how many companies do you
know that are 50 years old? And what ever happened to Macsyma
(Symbolics died but you can still buy it for DOS). What about
Derive? (TI bought it, rewrote it into C++ but refused to release
the original Lisp code to me). Reduce? (Tony Hearn released the
code as open source but I don't know who is maintaining it).

Axiom was one of the commercial big three with MMA and Maple.
When MMA and Maple (recently bought by a company in Japan) go 
under where will computational mathematics be? Will MMA and Maple
become open source? Who will maintain them? Who but the original
authors could understand their internals? What happens to all
of those thousands of algorithms?

So I hope that you advertise well. I hope you start a company.
I hope you all get rich and famous. But I also think that there
needs to be a bit more thought about exactly what it is you
would advertise and what you are trying to achieve by it.

Tim Daly


-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Support contracts for commercial customers.

2011-02-24 Thread daly

 I'm also curious about honest *opinions* about how people in the Sage
 community would feel about a company making potentially gobs of money
 selling support contracts?   What balance between profit and giving
 back to the community would be appropriate?  What services might be
 offensive, and what would be OK?
 
 For example:
 
   * I could see how some people might be annoyed if there were a Sage
 version of EPD (http://www.enthought.com/products/epd.php) that fully
 supported Windows (say), even though Sage didn't, and cost
 $199/license.  On the other hand, perhaps a $199 Sage-for-Windows
 might be better than no-sage-at-all for Windows for free.

Funding always has the upside and the downside.

One upside is that you could afford to pay someone to actually
do porting and support work. As you know, there are a lot of tasks
that rarely get done because they are just not interesting enough
to do. I spend a week every two months on porting and platform
issues. 

With funds coming in you could set up a limited liability corp
to manage negotiation with schools, etc. 

The downside is that you begin to compete with MMA, Maple, etc.
commercially. Can Sage compete on a level playing field? If I
am going to give my research away should I write it in Sage or
MMA? Which one will give me a larger audience?

There is the question about where the profit would go. If
I do the research and you make the money it seems a little out
of balance. 

There might be limitations on free. For instance, a 
Windows port might use proprietary software to make Sage run
well on Windows. There are a few people in Sage who are quite
passionate about GPL-ish issues and this might lead to a fork.

Redhat seems to have walked the thin line but they always
styled themselves as a service company. They did a lot to 
support the community. Eventually they ended up with a
deliberate split of redhat vs fedora. Would you end up with
a Sage vs Wage split?

 
   * I'm curious if something like sagenb.org, but with Google ads,
 would be offensive.   I could see somebody starting a small business
 that is just public notebook servers that also have ads.
 
 I haven't personally made up my mind about any of this.
 
  -- 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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Support contracts for commercial customers.

2011-02-24 Thread daly
On Thu, 2011-02-24 at 11:18 -0800, Tom Boothby wrote:
  I'm also curious about honest *opinions* about how people in the Sage
  community would feel about a company making potentially gobs of money
  selling support contracts?   What balance between profit and giving
  back to the community would be appropriate?  What services might be
  offensive, and what would be OK?
 
 For me, it all depends on what the company does with said gobs of
 money, and who is at the helm.  If some enterprising stranger starts a
 company providing support contracts, that's their own business -- we
 develop free software, and people are allowed to use it.  But somehow,
 if you (William Stein) were to start the company and profit from it,
 the situation gets hairy.

Keith Geddes (Maple's version of William) had to choose between
being part of Maple management and being a professor. He decided
to be a professor. I've talked to him about it and it was not a
simple decision on his part.

You can be rich or you can be famous. Which one would you choose? :-)

 
 For example, if you were to start a company which was primarily
 devoted to making you lots of money, that would kinda suck.  If, on
 the other hand, you devoted the majority of the profit to a good
 cause, I'd be all for it.  My definition of good cause here is
 pretty loose, too: if you used the profit to (say) buy and operate a
 server farm which replaced the public notebook, that'd be *awesome* in
 my book.  If the money went to an institute which pays mathematicians
 to do research which is tangentially related to the interests of Sage
 users, great.

If Sage could follow the Redhat model I think this would be a win
for the whole community. It would be great to see ANY kind of a
funding stream for computational mathematics. 

Funding grants for general research questions (e.g. what is a
general way to handle simplification?) would be great.
 
 
 If the money went to some Sage developers and not others, then I
 foresee some big problems, though.  I don't know how this would be
 handled, and I assume that some people would get pissed off and leave
 the project over it.  On the other hand, it would be nice to be able
 to hire talented programmers to do dirty work that current Sage
 developers don't want to do.
 
  For example:
 
   * I could see how some people might be annoyed if there were a Sage
  version of EPD (http://www.enthought.com/products/epd.php) that fully
  supported Windows (say), even though Sage didn't, and cost
  $199/license.  On the other hand, perhaps a $199 Sage-for-Windows
  might be better than no-sage-at-all for Windows for free.
 
 Is this option GPL-compatible?
 
   * I'm curious if something like sagenb.org, but with Google ads,
  would be offensive.   I could see somebody starting a small business
  that is just public notebook servers that also have ads.
 
 Knock yourself out.  If it was made obvious that sagenb.org requires
 huge amounts of computing power and the ads enabled us to pay for CPU
 time on a distributed solution, I'm all for it.  On the other hand, if
 the ads only make a few bucks a month, it isn't worth it.  Free
 services on the net have ads or are donation-driven -- people are used
 to that.  I'm thoroughly opposed to obnoxious flash ads, pop-ups,
 etc., but text google ads are fine by me.  It's going to be HILARIOUS
 when we start seeing Mathematica ads on sagenb.org, though.
 


-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Rapid growth in Python popularity

2011-02-18 Thread daly
 The python community is huge, skills are available,
 and often the needs are not in the core science algorithm
 which is well looked after, but in the glue and interface,
 which requires a less in-depth understanding of the science
 than the core algorithm. It allows non-niche programmers to assist
 more easily than... FORTRAN. 

I do think Sage has proven the conjecture that Python is an excellent
choice for a glue language (although a lot of the actual glue seems
to be in Cython?). Since Sage is growing by accretion, William made an
excellent choice.

I don't think Sage has proven the conjecture that Python is good
for computational mathematics. My experience with computational
mathematicians is that they will program in obscure (APL) or
dead (Fortran) languages. Every one I have met over the years
is perfectly capable of writing their algorithms in anything.

There are two ways to look at any computational mathematics
problem. Either you want something very close to the math,
(e.g. Spad) for conceptual efficiency or very close to the
machine (e.g. C) for execution efficiency. Python sits
somewhere between these two extremes, making it a non-optimal
choice for either.

If I were working with Sage I'd write my algorithm in some
other language and glue it on with python.

As for the conjecture that Python is wildly popular and
therefore the perfect choice for computational mathematics
I can only point to history. Pascal was everywhere, including
in the universities. Smalltalk took the world by storm.
PL/I was universal. Ada was the ultimate language. Most
people probably don't even list these languages on their
resume anymore. Wait 10 years. Nobody will admit to knowing
Python.

Tim Daly



-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Rapid growth in Python popularity

2011-02-18 Thread daly

 
  As for the conjecture that Python is wildly popular and
  therefore the perfect choice for computational mathematics
  I can only point to history. Pascal was everywhere, including
  in the universities. Smalltalk took the world by storm.
  PL/I was universal. Ada was the ultimate language. Most
  people probably don't even list these languages on their
  resume anymore. Wait 10 years. Nobody will admit to knowing
  Python.
 
 Your summarization of history indicates that no language will survive
 10 years, so we should pick a language not on its long-term merits but
 based on getting something out of it before it fades.
 

Hasty generalization. Fortran, Lisp and C are still active and they
are 50 years old so some languages are still resume material.

Pascal, in its day, was HOT. Universities switched to Pascal for
teaching, books were using it as pseudocode, and great debates
raged about its bike-shed issues (e.g. a lack of strings).
It was the easiest language to write. It was easy to compile.
It was required as a line-item on your resume.
It cured cancer and was the key to worldwide understanding.
Famous people in history were renamed after the language!
Surely everyone you know codes in Pascal, right?

Is Python a Fortran or a Pascal? 

Well, lets look for some data about how others choose.
I have touched nearly every computational math program
on the planet over the years.

On my Ubuntu linux system almost every python program I
didn't write is some sort of a system script so it seems
to have moved into Perl's primary domain. From that data
point I'd say that Python is a great language to know if
you plan to be a sysadmin. (I excluded Sage, of course).
Sympy and numpy are exceptions. But even Java people use
python for scripting and test (e.g. inside ant).

On my Ubuntu linux system almost every computational
math program I didn't write is either Fortran, Lisp, C,
C++, assembler or some specialized math language like
Spad, MMA, Maple, etc. From that data point I'd say that 
Python is not a computational mathematics language of note.

From the data it seems that Python is the new Perl,
a new, improved system scripting language; a glue
language for the new millenium. That might explain
why it appears to be so popular and why Perl is sinking
in the TIOBE ratings. 

Would you do computational math in Perl?

Tim Daly




-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Rapid growth in Python popularity

2011-02-17 Thread daly
An interesting article about computational science programming:
http://www.nature.com/news/2010/101013/full/467775a.html?ref=nf

Tim Daly


-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: gcd lcm and numberfields

2011-02-11 Thread daly
On Fri, 2011-02-11 at 09:20 +, David Kirkby wrote:
 On 10 February 2011 14:51, rjf fate...@gmail.com wrote:
  in maxima, gcd(1/4,1/6)  is 1/12,  lcm is 1/2
 
  Since maxima immediately simplifies 2/1  to 2, there is no
  distinction between gcd(2/1, )   and gcd(2, ...)
 
 FWIW, I just noticed that Mathematica treats 2/1 as an integer and not
 as a rational.
 
 In[1]:= Head[2]
 
 Out[1]= Integer
 
 In[2]:= Head[1/3]
 
 Out[2]= Rational
 
 In[3]:= Head[2/1]
 
 Out[3]= Integer
 
What does MMA do with gcd(2/1,4)


-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: sage thoughts

2011-02-11 Thread daly
On Fri, 2011-02-11 at 01:49 -0800, Simon King wrote:
 Hi,
 
 On 11 Feb., 09:56, Simon King simon.k...@uni-jena.de wrote:
  Well, I had the impression that a couple of people are in favour of
  the following:
   gcd(a/b,c/d) := gcd(a,c)/lcm(b,d)
   lcm(a/b,c/d) := lcm(a,c)/gcd(b,d)
 
 It just occurs to me that I am incredibly stupid.
 
 The definition above wouldn't work at all, it isn't even well-defined.
 Just replace gcd(1/4,1/6) by gcd(3/12,9/54). You obtain gcd(1,1)/
 lcm(4,6) = 1/12,  but gcd(3,9)/lcm(12,54) = 1/36.
 
 Does anyone have a better idea? Would it be a correct definition if
 one insisted on reduced fractions?
 
 Cheers,
 Simon
 
That's why I was asking for an algorithm for gcd and lcm
in the subdomain. I'm not sure what answer is expected.
The unit (1) is correct but not by your definition, and
apparently not helpful for the original poster.

Tim Daly


-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: sage thoughts

2011-02-10 Thread daly
On Thu, 2011-02-10 at 22:57 -0800, Simon King wrote:
 Hi Bruno!
 
 On 11 Feb., 01:37, Bruno Le Floch blfla...@gmail.com wrote:
   You could have both consistencies. That depends on how you define gcd
   and lcm:
 
   - Quotient fields as described by Bruno.
   - Fields:  zero if both elements are zero. A non-zero element
   otherwise (most fields would choose 1 here).
   - PID: a generator of the corresponding ideal.
 
  I don't see how this brings in both consistencies. Algebraic
  consistency requires gcd and lcm on QQ to have different outputs
  depending on whether QQ is seen a Field, a PID, a Quotient Field... Is
  there a clear way for the user to indicate which QQ he wants?
 
 I am sorry for the FUD that I spread in my earlier posts.
 
 Meanwhile people convinced me that it is indeed possible to have both
 consistencies. The point is: In a PID, the lcm of a and b is only
 defined up to a unit - it is only required that lcm(a,b) generates the
 intersection of the ideals generated by a and b. My mistake was: 1 is
 certainly the canonical choice of a generator of the ideal a\cap
 b (a,b non-zero); but that does not mean that it is the best return
 value of lcm(a,b)!
 
 So, if lcm(a,b) for a,b non-zero returns *any* non-zero element, then
 consistency from the category point of view is granted -
 lcm(1/2,1/4) = 42 is not wrong in QQ.
 
 But that freedom means: We can *in addition* achieve consistency with
 respect to sub-structures, namely by seeing QQ as a quotient field.
 
 Cheers,
 Simon
 
Can you suggest an algorithm to implement this?
Is there an agreed-upon answer (i.e., not 42?)

Tim Daly


-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: sage thoughts

2011-02-09 Thread daly
On Wed, 2011-02-09 at 22:18 -0800, rjf wrote:
 You say,
  gcd(2/1,4) returns 1 for simplicity (!), because 2/1 is a rational.
  This is shockingly silly.
 
 I don't know exactly how this came up, but if 2/1 is in a different
 domain (rational)
 from 2, (integer),  then gcd should probably be 1,  since any non-
 zero
 rational number divides any other, and one commonly uses the positive
 unit 1 for
 such a case. You could argue that since you can coerce 2/1, you
 should.
 
 That's sometimes OK, but not always.
 
 Really, the issue is much broader. for example, do you also want to
 treat the complex number
 1+0*i the same as 1?   do you want to treat the floating point number
 1.0 the same as 1?
 
 What about 1X1 matrices?
 
 Is 1^0  the same as 1^0.0  or 1.0^0  or 1.0^0.0?  Do you perhaps wish
 to consider/dismiss
 the existence of number systems with signed zeros (IEEE floating-point
 standard) on the
 grounds that -0 = +0,  [true, for numerical comparison] and therefore
 there should be
 only a single zero?
 
 While I don't know the exact formulation of this GCD problem, the
 issue of
 implicit coercion is one of the troubling sore spots in a system
 design, and should not
  be decided by counting up casual +1 votes.
 
 I think the Axiom people might have thought more about it than others.
 

It is a question of domains. In Axiom you can specify the domains.

2/1 is a Fraction(Integer) aka rational
4 is an Integer
(2/1)::Integer = 2 where 2 is an Integer.
4::Fraction(Integer) is a Fraction(Integer) 

So there are several cases:
gcd((2/1),4::Fraction(Integer)) = 1 of type Fraction(Integer)
gcd((2/1)::Integer,4))  = 2 of type PositiveInteger
gcd(2/1,4)  = 1 of type Fraction(Integer)
gcd(2,4)= 2 of type PositiveInteger
gcd(2,4::Fraction(Integer)) = 1 of type Fraction(Integer)

Tim Daly



-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: FAQ suggestion: I'm a programmer, how can I contribute to Sage?

2011-02-02 Thread daly
On Wed, 2011-02-02 at 10:43 -0600, Jason Grout wrote:
 On 2/2/11 10:33 AM, rjf wrote:
  1. What happens if you don't have a plan?
  
   2. Who makes a plan?
  
 
 You have long experience with other open-source projects.  Have they had 
 plans?  (I'm really genuinely curious).  Who made it?  How 
 comprehensive/detailed was it?  Was the plan a success (i.e., was it 
 worth making?)  Was the plan followed?  How did you give incentive to 
 follow the plan?

Axiom has a set of goals, made by me, such as 
http://axiom-developer.org/axiom-website/currentstate.html

This gives a place to capture ideas and long term plans.

A plan might imply a schedule and, as far as I'm aware,
nobody knows how to schedule software development. This
is especially true of free software.

Is it a success? Well, a lot of the tasks have been
accomplished, some have been abandoned, and some will
take years to finish (e.g. making Axiom fully literate).

How did I give incentive to follow the plan?
Ideas that were discussed and agreed upon were added
to the list of goals. Some of them have been completed
(e.g. the boot language is gone), some of them have died
(e.g. the CCL port is dead), and some of them caused
much controversy (e.g. competing with MMA, autoconf,
boot language) and were decided by me. Those who
disagreed forked. 

A project cannot be all things to all people and
someone has to decide what the long term goals are.
But I don't think that a plan is useful except 
maybe in the short term among a group of developers.
Open source does not really attract groups in my
experience. It is usually a set of single-person
efforts.

Tim Daly




-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: FAQ suggestion: I'm a programmer, how can I contribute to Sage?

2011-02-01 Thread daly
On Tue, 2011-02-01 at 08:40 -0800, William Stein wrote:
 On Tue, Feb 1, 2011 at 8:32 AM, William Stein wst...@gmail.com wrote:
  On Tue, Feb 1, 2011 at 6:21 AM, Dr. David Kirkby
   * No documented plan
   * No real documented estimates of time scales
   * No status reports for the project as a whole.
 
  If you think a plan as you describe it for overall Sage development is
  so important, why don't you make one?
 
   -- William
 
 How about this plan?
 
 1. Make a plan.
 2. ???
 3. Profit!
 
  -- William
 

There is a patent on that business plan.
The Supreme Court just ruled that it is valid.
I'm sure you'll be hearing from MicroGooglzon shortly.
Oh, and step 2 is considered a trade secret, which you
just revealed, so you've REALLY stepped in it now :-)

Tim Daly


-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: FAQ suggestion: I'm a programmer, how can I contribute to Sage?

2011-01-30 Thread daly

 
 3) I think the issue of crackpots and bad code dragging things down is
 not much of  a problem. The reason is that it takes quite a bit of
 perseverance to get code into Sage.  My experience with my Jmol
 contributions is an example.  I would not claim to be the best coder,
 but think my Jmol contributions addressed some issues people had.
 And certainly the code is not yet ideal, but it does do most of what I
 understood people to want.  Because of the load on people doing
 testing, it has taken months to get much feedback on it.  This means
 anybody submitting code has to be willing to stick with it and prod it
 along over the long term.  People who are not serious won't do this.
 My example may be a little slower than many people's because I also
 have very little time to contribute to this, but I still think you are
 unlikely to get really bad code included using the present model.

To quote the above This means anybody submitting code has to be 
willing to stick with it and prod it over the long term.

The real problem with Sage's development model will not show up
for a few years. At the moment most of the code being contributed
is supported by the original authors. The algorithms are complex
and some implementations are only competitive when optimized into
Cython, despite the Sage is Python mantra.

The real problem will arise when these authors leave the project.
Code rots. People make simple changes. Linux changes libraries.
Who will be able to debug research-level elliptic curve code
when some minor, unrelated change breaks it? Who will even know
that it is broken? Is it broken now?

And since the Sage code base is owned by other people with other
goals, that is, all of the spkg files from upstream projects,
the potential for code rot is much larger and the debugging
problem is much harder. Is the elliptic curve code failure due
to Sage-owned python changes or spkg changes? What happens when
python itself changes and upstream packages make the move to
python 3.0?

The problem isn't really bad code. The problem is code rot.
What does a programmer need to know to maintain the system?
How can a new programmer join the project and contribute?
If it is not easy now it won't be possible later.

How do we architect systems to survive the loss of the authors?
How do we architect systems to survive the changing platforms?
Will Sage live?

Tim Daly





-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: FAQ suggestion: I'm a programmer, how can I contribute to Sage?

2011-01-30 Thread daly
On Sun, 2011-01-30 at 13:52 -0800, William Stein wrote:
 On Sun, Jan 30, 2011 at 9:23 AM, daly d...@axiom-developer.org wrote:
 
 
  3) I think the issue of crackpots and bad code dragging things down is
  not much of  a problem. The reason is that it takes quite a bit of
  perseverance to get code into Sage.  My experience with my Jmol
  contributions is an example.  I would not claim to be the best coder,
  but think my Jmol contributions addressed some issues people had.
  And certainly the code is not yet ideal, but it does do most of what I
  understood people to want.  Because of the load on people doing
  testing, it has taken months to get much feedback on it.  This means
  anybody submitting code has to be willing to stick with it and prod it
  along over the long term.  People who are not serious won't do this.
  My example may be a little slower than many people's because I also
  have very little time to contribute to this, but I still think you are
  unlikely to get really bad code included using the present model.
 
  To quote the above This means anybody submitting code has to be
  willing to stick with it and prod it over the long term.
 
  The real problem with Sage's development model will not show up
  for a few years.
 
 How long do you mean by a few years?
The major packages, Maxima, Reduce, Axiom, Mathematica, Maple,
and others of that ilk are 30+ years old. So I would define
a few years as the time it took the project to move from 
the primary authors to a second generation support role.

How long will this take for Sage? Well, as I recall you have
said that you plan to move on to doing number theory work
rather than system development. Indeed, I suspect that the
pSage effort is a first move in that direction.

However, a good computational mathematics platform is a 
forever thing in the sense that the results it gets ought
to be forever valid. So given the difference between the
startup timeframe and the lifetime timeframe of Sage there 
is a question of how to survive that transition.

 
   At the moment most of the code being contributed
  is supported by the original authors.
 
 I don't know what you're basing this vague claim on...
 
   The algorithms are complex
  and some implementations are only competitive when optimized into
  Cython, despite the Sage is Python mantra.
 
 There is no Sage is Python mantra.  Sage is a mathematical
 software system, some parts of which are written using Python, and the
 interpreted user language of Sage is indeed Python.
Umm...ok. It has been my impression that Sage is Python has been
one of the major bullet points of the project. I remember a discussion
about rewriting things like integration into python. But my memory is
not what it used to be so perhaps I'm mistaken. 

 
  The real problem will arise when these authors leave the project.
  Code rots. People make simple changes. Linux changes libraries.
  Who will be able to debug research-level elliptic curve code
  when some minor, unrelated change breaks it?
 
 I can easily think of at least a dozen people immediately.  But given
 that you're worried about a few years, and you didn't define what
 this phrase means, it's perhaps not possible to answer your question.
There is a distinction between those who can (e.g. Victor Miller) 
and those who will, especially if the bug is upstream. Tracing a
bug through the inheritance hierarchy, into Cython, and then into
an upstream linked library is not a trivial exercise.

 
   Who will even know that it is broken?  Is it broken now?
 
 Yes, it is broken.  It's computer software, after all.
 
  And since the Sage code base is owned by other people with other
  goals, that is, all of the spkg files from upstream projects,
  the potential for code rot is much larger and the debugging
  problem is much harder.
 
 And for exactly these reasons there are far more people involved in
 fixing bugs in various parts of Sage.  If you total all the people who
 have worked on code that is part of Sage during the last year, you
 would likely easily get over 1000 programmers.   I bet you can't say
 that about Axiom (and perhaps not about Mathematica, Matlab or Maple,
 either.)   Also, the modularity of Sage makes the problem easier in
 some ways.
 
  Is the elliptic curve code failure due
  to Sage-owned python changes or spkg changes?
 
 Sometimes one, sometimes the other, sometimes both.
 
  What happens when
  python itself changes and upstream packages make the move to
  python 3.0?
 
 There are no Python packages at all in Sage that involve elliptic curves.
I agree that you win the pedantic point about elliptic curves in python.

Pick a python-implemented algorithm of high complexity and we can
reconsider the point, possibly algorithms with subfield structures
and uniqueness of finite fields? Surely there must be some high
complexity algorithm in python that depends on upstream libraries.
Choose one.

 
 But incidentally, when the Python dependencies

Re: [sage-devel] Re: Free advertising on Stack Overflow

2011-01-23 Thread Tim Daly

 Advertising images target the emotions, not the intellect.
What images bring strong emotional responses to mathematicians?
Are Mandelbrot sets the leading edge of cool?
For the Sage crowd wouldn't an elliptic curve be better?

Tim Daly

On 1/23/2011 7:56 AM, Martin Albrecht wrote:

On Sunday 23 January 2011, you wrote:

Here is a basic design:

http://tinyurl.com/48xqfm5

Thoughts?

Hi, I like the general idea but would suggest a few optimisations design wise.

- I think the font isn't optimal. A sans serif font is a good choice I think
but I would play around with some other fonts (from that family) to get an
idea how they look.

- I'd drop the gradients around the edges or the darker stuff in the edges.
The gradients remind me of website 4-5 years ago whereas the modern style
seems to be flat, like on sagemath. Almost any website logo these days is flat
with clear contrasts.

- I think some spaces between text and images is too small, giving it a slight
uneasy feel.

Feel free to ignore these comments, just my five cents.

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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Why Sage? Website Section

2010-11-17 Thread Tim Daly

 I don't really have anything more worth saying on this subject.

Tim Daly

--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Why Sage? Website Section

2010-11-15 Thread Tim Daly



On 11/15/2010 8:54 PM, Robert Bradshaw wrote:

On Sun, Nov 14, 2010 at 11:45 AM, Dr. David Kirkby
david.kir...@onetel.net  wrote:

On 11/14/10 07:00 PM, Tim Daly wrote:

I find it amusing that mathematicians are being told that
a math-specific language is a liability. Mathematics is,
after all, a specialized language that took me years to
learn.

Creating, learning, and maintaining a math-specific language is not
free, and perhaps one of the few strands of consensus in this thread
is that it's very difficult to do right. The marginal advantages over
using a (suitable) general purpose language is, IMHO, not worth the
cost. Using a general purpose language has several advantages, most of
which have been discussed to death already.

Actually, I do not believe that the current way we do mathematics
by computers is correct but that discussion takes us WAY off thread
and this isn't the forum for that anyway.


Was the adoption of the special(er) purpose Spad language helpful in
attracting users and/or developers for Axiom?

No, I'm sure that it did not attract more users. What it did do was
make the language much closer to the mathematics. Spad is a general
purpose programming language, uses indentation like Python, and is quite
similar to python syntax and semantics. In fact, it allows things
quite beyond python, like nested list comprehensions, full multiline
closures, general argument destructuring, etc. If you are a python
programmer you would find Spad to be python 4.0. It also compiles
to exceptionally efficient code without needing Cython.

I do think that python is not actually the language of Sage.
I think the Sage language is unnamed at the moment. I've been a paid
professional python programmer and I still struggle with Sage (which
I build occasionlly to cross-check Axiom). The Sage language has a
lot of things like QQ which is nowhere in the python language. Saying
that Sage is written in python seems like saying that mathematics is
written in english (there I go with those analogies again...). Most
english speakers cannot read or write mathematics and most python
programmers cannot read or write sage programs.

Maple is a very C-like language, which has a much larger audience
than python. I am not sure that this attracted more users to Maple.

I am not sure that attracting users to CAS systems has anything to
do with the language. Generally you don't reach the language issue
until you've used a CAS as a fancy calculator for a while.

In any case, my original point was that in becoming a computational
mathematician the CAS language is the least of your problems.

Tim Daly

--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Why Sage? Website Section

2010-11-14 Thread Tim Daly

 I find it amusing that mathematicians are being told that
a math-specific language is a liability. Mathematics is,
after all, a specialized language that took me years to
learn.

In any problem you wish to solve with a program there is always
an impedance mismatch (like hooking a soda straw to a firehose).

You can choose a language close to the machine (e.g assembler)
and port your problem across the chasm. Or you can choose a
language close to the problem (e.g. APL) and let the machine do
the port across the chasm. Python is somewhere in the middle
where mathematics is concerned.

Python is a poor match for the machine (interpreted) and it is a
poor match for the mathematics (needing lots of supporting
superstructure the user needs to learn).

As a pragmatic choice for design-by-accretion it is excellent.
But as a selling point for developing mathematics I'm somewhat
more skeptical.

What is the ultimate purpose of Sage (beyond competition)?
Is it a platform for doing computational mathematics?
If so, why wouldn't I want a language close to my problem,
that is, a language that directly supports well-founded
mathematics? And what can that possibly have to do with Python?

Python is the glue. Who chooses a workbench based on the glue?

Tim Daly


On 11/13/2010 10:13 AM, rjf wrote:


On Nov 13, 6:32 am, Johan S. R. Nielsenj.s.r.niel...@mat.dtu.dk
wrote:


two info boxes on this suggested Why Sage-page.

I don't think that Python is the perfect language to write mathematics
software with; I would definitely vote on a much more functional
language here, e.g. OCaml or maybe even Haskell. However, this would
cut out so many potential developers,

... yada yada...

excessive boosterism.

Consider that symbolic software systems like Maxima/Macsyma, Reduce,
Axiom, Jacal ...
were written in Lisp,

and that Mathematica and Maple were written in C dialects...

and even YOU would prefer a different, more functional language.

And then you say Python is still better.

Certainly not for writing math software.Maybe for writing web
applications?

Because it has a coherent syntax   Compared to Lisp or Haskell or
OCaml?
Because people who know little mathematics and little about
programming
can write/alter/debug applications for SAGE???  About which they
presumably know
nothing?   And this is because Python is such a winner?

And of course so much of SAGE is not even in Python, but C, Fortran, C+
+, Lisp, whatever,
that even that is nonsense.

excessive boosterism.

At best, you might say, some features of Sage can be augmented by
writing in Python, and
the user interface looks like Python  (actually it is not, but has to
be pre-processed).

RJF



--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Why Sage? Website Section

2010-11-14 Thread Tim Daly

 I am not the best person to ask as I have a vested interest.

I find that mathematical notation is strongly context
sensitive which gets translated into types when done
as computational mathematics. Thus, I believe that a
mathematical language needs to be strongly typed.
Python is not strongly typed.

Axiom has two levels of type-strength. The interpreter
does its best to guess types so the user can give short
and reasonable inputs. The compiler requires extremely
strong typing to ensure that the algorithms match the
intentions. The fact that the compiler does not make
guesses makes it more challenging to develop library code
but increases the chance that the algorithm is correct.
Python does not compile.

In addition, I believe that a computational mathematics
language has to have a strong connection to the underlying
mathematics. In Axiom's case, abstract algebra provides the
mathematical framework for providing categories around which
the algorithms are structured. Sage does not seem to have a
strong scaffold for adding new packages. It appears to be
growing by accretion.

There are two extensions I would like to have which is
the use of unicode and the use of two dimensional input.
Sage/Python has a chance for a big win here.

I think that unicode input which allows greek and other
symbols would make the input closer to the original mathematics
notation. Unfortunately, my thesis work showed me that
mathematical notation is highly ambiguous. In fact, I have
come to the conclusion that the equations in a book are
pretty much content free. The real mathematics is actually
contained in the surrounding text. To see this effect take
your favorite textbook, remove everything but the equations
and you'll find that you have lost the meaning of the symbols.
Without context, E=MC^2 is a meaningless jumble of symbols.

I think that two dimensional input is also a huge win.
However, I worked on two dimensional input at IBM Research.
I know of several attempts to do the same thing. The most
recent attempt that I saw was at the University of Waterloo.
I do not know what became of this effort but I know that
two dimensional input is hard and very ambiguous.

In any case, computational mathematics is more about the
algorithms than about the notation. A strong mathematical
framework and strong typing are more important than I/O.

By the way, the Axiom Spad language is very much like Python.
It uses indentation to group code. It has list comprehensions.
It has many more data structures than Python. It dispatches
not only on the types of the arguments but also on the type
of the result (something few languages allow even today).

Spad can be either interpreted or compiled. It can communicate
with lisp (the implementation language), C (the whole graphics
subsystem is written in C), javascript (the browser frontend
is AJAX/Javascript/HTML), Fortran (the commercial version
called the NAG fortran library routines), etc. The claim that
Python is an exceptional language for computation mathematics
or is exceptional as a glue language completely ignores
history which tends to make us old people cranky.

I think the Sage language designers could steal a few useful
ideas from the Spad language.

I also find the Python/Lisp debate useless. In Axiom, Lisp is
the implementation language but you can use Axiom for years and
not know that because Spad is the computational algorithm language.

In Sage there is confusion about the implementation language of
Python and the computational mathematics language built in Python
which appears not to have a name.

Tim Daly




On 11/14/2010 2:45 PM, Dr. David Kirkby wrote:

On 11/14/10 07:00 PM, Tim Daly wrote:

I find it amusing that mathematicians are being told that
a math-specific language is a liability. Mathematics is,
after all, a specialized language that took me years to
learn.


I asked RJF what languge he thought the interface should be. As 10 
options I consider might be viable choises where


 1) Create an entirely new language.
 2) Python
 3) Maxima
 4) A Mathematica like interface
 5) A MATLAB like interface
 6) A Maple-like interface
 7) A Magma-like interface
 8) Lisp
 9) Q - see 
http://en.wikipedia.org/wiki/Q_%28equational_programming_language%29

 10) Pure http://code.google.com/p/pure-lang/ is another possibility,
but that did not exist until 2008, but is based on  Q, which existed
prior to Sage

He failed to response. (He would rather tell me on the Maxima list 
that I can create an infinite set of integers to do some testing.) But 
that is to be expected from Richard - a signal to noise ratio of about 
-30 dB.


But what do you think is the ideal language for a user interface? 
There have been endless attempts at cleating new languages (#1 above). 
I've even done it myself, to the extent of writing a couple of hundred 
lines of code for lex and yacc. But it's a very difficult problem to 
get right, and quite honestly requires a set of sills I don't think a 
single Sage

Re: [sage-devel] Re: Why Sage? Website Section

2010-11-14 Thread Tim Daly



On 11/14/2010 10:37 PM, William Stein wrote:

On Sun, Nov 14, 2010 at 6:48 PM, Eviatareviatarb...@gmail.com  wrote:

I thought Python was strongly typed. Definition from Wikipedia:

Most generally, strong typing implies that the programming language
places severe restrictions on the intermixing that is permitted to
occur, preventing the compiling or running of source code which uses
data in what is considered to be an invalid way. For instance, an
integer division operation may not be used upon strings; a procedure
which operates upon linked lists may not be used upon numbers.
However, the nature and strength of these restrictions is highly
variable.

What do you mean by saying it isn't?

FYI, I've learned from experience that even using the phrases
strongly typed and weakly typed is a bad idea.
The problem is that there aren't any good accepted definitions of
them, and it is easy to find reputable sources that flatly disagree
with the definition at Wikipedia, unfortunately.

The original poster probably meant that Python is not statically
typed.   (Another can of worms, but less of a problem.)

  - William

I agree with William that the strongly typed question is a
(well, I can't bring myself to use the can of worms analogy
given my prior analogy chastizing :-) )

To illustrate an example, it is possible to define:

  integer foo(integer x, integer y) {}
  matrix  foo(integer x, integer y) {}

and then write:

  integer a := foo(3,4)
  matrix  b := foo(3,4)

The question of which foo to call requires function dispatching
on the return type of the function. Few existing languages do this.

One place where this is useful is the construction of canonical forms.
The question of which result is simplest depends on the result you
expect. Consider that

1 11
- x + --
7 13

is a polynomial with fractional coefficients and cannot be reduced. But

  13x + 77
  
 91

is a fraction of two polynomials with integer coefficients. They also
happen to represent the same value. Simplification of the value depends
on whether the desired result is a
  Polynomial(Fraction(Integer))
or a
  Fraction(Polynomial(Integer))

By specifying the target type you can define the simple form.

Tim Daly


--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: ECL / Maxima / Fedora 14 issues.

2010-10-30 Thread Tim Daly

 I experimented with using Amazon's cloud for (Axiom) builds.
It is trivially easy to set up custom images that can be
used for builds. It is also very cheap for an hour of CPU.
So consider setting up a cloud buildbot.

Tim Daly

On 10/30/2010 1:30 PM, David Kirkby wrote:

On 30 October 2010 07:17, Mike Wittmsg...@gmail.com  wrote:

On Oct 29, 6:48 pm, Mike Wittmsg...@gmail.com  wrote:

I don't suppose there's a way I can initiate the buildbot
from my end and have the results go to the right place?

Once I get time to install Fedora 14, I imagine I could at least
make that system available. I suppose that I should try to
understand how the buildbot scheme works. Is there one place
you can point me to that describes it pretty well?  If so, I
could probably find an hour or two Saturday or Sunday to see
if I can understand its workings and then give you a
more coherent answer.

OK, well I did find the documentation on buildbot.net, and if
I'm understanding correctly from my brief scan of some of
the manual it appears that the communication is initiated
from the build slaves. So, I think that means that my
machines could be used. So I have two questions:

(1) Do the machines have to be available all the time, or
can they just be available some of the time.

(2) Would someone be willing set this up for me (or at least
provide an example configuration that works for sage
builds on some linux type box) or will I have
to *actually* study the buildbot manual until I can figure out
how to do that myself.

-Mike

It's not practical unless the machine runs 24 hours per day, 7 days
per week. The release manager can currently click a button on a GUI
and start the build on all the slaves when he wants to. That's just
not going to be practical with your setup.

There is a plan to use Virtual machines on Boxen as build slaves soon.
Perhaps you could manage one of those running Fedora 14. That machine
would then stay on 24/7.

Dave



--
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
URL: http://www.sagemath.org


[sage-devel] Python 2.7 vs 3.2

2010-10-29 Thread Tim Daly

 There was an interesting comment here about the question
of Python 2.8 and the smooth upgrade path. Apparently
the only Pythonic path is a 3.2 version.

http://sayspy.blogspot.com/2010/10/viewing-python-32-as-successor-to.html

--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Supported platforms - once again

2010-10-27 Thread Tim Daly

 I would expect significant pushback from the Gentoo people
on the issue of including other projects inside Sage. GCL
packaged gmp4 (now fixed) and their response was that this
should not be part of GCL. I'm not sure if independently
available projects (e.g. ECL, Maxima, etc) would fit the
compile-from-source Gentoo model. Certainly the packaging
of OSX binaries for Fortran will raise a few eyebrows.

Tim Daly

On 10/27/2010 3:38 PM, François Bissey wrote:

On 10/27/10 04:26 PM, mmarco wrote:

A few words about the gentoo platform.

Since gentoo does not follow the usual system of versions, but is
based on continuous incremental upgrades, there is no way to ensure
that sage binaries would work on a given gentoo box. As far as i know,
the usual binaries available for other platform don't run over gentoo.
Although in all the cases i have tried, i was able to build sage from
source.

I think it would be a good idea to change the sentence Gentoo
binaries are regularly available at ??? by a note with a link to the
sage-on-gentoo project.

What's the best URL to use? I found

http://github.com/cschwan/sage-on-gentoo

but is that the most suitable?

I guess since Gentoo uses a different system, it's not exactly comparable
to any Sage build.

There's a few bits I'm lacking on that page, but I think it's a big
improvement over the previous system, where there were several different
references to supported platforms, no two of which agreed with each other.


I should pipe in since we are talking about that.
Generally speaking sage should work on a reasonably up to date stable Gentoo
system. However it would be a good thing to point user to sage-on-gentoo as it
is aimed at properly integrating to their system.
Eventually we plan to make sage available directly from the main Gentoo tree
like any other package. we may keep the overlay around for alpha/experimental
stuff.

The caveats are as follow. The sage-on-gentoo project is focused on the end
user. That is someone gets sage from it and starts working. It is not meant as
a development platform - unless you know how to write ebuilds for Gentoo.
If you want to get new code in sage it may be best to get the tarball.

Francois



--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Function assume() has no effect on Maxima via desolve()

2010-09-23 Thread Tim Daly

 The problem is called the proviso problem, as in things like
1/x provided x != 0

I did thesis work in this area. One of the attacks is to use
cylindrical algebraic decomposition (CAD). A second approach
is to create a tree of expressions based on intervals such as
[1/x where x  0] [1/x where x = 0] [1/x where x  0]
The computation proceeds in 3 parts, each one under an interval
assumption. If a new proviso is added the program tree-forks again:

[1/x where x  0  1/y where y  0]
[1/x where x  0  1/y where y = 0]
[1/x where x  0  1/y where y  0]
[1/x where x = 0  1/y where y  0]
[1/x where x = 0  1/y where y = 0]
[1/x where x = 0  1/y where y  0]
[1/x where x  0  1/y where y  0]
[1/x where x  0  1/y where y = 0]
[1/x where x  0  1/y where y  0]

Note that these can all be run in parallel and the results
combined after the computation. This approach lends itself
to massively parallel computations.

I did a literature analysis of a couple hundred textbooks
and found that approximately 80 percent of all equation
provisos could be rewritten into interval constraints.

A simple assume facility does not begin to address the
problem for many reasons, such as the fact that provisos
can arise during intermediate computations.

Tim Daly





On 9/23/2010 8:36 AM, Burcin Erocal wrote:

On Wed, 22 Sep 2010 11:40:44 -0700 (PDT)
rjffate...@gmail.com  wrote:


Many features in Maxima do not use the assume features at all.
If Macsyma were to be redesigned from the ground up, the issues
related to assume etc would probably be addressed at a foundational
level.

To the extent that other computer algebra systems claim to be a fresh
look at issues, it appears that they have all failed to address this
one.

Instead they ignore assumptions and later patch them on in peculiar
ways
and provide access to this information only from some specific
programs, e.g
Mathematica's Integrate, Reduce, Simplify.  But probably not much
else.

So this known problem (at least since 1974) was off the radar of the
brainiacs
who designed all those subsequent systems, including I suppose, Sage.

I think it would be a huge overstatement to say that the symbolics
subsystem in Sage was designed in any way. IMHO, it was mostly
patched together to support educational use, then acquired more cruft
through several rewrite attempts and cramped schedules.

I am definitely not an expert in this field and have no idea how the
assumptions should work. If you can provide some references, perhaps
these could be used as starting points when/if somebody decides to
work on this.

Here is the only reference I found on this topic:

http://portal.acm.org/citation.cfm?id=680466

The article is available for download here (for those with access):

http://www.springerlink.com/content/p77364025wh6j7h5/


Burcin



--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Function assume() has no effect on Maxima via desolve()

2010-09-23 Thread Tim Daly

 To implement the proviso system I mentioned would require that
it be deeply embedded in the algorithms. Whenever an algorithm
(say, division) did an operation that involved a proviso it would
need to (a) decorate the result with the proviso and (b) potentially
split the answer into separate sub-answers for further computation.

Note that I did not make any restrictions on the provisos so they
could be anything (not even necessarily computable), such as polynomials
or roots (e.g. [x suchthat x in roots of ] and they don't need to
be intervals (e.g. f(x) is holonomic, the so-called is provisos).

There are deep research questions here involving reformulating normal
algorithmic computations to collect the provisos, splitting the
collection into (not necessarily decidable) disjoint sets, doing
parallel computation under a proviso set (generating further subsets
as the computation proceeds), combining partial results to poison
other branches of the parallel computation tree (which implies computing
partial CAD results and a blackboard architecture) and the question
of combining results under proviso constraints (e.g. combining intervals
if the representations are intervals, in order to recover the real line
or the complex plane).

There is a whole research program here but the NSF doesn't seem to know
or care so its unlikely to be explored except by open source. Axiom has
a long term goal of refactoring the algebra to include this in the design
at the fundamental level (which was the point of the thesis work). It is
only in recent years that hundred-core machines are becoming available to
support the huge parallel trees this generates. A proviso-based system
will enable parallel computation in a natural manner as opposed to the
current ideas that depend on simple cases (like matrix multiply).

An assume facility that is bolted-on after the fact cannot possibly
handle issues that arise as part of the computation since intermediate
expressions can contain computations that are not apparent in the final
result. An assume facility could create some initial conditions but would
naturally be expressed using something like Axiom's suchthat.

Tim Daly



On 9/23/2010 11:19 AM, rjf wrote:


On Sep 23, 5:36 am, Burcin Erocalbur...@erocal.org  wrote:


I think it would be a huge overstatement to say that the symbolics
subsystem in Sage was designed in any way. IMHO, it was mostly
patched together to support educational use, then acquired more cruft
through several rewrite attempts and cramped schedules.

I think that is true of ALL the subsystems in Sage.

In terms of my own interests, that is why the idea of rewriting Maxima
in
Python is pointless.  Wouldn't you prefer to write a system that
addressed
the shortcomings of Macsyma (etc.)   And by shortcomings I don't mean
written in Lisp instead of Python.

There are perhaps papers hinting at the Macsyma assume system
capabilities by Michael Genesereth, but a quick search did not reveal
them.
The Maple system has a more ambitious capability, but it is still
patched on.
I do not know where the Mathematica version contains, at the moment.
It
seems to grow, every so often.  But it is still patched on.  The note
from
Tim suggests that (I think) linear inequalities and rectangular
regions can
encode most conditions of interest.  Or maybe polynomial conditions?
Certainly not all. And cylindrical algebraic decomposition may be
useful, though
potentially quite expensive, there is all that other stuff that is not
algebraic.
Like log, exp, cos, ...


I am definitely not an expert in this field and have no idea how the
assumptions should work. If you can provide some references, perhaps
these could be used as starting points when/if somebody decides to
work on this.

Well, you can probably start with that Maple reference,
the next time you design a system. Unfortunately, Sage is already
built, and it
is probably too late.  But Stein is doing something else, so you don't
have
to worry about him getting in the way.  Maybe UberSage; you can call
Sage
if you need to.

Here is the only reference I found on this topic:

http://portal.acm.org/citation.cfm?id=680466

The article is available for download here (for those with access):

http://www.springerlink.com/content/p77364025wh6j7h5/

Burcin


--
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
URL: http://www.sagemath.org


Re: [sage-devel] Suggestion to provide external links in documentation.

2010-09-21 Thread Tim Daly

 You might find this document useful:
http://axiom-developer.org/axiom-website/rosetta.pdf

On 9/21/2010 5:11 AM, Dr. David Kirkby wrote:
I was just looking at a post of Minh's, in which he suggested others 
had suggested adding to docstrings  the names of related commands. 
That seems very sensbile - just like the man pages of a Unix system.


How would people feel about providing links to MathWorld and Wikipedia 
on the docstrings too?


i.e. for norm

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

add links to

http://en.wikipedia.org/wiki/Matrix_norm
http://mathworld.wolfram.com/Norm.html
http://mathworld.wolfram.com/MatrixNorm.html
http://mathworld.wolfram.com/VectorNorm.html

IMHO, it would also be worth adding the nearest equivalent commands in 
Macsyma, Mathematica, Maple and MATLAB, though I doubt that will be 
possible for many commands. sin() would have


Sin[] - nearest equivalent command for Mathematica
sin() - nearest equivalent command for MATLAB

I don't know about the command for 'sine' in other packages, but no 
doubt someone is familiar with them.


One could also add for packages where there is no similar command for 
the commercial packages.


foobar() - As of version 7.0, Mathematica has no similar functionality.

I think at one point, providing a list of equivalent commands in these 
packages should be done, to aid people porting code from these 
packages to Sage. A start would be to document the nearest equivalent 
commands in the actual docstrings.


At least if a conversion list was ever made, the docstrings would 
provide some help to those compiling such a list.



Dave



--
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
URL: http://www.sagemath.org


Re: [sage-devel] Cliquer - upstream modifications and dubious code

2010-09-15 Thread Tim Daly

 This might be of interest on security grounds:
http://www.amazon.com/Secure-Coding-Robert-C-Seacord/dp/0321335724

On 9/15/2010 6:46 AM, Dr. David Kirkby wrote:

On 09/15/10 06:17 AM, Minh Nguyen wrote:


I'm disheartened that this happened. One should not modify upstream
source, but place patches against upstream source under the directory
patch/.


I think you mean patches. I did notice a patch directory in 
Cliquer, but


http://www.sagemath.org/doc/developer/patching_spkgs.html#overview-of-patching-spkg-s 



says patches. That's a minor point though.


I worked on getting Cliquer to build as a shared library on Cygwin,
Linux, Mac OS X and Solaris (t2.math). I take your comments as an
encouragement for me (or anyone) to further investigate how to polish
up the Cliquer spkg. In my programming work, I have been following
advice from E. S. Raymond's book The Art of Unix Programming [1] and
D. A. Wheeler's book Secure Programming for Linux and Unix HOWTO --
Creating Secure Software [2]. I hope you would continue to share your
thoughts, as you have generous done, on good programming practices so
that contributors to the Sage community can benefit from your
experience.


Clearly Minh you take the time to read up on what are considered good 
practices, but your attention to such issues is not universal among 
Sage developers.


#1 seems pretty useful for all Sage developers to read.

#2 is a bit less so, though clearly anyone dealing with the notebook 
should look at #2.


IMHO, the notebook is very bad from a security point of view, but I 
have some sympathy for William over that. He probably never expected 
to get a large number of people using one sage server, so security was 
not high on his priority list.


It's s shame there are not any decent books online about best 
practices in software engineering. Whatever I've found tends to be in 
expensive books.



[1] http://catb.org/~esr/writings/taoup/html/

[2] http://www.dwheeler.com/secure-programs/

[3] http://en.wikipedia.org/wiki/Clique_(graph_theory)





--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: A Mathematica parser for Sage.

2010-09-08 Thread Tim Daly

Some of the questions you have about why lisp are answered in:
http://channel9.msdn.com/shows/Going+Deep/Expert-to-Expert-Rich-Hickey-and-Brian-Beckman-Inside-Clojure/
which is about Clojure, a more recent lisp although the ideas are
essentially the same in Common Lisp.

Tim Daly

David Kirkby wrote:

On 5 September 2010 10:14, Mitesh Patel qed...@gmail.com wrote:
  

Hi David,

On 09/05/2010 03:52 AM, David Kirkby wrote:


I'm quite happy to be that someone who learns Lisp - I'm serious
thinking of buying a book on it. Unfortunately, they tend to be quite
expensive, as do books on writing compilers.
  

Some time ago, I found Practical Common Lisp by P. Seibel, which is
available for free online:

http://www.gigamonkeys.com/book/

But I have not read it and am not familar with Lisp.

Sincerely,
Mitesh



Thank you for that - it is one of the books on Amazon I was considering.

http://www.amazon.com/Practical-Common-Lisp-Peter-Seibel/dp/1590592395

It's $52.29 on Amazon - to find it free is quite nice.

I also found Common Lisp: A Gentle Introduction to Symbolic Computation - all

http://www.cs.cmu.edu/~dst/LispBook/index.html

I want to finish the Solaris port first, getting it building properly
on 64-bit systems. But then I might take a look trying to parse
Mathematica and do something useful with it.

Dave

  


--
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
URL: http://www.sagemath.org


Re: [sage-devel] A Mathematica parser for Sage.

2010-09-06 Thread Tim Daly




Without knowing Lisp it is hard for me to really tell how valid your 
arguments are, but I must admit a couple of people who know both Lisp 
and Python have said Lisp would be easier. You are RJF are not the 
only ones to express that opinion.


Dave


Consider the MMA code as a source language and write a simple
compiler stage that translates that MMA code to a tree structure. You
have to do this in any modern compiler architecture. For this purpose you
can think of lisp as a printable form of AST structures. So the lisp data
structures are just these parse trees. MMA parse trees are easy to make.

Lisp gives execution semantics to these AST data structures since, in lisp,
data is code and code is data. So once you finish the first stage of your
compiler using lisp as your AST target language you're done. Just 
execute it.

In fact, lisp implements the rest of the compiler for you.

Axiom's Spad language does the same thing. The Spad language gets parsed
into an AST which just happens to be list data structures. These data 
structures
also happen to be executable lisp. Gnu Common Lisp compiles the lisp 
code to C
and GCC compiles the C code to machine code. So Spad algebra is 
implemented
in machine code, or implemented in C, or implemented in lisp 
depending on
where you want to focus. But all we had to write was the source-language 
(spad)

to-source-language (lisp) parser.

Writing in lisp gives you all the power of the python-cython but the whole
process is automated and you don't have to change language level. The
generated machine code is extremely efficient (matching Fortran machine
instruction sequences for numeric code).

So when a lisper sees the whole rewrite it in cython to make it faster
debate and hears that python is an interpretation-only language you can
begin to see why python seems so primitive. The whole interpreter/compiler
issue was solved and automated 30 years ago, only to be recreated by
python/cython in a more primitive, hand-processed form. Writing an MMA
compiler on top of the python/cython stack is a LOT more work and re-invents
technology that is 30 years old.

Just parse Foo[x] into (Foo x) and execute it. Problem solved.

Tim Daly

--
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
URL: http://www.sagemath.org


Re: [sage-devel] A Mathematica parser for Sage.

2010-09-05 Thread Tim Daly



David Kirkby wrote:

On 5 September 2010 22:13, William Stein wst...@gmail.com wrote:
  

On Sunday, September 5, 2010, David Kirkby david.kir...@onetel.net wrote:



  

RJF thinks Lisp is the best language
William thinks Python is God
  

No I don't.

I chose Python for Sage because in 2004 it was the closest popular
open source language to Magma.



God was the wrong word. But you have said Python is a beautiful
language.  Your view of the language contrasts greatly with that of
RJF.

It's not clear to me the best way to tackle something able to parse
Mathematica.

It is however very clear there are far more people know Python than
Lisp, so use of Python is more attractive to more developers.

Dave

  

What does the number of python developers have to do with the question?

If we look at the problem domain it appears that the task is a 
source-to-source

transformation followed by an execution of the result.

Which language makes this task easier?

MMA-to-lisp followed by execution involves changing MMA data structures
into lisp data structures which, because of the data-code equivalence 
of lisp,
just involves evaluating the resulting expression in Maxima. It would be 
possible

to write a Sage pexpect front end that takes MMA syntax as input, calls a
(translate-and-execute) function in Maxima, and returns the result. Thus 
you get

both Maxima and MMA in the same code pile at little cost.

MMA-to-python is a compiler task (lex/yacc/AST/codegen). The generated code
would have to know which subsystems would be involved because the syntax of
the calls vary. An alternative is an MMA interpreter, which is a lot of 
work.

Adding MMA syntax to the python top-level would involve much more pre-parser
effort in Sage, moving the Sage language farther from python than it 
already is.


While they are conceptually equivalent tasks, the lisp version seems to 
me to be
mechanically easier to implement. It is considerably more flexible and 
more easily

extended. Lisp could easily add new syntax, something a MMA-to-python based
compiler would find a struggle.

Tim Daly

--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Random banter about Sage standards

2010-09-02 Thread Tim Daly



William Stein wrote:

On Wed, Sep 1, 2010 at 6:08 PM, Jason Grout jason-s...@creativetrax.com wrote:
  

On 9/1/10 10:32 AM, Bill Hart wrote:


Tim,

all screwing around aside for a moment. I broadly agree with your
sentiments. However, there are also some issues with what you are
suggesting. And I mean to make these observations in all seriousness.
  

I'm reading this thread with great interest.  Though I don't have strong
feelings one way or the other at this time, your post made a lot of sense to
me.  Thanks for the post.

Jason



I've written a blog post that is relevant to this thread:

http://389a.blogspot.com/2010/09/purple-sage.html

  
As I understand your post, you are creating software for your own 
personal use.
Clearly the only standards that matter are your own. Do you agree that 
creating

software that the world should use might require different standards? What
would you expect those standards to be? Should the code be required to do
more than just compile and run a simple test?

--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Random banter about Sage standards

2010-08-31 Thread Tim Daly



I think the claim was that it is becoming the M$ of mathematical
software. I suspect that means default standard or something.
Actually, I didn't ask. Tim, what does it mean?
  
I was making the assumption that Sage managed achieve success by being 
widely
adopted and replacing the 4Ms. The bulk of the discussion rests on that 
assumption.

If that assumption is not true and Sage disappears, nobody cares.

Tim Daly

--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Random banter about Sage standards

2010-08-31 Thread Tim Daly




If I understand you correctly, you want to set the goal for Sage much
higher than just a free, open alternative to the Ma*s.

- Robert

  

Yes, but why am I trying to do that?

Computation mathematics is a new field of study, at least in the 
symbolic area.
It is the child of the union of mathematics and computers. Unlike other 
forms

of software, computational mathematics software (CMS) has the property that
it will always be able to give timeless answers, making it useful forever.

Being useful forever does not imply that the software survives forever.
You can argue that this is good darwinian attrition. But CMS software is
very hard to build and requires a great deal of very scarce expertise that
can disappear at any time (e.g. changing jobs, being hired into a company
like MapleSoft/Wolfram/Magma/etc., companies being bought or closed)
When that happens, and it will, then that portion of the software becomes
unmaintainable or unavailable.

The natural response to dead software is to write new software. You can
see this in CMS-land as there are over one hundred attempts at building
CAS programs (I collected them at one point, similar to the Sage goal).
But due to the expertise issue these programs don't get very far. Sage wants
to rewrite the Trager/Bronstein integration but that seems unlikely as the
required expertise (Bronstein) is dead and the code isn't documented (yet).

Sage is trying to avoid the darwin problem by gluing together existing 
systems.

This is a very clever idea, a second generation response.

What I am trying to do is ask the question...
What does a computational mathematics system need to do to live forever?
in particular, in this forum,
What does Sage need to do to live forever?

Sage is exciting, fast moving, has no time to do it right, would die of
documentation ossification, couldn't possibly prove anything (as if proofs
are foreign to mathematics), needs to be released twice a day, is in a
foot-race with the 4Ms for mind-share, needs quantity not quality, will
let the next-generation-slubs document their work, is 3ns faster than 
M*, etc.


I am one of the first generation dinosaurs trying to impart some of the 
lessons
learned to the next generation. I am taking the long view, trying to 
figure out

how to impart computational mathematics to my grandchildren. Will they still
be writing new polynomial packages and arguing over ZZ? Will they have to
watch yet another hundred threads discussion the same issues? Will they 
suggest
that William Stein should move his comments to the flame thread? Or will 
they have

a broad legacy of excellent CMS work upon which to build?

My experience tells me that William will move on, python will move on, the
funding will dry up, the students will be hired into real jobs and Sage 
will die

of code rot as GCC/python/architecture/build-complexity/etc all work away
at its foundations. The system will devolve into tracking down hard bugs in
other peoples code, people will find that hard without documentation
and not worth doing because it isn't flashy. Suppose William had instead
proposed that Sage was a project to find and fix all the bugs in Maxima.
How many people would join? Now imagine Barry Brightspot proposing
a project to find and fix all the bugs in Sage

To those who work on Sage... Why? Do you just want to build yet-another-CAS?
Do you just want a platform for your thesis work? Do you just want to
write code that gets thrown away? Or would you rather have your name
appear in the credits list of Sage-2090 as one of the Newtons of
computational mathematics?

I am advocating that Sage set its goals much higher than replacing the Ms.
If you don't, then my experience tells me that the project will die. If 
you do

then the project may die anyway but other people can build on the remains
rather than from scratch. Or you just might have a formula for the 
long-term.


What do *you* think needs to be done to make Sage live forever?
I have thought about this question for a long time and I'm trying to 
pass it on.
Your experience may tell you that my suggestions are wrong but you'll 
only be

able to know after the fact and by then it will be too late.

Anyway, I've said about all I want to say so I'm abandoning this topic.
Good luck and thanks for all the fish.

Tim Daly



--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: test suites for Sage

2010-08-30 Thread Tim Daly

Nicolas,

This is similar to the CATS pamphlet files.
They use noweb format but they could use the \begin...\end
latex environment. I plan to make that change anyway.

If we look at one of the files, e.g.
http://axiom-developer.org/axiom-website/CATS/schaum1.input.pamphlet
it is a sequence of blocks. The Axiom comment character is -- so
any line beginning with -- is ignored by Axiom.

Each block is of the form

--S (number)
An Axiom Command Line
--R
--R The expected output from Axiom
--R
--E (number)

So when this file is run Axiom sees a command line followed by
a set of comments. The comments contain the expected output.

A post-process reads the output from Axiom and compares it
to the comments. The --S/--E numbering scheme allow the compare
function to check that all tests run and list the number of the
failing function.

This allows us to automate the testing.

Tim Daly


Nicolas M. Thiery wrote:

On Mon, Aug 30, 2010 at 03:33:23PM +1000, Minh Nguyen wrote:
  

A few months ago I experimented with writing test cases in LaTeX as
part of a detailed discussion of underlying relevant theory. So for
example you want to write some test cases for graph theory. You start
by writing a short document explaining any relevant theory and runtime
complexity of algorithms you want to cover, with references to any
literature where appropriate. Next write down properties you're
interested in together with any expected results, followed by a
transcript of a Sage session that verify the stated properties. All of
these are written up as a LaTeX document just like your normal LaTeX
document. To run the test cases through Sage, I used a little tool [1]
to extract the test cases and run them through the Sage doctesting
framework. As an example of what I mean, refer to this document [2]
which is a work in progress.



For the record: the (relatively new) sageexample environment of
sagetex allows for including doctest like examples in the latex file:

  \begin{sageexample}
sage: 1 + 1
2
  \end{sageexample}

Upon compilation, those examples are all extracted to a separate file
which you can test using sage -t. That's what we use to check the
examples in our French introductory Sage book. This still has a couple
glitches, but the more people use it, the better it will become :-)

Best,
Nicolas
--
Nicolas M. Thiéry Isil nthi...@users.sf.net
http://Nicolas.Thiery.name/

  


--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Random banter about Sage standards

2010-08-30 Thread Tim Daly



How do you expect Wolfram Research, Maplesoft and similar deal with such
issues? They must hit them too. I suspect they have a few nightmares with
this, but the best way is probably to have decent documentation. If code is
well commented, and has references to papers where the algorithms are
published, then it sill probably be maintainable.



Actually I've had the same literate programming, deep documentation 
discussion with
developers from Wolfram and Maple. According to them, neither program 
has good
internal documentation. They can rely on the fact that they can pay 
people to maintain

the source and the knowledge continuity. I have begged them to improve it.

Why would *I* care? Because of the future. Think about things in the 
long term.


There are very few companies that last 50 years. Indeed, Maplesoft was 
bought recently.
What would happen if Wolfram and MapleSoft died? Well, in the worst 
case, the failing
company just disappears. Nobody can run MMA or Maple code anymore. This 
creates
a *huge* black hole in computational mathematics. (Think Derive and 
Texas Instruments).


There is the possibility that the code might be released but it is a 
very slim chance.
Companies that go bankrupt get their assets sold. The source code would 
be the major
asset and there would be a lot of people wanting to get paid so they 
won't likely make

the code open source. (Think Macsyma and Symbolics)

But lets assume the best case, that MMA and/or Maple became open source.
Here I have a great deal of experience because *I* got the open source 
version of
Axiom which was a very large, very complex program. Axiom was sold 
commercially
as one of the big 3. Internally it was mostly code with about 3 lines 
of useful
documentation. The released version of the code lacked the front end 
(saturn),
the back end (nag libraries), the new compiler (aldor), and required a 
running
Axiom in order to build Axiom so it had to be restructured to 
self-bootstrap.


The only reason that Axiom came back to life is that I was one of the 
original
developers and had a deep understanding of the system internals. I'm not 
bragging,
I'm simply pointing out that it is difficult to organize and repair a 
million things of code.
Even with my deep understanding of internals (some of which I wrote) it 
still took a
year to make it available. I found that I couldn't understand my own 
code and I always

try to write dirt-simple code, unfortunately without comments.

Now imagine that someone handed you the (partial but mostly complete) 
source code for

MMA or Maple. And imagine that it contained 3 useful comments.
Is there any chance of rebuilding these programs into runnable systems? 
I think not.


Now imagine that MMA and Maple were fully literate and could be read 
like a novel.


Which would you prefer?

Which scenerio benefits computational mathematics in the long term?

Now apply the same lesson to Sage. Assume that 30 years from now, none 
of the
original developers are connected with the code and there is no one to 
ask. It will happen.


Tim Daly

--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Random banter about Sage standards

2010-08-29 Thread Tim Daly
 
of the arguments
but also on the type of the return (something that is still not common). 
But Axiom was
developed as research software, not with the intention of being brought 
to market as a

product (free or commercial). Sage is being developed with this intention.

Our choice of standards was to build on abstract algebra. There were a 
great many
debates about the right way to do things and we always went back to the 
touchstone of
what abstract algebra implied. At the time (40 years ago) there were no 
existing examples
of computational mathematics for many of the ideas so we had to invent 
them. Axiom
set the standards (e.g. integration) and they were quite high (Axiom 
still has the most

complete implementation). Sage has existing examples to guide it.

So at the time Sage was being developed there *were* standards in place. 
You seem
to feel that Sage was started pre-standard (2005?) and pre-referee 
(ISSAC?).




I think this was necessary for the
time--Sage would have gotten off the ground if it couldn't have been
useful so quickly. This includes in particular many of the spkgs that
have been grandfathered in and wouldn't make the cut now, but it takes
time to remove/replace/clean them up. Of course there's room for
improvement, but do you think the current review process is
insufficient and lots of new bad code is being written and included?
If so, what should we do better?
  


I *do* feel that the current review process in Sage is insufficient (see 
my earlier diatriabe).


I see reviews of bug fixes but I don't see reviews of spkgs. We are now 
over 50 years
into the development of computational mathematics and Sage has the goal 
of competing
with systems developed in the 1970/1980s, over 30 years ago. This would 
be a great
thing if Sage were to deeply document the algorithms, develop the 
standards, and/or
prove the code correct but I don't see anyone advocating any of these. I 
don't see anyone
advocating alternative ideas that would raise the bar in computational 
mathematics.


Even in the area of education I don't see anyone hammering on the NSF to 
fund more
efforts in computational mathematics. I don't see pushback to NIST to 
standardize the
algorithms. Obama wants to bring science back to life and encourage 
research. As the
largest group of academics I would wish that you would petition the 
funding sources.
Even if all of the funds went to Sage I'd still feel that this was 
worthwhile.


In short, I don't see *change*.

Tim Daly
(curmudgeon and rjf wannabe)

--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Random banter about Sage standards

2010-08-29 Thread Tim Daly



Bill Hart wrote:

Why is this entire thread not on sage-flame? What does software
engineering, documentation, test code, etc. have to do with Creating
a viable free open source alternative to Magma, Maple, Mathematica and
Matlab.?
  
Despite what appears to be competitive badgering I really do want Sage 
to succeed.
But I don't want Sage to spread the impression that mathematical 
software can't be trusted.


I badger because computational mathematics is my chosen field of study 
and I feel it is
*vital* to raise the standards to professional, high quality, 
trustworthy levels. If Sage is going
to be the M$ of mathematical software, will it also convince everyone 
that math software
just gives highly questionable answers? Every program makes mistakes but 
hand-waving
about it's not my problem, it's the upstream code gives the whole 
field a bad reputation.
And I very much care about that. This *isn't* software, this is 
*computational mathematics*.


If advocating such project goals is considered sage-flame material 
then we all lose.


...[snip]...


Why attack Sage. It is what it is. Why defend it. It certainly didn't/
doesn't get everything right. One thing is for sure. Whatever is wrong
with Sage, it is almost certainly too late to fix it. Whatever is
right with Sage certainly made it popular.
  

*sigh*

If you want to make Sage seriously innovate to solve one or more of
the above, you need a *large* group of like-minded volunteers who can
help you. You won't do it on your own, no matter how many years you
work, nor how hard.

Many of the things Tim and David say resonate with me. I'd really,
really love a tremendously efficient, well-documented, reliable, Open
Source mathematical project. Having seen how insanely difficult even
just goal number 1 is for just the domain of arithmetic, I honestly
think we haven't got a chance. Not ever. The expertise don't exist in
sufficient quantity. And even those with the expertise, don't have the
time. So, looks like we are stuck with what we got.
  
Re: don't have the time... Unlike any other software effort, programs 
like Sage are timeless.
The integral of the sin(x) will always give the same answer, now or 30 
years from now. Any
one individual does not have the time but the project does, assuming 
it lasts. Would you
read a mathematics journal with the editorial policy we'll print 
anything because we don't

have the time?.

By the way, does anyone know what the current state of program proving
is? How does this work? Does one write the proof by hand then
formalise it in code in a formal system until it parses? Can someone
give me some references on this. I am genuinely interested. I've read
some comments about SML being good for program proving (why?), and
that the Haskell type system amounts to giving a proof under some
circumstances. But it is baking my noodle how any of this has anything
to do with proving programs, especially in mathematics. The monad
idea in Haskell gave me some hope, because it sounds mathematical, but
I simply didn't understand it, at the end of the day.
  

See http://en.wikipedia.org/wiki/Curry%E2%80%93Howard_correspondence
and http://userweb.cs.utexas.edu/users/kaufmann/tutorial/rev3.html#top
and http://coq.inria.fr/a-short-introduction-to-coq

The first one shows that writing programs and proving programs have a
correspondence. The second one shows ACL2 which is basically a way of
writing program proofs in lisp. The third one shows COQ which has a very
strong connection between mathematics and types.

In systems like Maxima and Axiom it would be possible to embed ACL2
directly into the system (lisp is lisp after all) and perform the proofs 
inline.

Given the mathematical definition of a Ring and a function on the Ring
elements you could prove the function correct. For Axiom this is part of
the stated long term goals of the project.

On the other side (at the machine level) there is a program called FX, that
is, Function Extraction. FX grew out of the work by Richard Linger,
Harlan Mills, and Bernard Witt. It is being constructed at the Software
Engineering Institute. FX reads machine language, extracts the semantics,
and composes the instructions into blocks of behavior. You can't fully test
a program but FX covers *all* of the program behavior so you can identify
failing cases. See
http://daly.axiom-developer.org/TimothyDaly_files/publications/sei/Man75586.pdf
(disclaimer: I am one of the authors of the FX technology)

Testing programs is as ineffective as testing theorems.
No matter how many examples you create, you don't have a proof.

Tim Daly

--
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
URL: http://www.sagemath.org


[sage-devel] Re: test suites for Sage

2010-08-29 Thread Tim Daly

I am working on 2 new test suites.

One involves the Rubi test suite using patterns for integration.
This is a very large test suite, well over 9000 integrals.
I have created test cases for Axiom but not yet written the
rule-based integration patterns. I'll move them into the CATS
area in the near future. This establishes a baseline against
which the new rule-based integration patterns can test. I have
to add special functions like polylogs which Axiom does not yet
recognize before I can go further and then write the pattern rules.

Piezas's work is also pattern matching. The difficulty for
computational mathematics is that some of the patterns might
not hold true across all domains. They are identities so this
should not be a problem but I'd have to look at them in more
detail to be convinced. I've done no more than glance at the pages.


The second test suite involves graphing. I am using the
CRC Standard Curves and Surfaces (David von Seggern) book
which covers a huge range of graphs, from random (fractal,
gaussian, non-guassian) to determinate (algebraic, integral,
transcendental, piecewise continuous). This is moving, but
slowly, and will probably not see the light of day until 2011.

I tried to write a test suite based on Yudell Luke's
The Special Functions and Their Approximations that involved
expansions of MeijerG function but I don't know that I've got
the chops to do it. Maybe in my next life :-)

Tim (somebody, I can't find his name) was going to try the
CATS integration test suite in Sage. It should be rather easy
as Sage uses Maxima and the syntax is very close. I don't
know what became of that effort.

If you do a test suite on graphs I'd be happy to try to
make it work in Axiom. This would likely involve writing new
algebra code so it would be helpful if you included citations
of algorithms (if you know them) as you develop it. It looks
like Gross and Yellin includes high level algorithms so that
would be exceptionally helpful. I strongly favor basing test
suites on books containing algorithms.

A test suite for sequences and series is on my wish list but
I have not found a good reference for it.

I think it would be useful to collect good reference books for
any of the mathematics we want to test. This would give other
people a good starting point for developing test suites.

For the CATS test suite each file contains the problem, the
expected answer, and Axiom's answer. The format of the files
makes it possible to run them automatically which I do with
every system build. Does Sage have such a file format?

Tim Daly

Minh Nguyen wrote:

This is a split off from the thread Random banter about Sage
standards at 
http://groups.google.com/group/sage-devel/browse_thread/thread/c80b87648c213c5


Hi Tim,

On Fri, Aug 27, 2010 at 9:59 PM, Tim Daly d...@axiom-developer.org wrote:
  

For *standard test suites*, I believe we should have these in many
different areas. We should collect a set of reference books that are
fairly comprehensive and jointly develop tests that run on all systems.
Rubi is doing this with rule based integration.
http://www.apmaths.uwo.ca/~arich/
Axiom is doing this with the Computer Algebra Test Suite
http://axiom-developer.org/axiom-website/CATS/index.html



This is a point I at least agree on. I think it would be a moderately
difficult project to write a Sage counterpart to the Axiom CATS. It
would be an interesting project to see how one could develop a similar
test suite based on T. Piezas III's book A Collection of Algebraic
Identities available at

https://sites.google.com/site/tpiezas/Home

I've have been thinking about writing a test suite for Sage's graph
theory functionalities. The following comprehensive book provides a
good starting point on what to include:

* Jonathan L. Gross and Jay Yellen (eds). Handbook of Graph Theory.
CRC Press, 2004.

All of these items are on my todo list [1], but I haven't made any
headway on any of them in the last few months.

[1] http://sage.math.washington.edu/home/mvngu/todo.html

  


--
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
URL: http://www.sagemath.org


Re: [sage-devel] Textbook converted to Sage worksheets

2010-08-28 Thread Tim Daly



Rob Beezer wrote:
I've converted Tom Judson's open-source Abstract Algebra textbook 
(http://abstract.pugetsound.edu) from Latex to a series of Sage 
worksheets (one per chapter) with almost no compromises (ie the same 
source also builds a faithful PDF).  Cross-worksheet links are not 
supported yet in the notebook, and I've not yet started adding Sage 
code to the book, but adding compute cells is possible and feasible 
right now.  Available as the first example on the wiki page:  
http://wiki.sagemath.org/devel/LatexToWorksheet


Rob,

This is excellent. It would be useful if these kinds of textbooks were 
available
in versions for every CAS. I'll look at what it might take to generate 
an Axiom
version. Like the CATS test suites, this could give everyone a common 
touchstone

for discussion and debate as well as a common reference for teaching.


The worksheets are packaged into a single zip file, which the notebook 
will upload and unpack (mostly even in the right order).  There is a 
live compute cell at the bottom of each chapter for experiments or 
annotation via Tiny MCE. The graphics all begin life as tikz diagrams, 
so even these have editable source code.


Tom has done a lot of work to modernize the source, since this book 
was originally written in the late 1980's.  He had to also update the 
Historical Note about Fermat's Last Theorem.  ;-) I'll be working over 
the next several months to add in material about using Sage to study 
groups, rings, fields, etc.  Any extra non-obvious ideas about how to 
leverage Sage in the study of these topics would be appreciated.  
Reports of any typos or technical problems with the current 
state-of-the-art would also be appreciated.


I have a few other books in various states of conversion, some have 
Sage code already.  I'm also going to use Tom's book to further 
stress-test MathJax, which has already resulted in two bug-fixes for 
the MathJax jsMath-compatibility extension.  I've had help from 
several people on this, notably Tom Judson, Robert Marik, Dan Drake, 
Minh van Nyugen and Davide Cervone.
I'll contribute any examples from Axiom that have direct conversions to 
Sage.


(I've cross-posted to sage-devel and sage-edu - sorry for the noise if 
you read both.)


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
URL: http://www.sagemath.org


Re: [sage-devel] Random banter about Sage standards

2010-08-27 Thread Tim Daly
 this with rule based integration.
http://www.apmaths.uwo.ca/~arich/
Axiom is doing this with the Computer Algebra Test Suite
http://axiom-developer.org/axiom-website/CATS/index.html

If we publish and maintain the test suite results for all systems
there will be great pressure to conform to these results, great
pressure to develop standard algorithms that everyone uses, and
great pressure to improve areas of weakness.

For *program proofs* I can see where ACL2 and COQ can be integrated
into systems so that a published paper can include an automated
proof. This will raise the standard expected for professional
publications in computational mathematics. It will also move us
away from depending on domain experts who have the unfortunate
tendency to die off, both personally and professionally.



The 30 year horizon ...

We are nearly 50 years into computational mathematics.

It is time to develop departments and textbooks, raise the level
of expectation for peer-reviewed publications, develop not only
software engineering practices but also computational engineering
practices. Computational mathematics is the one area of software
where you can independently check your answers and you can expect
to write timeless software that gets the same answers 30 years later.
It really is worth the time to get it right.



To bring this diatribe back to earth and the original subject,
you have identified a symptom of a much larger problem with the
current systems. Unfortunately there is no peer-pressure to have
higher standards. I was hoping that the NIST Digital Library of
Mathematical Functions would be the touchstone of algorithms but
that is clearly not the case.

Perhaps someday there will be sub-department of the NSF that
tried to organize, guide, and fund it but nobody there has
the vision and the will to get it done. Maybe we should
nominate William as an NSF director :-)


Tim Daly

Dr. David Kirkby wrote:

On 08/24/10 02:06 PM, kcrisman wrote:


Anyway, I think (as you have correctly noted before) we have a bit of
a culture clash between software engineering and mathematics.


SNIP



Just have patience with those of us who aren't from a software
background - and trust that we are trying hard to internalize your
lessons, but that we have more immediate needs to fill as well for our
next course or paper.  I think that just as Minh's messages about
documentation are slowly taking hold in the whole ecosystem, so are
yours about software engineering.

- kcrisman



Just to make a point, my own background is not software engineering. 
My first degree is in electrical and electronic engineering, my 
masters in microwaves and optoelectronics and my PhD in medical 
physics. Apart from a very brief spell (about 6 months), I have never 
worked in the IT industry.


I first became aware of the subject of software engineering when an 
Australian guy joined the department I worked at University College 
London. Russel's task was to develop some hardware and software for a 
research project. He quite rightly realised that developing software 
by the seat of your pants as he called it was not the way to go 
about it. So before starting to write the software, he purchased a 
book on the subject of software engineering.


I never gave this topic much more thought until I started working on 
Sage. I then because to realise that Sage needs to take a more 
professional approach to the development, as it seems a bit add-hock 
to me.


My own view is I'd rather have something with less features, which I 
could rely on, than lots of features I don't trust. When there is 
little in the way of project management, and a culture of not doing 
anything properly, then attitude tends to spread like a virus.


I'm currently running the doctests 100 times on a machine, with the 
same build of Sage that passed all doc tests. This is an interesting 
failure I observed:


sage -t  -long devel/sage/doc/en/constructions/linear_algebra.rst
**
File 
/export/home/drkirkby/sage-4.5.3.alpha2/devel/sage-main/doc/en/constructions/linear_algebra.rst, 
line 202:

sage: A.eigenvalues()
Expected:
[3, 2, 1]
Got:
[3, 1]
**


The tests have been run 41 times now, and only once has that test 
failed. The answer looks quite reasonable, but I assume is wrong, as 
the other 40 times the code gave the expected value. It's these sorts 
of things that concern me. Why should the same build of Sage, running 
exactly the same doctests each time, not produce repeatable results?


There's been a few failures, though that is the only one I've noticed 
where the answer looks very reasonable, but is in fact incorrect.


Dave



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

Re: [sage-devel] Re: How does real_lazy work?

2010-08-11 Thread Tim Daly

Axiom solves this problem by separating the category
information from the specific domain information.

Thus you can have a categorical implementation that works for
every domain in the category but you can supply a specific
implementation for a given domain.

So a dense matrix and a sparse matrix are both matrices
but each can override the default multiply routine for
efficiency reasons.

Domains can take parameters that specify information.
Polynomials are represented by a domain that supplies the
coefficient ring R so that you can create a polynomial over
integers, a polynomial over fractions, a polynomial over
the roman numerals, etc. Thus you say you want a
Polynomial(Fraction(Integer)), a polynomial with fraction coefficients.
Fraction(Polynomial(Integer)), a fraction with polynomials in the
numerator and denomiator where the coefficients of the polynomials
are integers.

So if p is a polynomial with fractional coefficients
(that is, Polynomial(Fraction(Integer))

 1  3   1  2
 - x  + - x
 7  3

we can ask for the same thiing as a fraction of polynomials
(that is, Fraction(Polynomial(Integer))

   3   2
3x  + 7x
-
 21

which is known as rearranging the type tower

Sage can use a similar scheme to separate the category information
from the domain information and from the domain representation.
From a mathematical point of view this has been a very successful
way to separate concerns.

Tim Daly

Johan S. R. Nielsen wrote:

On Aug 11, 1:28 pm, koffie m.derickx.stud...@gmail.com wrote:
  

Hej Johan,

It indeed seems to be at the core of a wider problem. The core of the
problem seems that sometimes you can represent various objects in
different ways.

- So in the coding theory example you can represent a general linear
code by a generator matrix. While you can represent a cyclic linear
code by a generator polynomial.
- In real_lazy you represent sqrt(2) as an algebraic element. But you
want to execute functions on it's binary representation (1.011010100
etc.).
- In linear algebra you can represent a matrix as a sparse or a dense
matrix.
- In commutative algebra you can represent a polynomial in a sparse or
a dense way.
- More suggestions are welcome :)

In all these cases you might sometimes want to execute functions as
implemented for the other representation. The big question of this
topic was how to nicely make these functions available as attributes
without breaking class inheritance and docstrings. I guess the best
solution suggested is Robert Bradshaw's solution. It would be nice to
have a working example of it's suggestion to be able to test it. And
maybe also add a section to the structuring code in Sage part in the
sage developers guide.



This is exactly it, and it crops up more or less everywhere in
mathematics. What I want to do for the error-correcting codes case
(exemplified via the one question posed above), is to begin with the
representation which is mostly used (or the representation most
tightly encompassing the object in question), so for a cyclical code,
I would use the generator polynomial. Whenever one wants to access it
as a linear code, this should be seamlessly (or close to) allowed, and
should generate the generator matrix in the background and cache it
for later use. Unfortunately, inheritance seems to me to be at the
same time too rigid and too weak, so I would sidestep that entirely
and rely on ducktyping (and manual implementing of inherited
attributes -- perhaps using solutions inspired by Robert's here).

Problems like this and the one of this thread arise all the time, but
I have yet to see an agreed or standardised solution ideology in
Sage. Has it ever been decided? Or is it empirically defined through
the current Sage code? I would very much like to see it in a section
called Structuring code in Sage -- just as much as I would like to
see such a section. The existing documentation in Writing code for
Sage is only concerned with micro-level problems such as doc-strings
and naming conventions; there is no discussion on macro-level stuff
like structuring. I guess this is also to encourage taking these
discussions on this board but sometimes general stuff is agreed on
such discussion which could be written down. I guess; I am new here,
so I might easily have missed something fundamental.

  

@Johan, is the problem I describe here the only one that was mentioned
in the other google thread or are there more?



There are several more, and some of them less specific. More or less
my entire first post is a discussion of how to solve the general case
of your example problem for the codes as well as related problems
regarding how to encode and decode. I invite everyone (also those not
familiar with error-correcting codes) with an opinion on these
structuring issues to join the discussion.

Cheers,
Johan

  


--
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an email to 
sage-devel

Re: [sage-devel] Re: complementary problem

2010-08-04 Thread Tim Daly



mda_ wrote:

Hopefully this all agrees with you, and if not, I guess I can start
learning Lisp...



My apologies for the cross-posting (I am not yet approved for sage-
flame)

http://www.buayacorp.com/wp-content/uploads/2007/10/john-mccarthy-poster1.jpg
  
The fact that you're doing it at all implies the imperative which, as 
we all know,

is not the way to program (this week).

(Above: A portrait, and tribute! ;-), to the inventor of lisp!)

http://en.wikipedia.org/wiki/John_McCarthy_(computer_scientist)

  


--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Python, Sage, categories

2010-07-24 Thread Tim Daly

You might find this interesting...
http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.110.7221rep=rep1type=pdf
Taivalsaari, Antero On the Notion of Inheritance
ACM Computing Surveys, Vol 28 No 3 Sept 1996

Robert Bradshaw wrote:

On Sat, Jul 24, 2010 at 10:46 AM, Harald Schilly
harald.schi...@gmail.com wrote:
  

On Jul 24, 8:10 am, Robert Bradshaw rober...@math.washington.edu
wrote:


We should do this as part of the tests, collect timing data on each
test block (and perhaps even each line?).
  

I don't think this would work for all lines because completing all the
tests would take too long (if we want to use timeit, each line is
repeated several times)
I rather suggest to add something to the doctest infrastructure, that
executes those lines in timeit(..) that are tagged via # timeit
appended to the line.
e.g.
sage: x = 1
sage: _ = x*x # timeit
Data for these timings are collected in a key-value dictionary that is
pickled into a file named after the current date+time (maybe also
revision number?) ... The key should also be something useful, e.g. a
3-tuple consisting of the relative path and name to the file, the line
number and the string literal of the exectued line.
Based on that it should be straightforward to write some code that
analyzes execution time regressions.



+1 to the idea of a timeit decorator, which would be useful for
microbenchmarking. I think timing whole blocks would be useful as well
to make sure there's no macro regressions. Though any one datapoint
isn't as useful, if everyone was consistently getting a slowdown for a
given doctest, that would be an indicator that something is going on.

- 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
URL: http://www.sagemath.org


Re: [sage-devel] About mpmath and sympy

2010-07-19 Thread Tim Daly



Paulo César Pereira de Andrade wrote:

2010/7/17 François Bissey f.r.bis...@massey.ac.nz:
  

As an aside, if two upstream packages include another upstream
package (e.g. both include GMP) what does Sage do? Are there
two copies of GMP? They could have different versions of the
same package since project 1 could have stopped at one version
and project 2 could have stopped at another. Sage could be
using a third.
  

Funny you mentioned GMP. At one point givaro was shipping its own
GMP. It was actually an accident on the givaro devs part - and I had
notified them. But I didn't notify this list. So in at least one release
givaro was actually overwriting part of GMP.



  I think there may be still duplicates somewhere, not just GMP, but
probably don't affect sage because either sage doesn't build it by
default, e.g. gap optional modules, or sage talks to it using the
pexpect interface.

  

For your question I guess it depends if it is kept internally without
clash with anything else or it actively tries to overwrite things that
have been installed already.
The second one is a no-no, and the first one should be fixed to use upstream
but not as a matter of emergency I would guess.



  If it is linked statically, and provides only an opaque interface,
usually it should just work, but that may depend on how the duplicates
access external resources, like files, kernel interface, etc. Problems
can get serious on shared objects when there are name clashes
(I remember when I tried LD_PRELOAD=libpolybori.so and discovered that
it builds stubs to several libc calls if UNIX is not defined, and it
is not in Linux).

  About Tim Daly comment that I think may be related to axiom :-) The
axiom package was broken for quite some time in Mandriva. My first
work on it I got it to work with system gmp,
but need several gcl patches. When someone else in Mandriva updated to
gmp 5, I rebuilt axiom using its internal copy of gmp3 (I am using git
axiom). In case you want to check it:
http://svn.mandriva.com/cgi-bin/viewvc.cgi/packages/cooker/axiom/
  

Axiom for mandriva is at the usual download site. I was curious how Sage was
planning to handle the multiple-version problem. If you look at the way 
software
can be layered you find that each layer tries to reduce errors by 
including the

upstream software. So MPIR is included in the distro for some packages but
each package usually has its own version.

Axiom only depends on two packages (GCL and noweb (noweb is going away))
but including Axiom under Sage will end up including gmp since that is 
included in

GCL. Including Axiom under Sage also includes a lisp but Maxima in Sage uses
ECL these days so there would be two complete lisps. Maxima can build on 
GCL.


Would it be reasonable for Sage to establish fundamental spkgs (like gmp)
which were used by all of the spkgs? I think Sage could play the role of a
normalizing force, suggesting that upstream packages use the same distros.
This would be similar to the (decades-old) push to use standard system
libraries. There was a day when everyone included their own copy of printf
in every program. Maybe it is time for a new spkg substrate push, at least
in the computer algebra community.

  

Francois



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
URL: http://www.sagemath.org


Re: [sage-devel] About mpmath and sympy

2010-07-16 Thread Tim Daly

As an aside, if two upstream packages include another upstream
package (e.g. both include GMP) what does Sage do? Are there
two copies of GMP? They could have different versions of the
same package since project 1 could have stopped at one version
and project 2 could have stopped at another. Sage could be
using a third.

François Bissey wrote:

  Hi,

  Newer sympy has a bundled copy of mpmath, what causes several
problems in my sagemath package. I was in vacation during most of
Mandriva 2010.1 freeze, and did not fully test the package for some
time, but I am working on an update for it; basically an 's/import
mpmath/import sympy.mpmath as mpmath/', but would like to know what
would be the better approach. (just letting the code use both leads to
SEGvs).

  The new sagemath package will conflict with
python-mpmath-0.14-1mdv2010.1 (forcing it to be uninstalled), because
the sympy is python-sympy-0.6.7-1mdv2010.1.



Hi Paulo,

that will probably be a pain for us in gentoo as well. 
At the moment we are sticking with sympy-0.6.6 as 
sympy-0.6.7 gives us trouble. The gentoo philosophy

at this point will be to remove mpmath from sympy and
make it a requirement. But I haven't been actively working
on that.

Francois

  


--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Vote on making GNU patch a standard package

2010-07-01 Thread Tim Daly

It is officially none of my business what you decide.
However, given that developers are the only people likely
to know how to create and post a diff-Naur patch file and
developers are likely able to install tools and 'patch' is
a well-known, widely used, and standard tool ...

does it make sense to have your own copy?


Adam Webb wrote:

 [Yes] Include GNU patch as a standard package in Sage

Sounds good to me.

Adam

  


--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Patches overwriting patches in singular

2010-06-29 Thread Tim Daly

I'm surprised you don't use patch.
Mercurial can generate patches.

François Bissey wrote:

On Jun 29, 4:13 pm, François Bissey f.r.bis...@massey.ac.nz wrote:


sage doesn't assume that the patch command is installed but rely on cp
being there. That's why patch aren't used.
I agree not ideal but that's a lowest common denominator issue.
  

Perhaps compare the md5sum of the original and bail if it's not the
expected number? Any time a file changes, the file we replace it with
in the spkg-install should probably change as well. Do our
prerequisites include some checksumming or hashing utility?

that's an interesting idea. On the linux side usually distro do checksums 
on packages so it has to be a part of the base system if you want to update.

It's probably the case on most other platform in one way or another.
That wouldn't have taken care of Dave's original problem in any case,
which was double copying the same file. Which I stupidly parroted in Gentoo.

Francois

  


--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Patches overwriting patches in singular

2010-06-29 Thread Tim Daly

Perhaps I'm being thick about this. In Axiom's build
we have a zip file for GCL source code. At build time
we unzip the GCL source, THEN apply our patches, THEN
we do a build.

Why wouldn't this process work in Sage?

Sage requires all of GCC to be installed.
Surely requiring patch is not a lot more overhead.
In the worst case, add the source for patch and build
your own copy early in the build process.

Sending/posting/trading diff -Naur patches is a long
standing tradition in open source. Sage is the only
project I've ever heard of that doesn't use them.

Mike Hansen wrote:

On Tue, Jun 29, 2010 at 4:54 PM, Tim Daly d...@axiom-developer.org wrote:
  

I'm surprised you don't use patch.
Mercurial can generate patches.



The issue is not generating the patches -- it's applying them.  All of
the spkgs (should) have the diff as well as the file with the patch
applied.

--Mike

  


--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Patches overwriting patches in singular

2010-06-29 Thread Tim Daly

We use a naming convention for patches.
Thus the 3rd new patch created today by me would have the name:

20100629.03.tpd.patch

which orders the patches by date, sub-sequence, and author.
You might want to use your spkg name instead as in:

20100629.03.singular.patch

This would ensure that patches are unique.

Mike Hansen wrote:

On Tue, Jun 29, 2010 at 5:57 PM, Dr. David Kirkby
david.kir...@onetel.net wrote:
  

But if there are two three files

src/foo.c
patches/foo.c
patches/foo.c.diff

what does patches/foo.c.diff possibly give me that could could get by
running

diff src/foo.c patches/foo.c ?



This requires that patches/foo.c was made from src/foo.c.  This is the
case for the current version, but if you look at a previous version of
patches/foo.c in the repository, you have to go out and get the
corresponding src/foo.c from the internet in order to see what the
change actually was.

--Mike

  


--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: Is 'flex' needed to build Sage?

2010-06-06 Thread Tim Daly

I'm sure Singular has a process to fix the problems you mention.
All you have to do is send a 'diff -Naur' patch that improves the build.

You got hundreds of megabytes of code for free and you're complaining
because the install script isn't written the way you advocate?

Advocacy is volunteering.

Send them a thank-you note for all the free code and include a patch file.

Tim

Open source... now it's YOUR problem to solve -- daly

Dr. David Kirkby wrote:

On 06/ 6/10 11:48 PM, François Bissey wrote:


yes singular is a downright mess, upstream and in sage.


I'm glad I'm not alone in my view.


Apart from moving to the latest upstream I think the singular spkg
is due for a spring clean. It build an enormous amount of targets
in a way that looks like a very careful choreography and apart
from libsingular and the singular binary there is no indication
sage uses any of the other stuff built.


It does take a long time to build compared to most other packages, 
which is probably due to the fact the package is large and so has a 
lot of source code.


If a lot of the targets are unnecessary, then I suspect the build time 
could be reduced. It took 40 minutes on my old 900 MHz SPARC, though I 
could probably reduce that if targets can be built in parallel. But 
even then, it is still going to be quite lengthy.


I have just read William's opinion and it may be true that is 
generally easy
to build. But reproducing the set up used in the sage spkg from a 
packaging

point of view is quite difficult.



Francois



Dave



--
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
URL: http://www.sagemath.org


Re: [sage-devel] new paper on sage by myself and Burcin Erocal

2010-06-03 Thread Tim Daly

I was commenting on the version of Axiom shown in your note. :-)

Axiom prints a banner on startup containing 2 pieces of information.
The second line is the release version of the system (September 2005)
The third line is the date this version was built (December 2006)

That's quite amusing given the Sage discussion about release schedules
and user-update frequency. The latest version of Axiom is May 2010.

  AXIOM Computer Algebra System

Version: Axiom 3.9 (September 2005)
 Timestamp: Saturday December 2, 2006 at 09:30:31





William Stein wrote:

On Wed, Jun 2, 2010 at 6:10 AM, Tim Daly d...@axiom-developer.org wrote:
  

You have Axiom from 2005?
You do realize it is updated every 2 months :-)

Tim



Huh?  I can't figure out what you're referring to above.

William

  

William Stein wrote:


On Tue, Jun 1, 2010 at 11:31 PM, Martin Rubey
martin.ru...@math.uni-hannover.de wrote:

  

William Stein wst...@gmail.com writes:




Hi,

Burcin Erocal and I wrote a paper

The Sage Project: Unifying Free Mathematical Software to Create a
Viable Alternative to Magma, Maple, Mathematica and Matlab

for http://www.math.kobe-u.ac.jp/icms2010/index.html

Here it is:

 http://wstein.org/papers/icms/icms_2010.pdf

  

A tiny correction to the list on 6, Table 2: as far as I know, sage does
not communicate with axiom, but rather with fricas.  But I admit, I am
not 100% certain, what the default installation does.  Please correct
me, if I'm mistaken.

Martin



Thanks for raising this point.  I remember Tim Daly complaining at
some point that I should rename the axiom command in sage to
fricas.  So this is worth looking into, which I just did. The result
is that the Sage interface called axiom really is an interface to
Axiom, as claimed.


I think the Sage interface that is called axiom does in fact work
fine with Axiom.   On my computer, I don't have fricas installed, but
I do have axiom:

wst...@sage:~$ which fricas
wst...@sage:~$ which axiom
/usr/bin/axiom

This is the read-deal axiom, from Debian I think:

wst...@sage:~$ axiom
GCL (GNU Common Lisp)  2.6.7 CLtL1Nov 10 2006 14:25:02
Source License: LGPL(gcl,gmp), GPL(unexec,bfd,xgcl)
Binary License:  GPL due to GPL'ed components: (XGCL READLINE BFD UNEXEC)
Modifications of this banner must retain notice of a compatible license
Dedicated to the memory of W. Schelter

Use (help) to get some basic information on how to use GCL.
Temporary directory for compiler files set to /tmp/
   AXIOM Computer Algebra System
Version: Axiom 3.9 (September 2005)
 Timestamp: Saturday December 2, 2006 at 09:30:31

-
  Issue )copyright to view copyright notices.
  Issue )summary for a summary of useful system commands.
  Issue )quit to leave AXIOM and return to shell.

-

  Re-reading compress.daase   Re-reading interp.daase
  Re-reading operation.daase
  Re-reading category.daase
  Re-reading browse.daase
(1) - )quit


Now I run Sage, and verify that it doesn't know about any fricas
command, only Axiom, which is the systemwide genuine axiom:

wst...@sage:~$ sage
--
| Sage Version 4.4.1, Release Date: 2010-05-02   |
| Type notebook() for the GUI, and license() for information.|
--
sage: !which axiom
/usr/bin/axiom
sage: !which fricas

And now I run a command, which calls Axiom:

sage: axiom('2 + 3')
5

Consulting the source shows that the command that Sage runs when the
axiom interface is invoked is axiom -nox -noclef:

sage: axiom.__init__??
...
Source:
   def __init__(self, name='axiom', command='axiom -nox -noclef',
script_subdirectory=None, logfile=None,
server=None, server_tmpdir=None,
init_code=[')lisp (si::readline-off)']):



See http://trac.sagemath.org/sage_trac/ticket/5111

There is a *separate* fricas interface:

sage: fricas.__init__??
Definition: fricas.__init__(self, name='fricas', command='fricas
-nox -noclef', script_subdirectory=None, logfile=None, server=None,
server_tmpdir=None, init_code=[')lisp (si::readline-off)'])
Source:
   def __init__(self, name='fricas', command='fricas -nox -noclef',



The upshot is that maybe I should list both fricas and axiom in the
interfaces table?

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
URL: http://www.sagemath.org






  


--
To post to this group, send an email to sage-devel@googlegroups.com

Re: [sage-devel] new paper on sage by myself and Burcin Erocal

2010-06-02 Thread Tim Daly

You have Axiom from 2005?
You do realize it is updated every 2 months :-)

Tim


William Stein wrote:

On Tue, Jun 1, 2010 at 11:31 PM, Martin Rubey
martin.ru...@math.uni-hannover.de wrote:
  

William Stein wst...@gmail.com writes:



Hi,

Burcin Erocal and I wrote a paper

The Sage Project: Unifying Free Mathematical Software to Create a
Viable Alternative to Magma, Maple, Mathematica and Matlab

for http://www.math.kobe-u.ac.jp/icms2010/index.html

Here it is:

  http://wstein.org/papers/icms/icms_2010.pdf
  

A tiny correction to the list on 6, Table 2: as far as I know, sage does
not communicate with axiom, but rather with fricas.  But I admit, I am
not 100% certain, what the default installation does.  Please correct
me, if I'm mistaken.

Martin



Thanks for raising this point.  I remember Tim Daly complaining at
some point that I should rename the axiom command in sage to
fricas.  So this is worth looking into, which I just did. The result
is that the Sage interface called axiom really is an interface to
Axiom, as claimed.


I think the Sage interface that is called axiom does in fact work
fine with Axiom.   On my computer, I don't have fricas installed, but
I do have axiom:

wst...@sage:~$ which fricas
wst...@sage:~$ which axiom
/usr/bin/axiom

This is the read-deal axiom, from Debian I think:

wst...@sage:~$ axiom
GCL (GNU Common Lisp)  2.6.7 CLtL1Nov 10 2006 14:25:02
Source License: LGPL(gcl,gmp), GPL(unexec,bfd,xgcl)
Binary License:  GPL due to GPL'ed components: (XGCL READLINE BFD UNEXEC)
Modifications of this banner must retain notice of a compatible license
Dedicated to the memory of W. Schelter

Use (help) to get some basic information on how to use GCL.
Temporary directory for compiler files set to /tmp/
AXIOM Computer Algebra System
 Version: Axiom 3.9 (September 2005)
  Timestamp: Saturday December 2, 2006 at 09:30:31
-
   Issue )copyright to view copyright notices.
   Issue )summary for a summary of useful system commands.
   Issue )quit to leave AXIOM and return to shell.
-

   Re-reading compress.daase   Re-reading interp.daase
   Re-reading operation.daase
   Re-reading category.daase
   Re-reading browse.daase
(1) - )quit


Now I run Sage, and verify that it doesn't know about any fricas
command, only Axiom, which is the systemwide genuine axiom:

wst...@sage:~$ sage
--
| Sage Version 4.4.1, Release Date: 2010-05-02   |
| Type notebook() for the GUI, and license() for information.|
--
sage: !which axiom
/usr/bin/axiom
sage: !which fricas

And now I run a command, which calls Axiom:

sage: axiom('2 + 3')
5

Consulting the source shows that the command that Sage runs when the
axiom interface is invoked is axiom -nox -noclef:

sage: axiom.__init__??
...
Source:
def __init__(self, name='axiom', command='axiom -nox -noclef',
 script_subdirectory=None, logfile=None,
 server=None, server_tmpdir=None,
 init_code=[')lisp (si::readline-off)']):



See http://trac.sagemath.org/sage_trac/ticket/5111

There is a *separate* fricas interface:

sage: fricas.__init__??
Definition: fricas.__init__(self, name='fricas', command='fricas
-nox -noclef', script_subdirectory=None, logfile=None, server=None,
server_tmpdir=None, init_code=[')lisp (si::readline-off)'])
Source:
def __init__(self, name='fricas', command='fricas -nox -noclef',



The upshot is that maybe I should list both fricas and axiom in the
interfaces table?

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
URL: http://www.sagemath.org


Re: [sage-devel] Re: What's the point of two stable releases in two days?

2010-05-26 Thread Tim Daly

The Axiom project had a long debate about releases
and version numbers which I see is about to happen here.

Axiom decided that a reasonable balance was to make 2 decisions,
one about releases and one about versions.

RELEASES

There is a choice between releasing often and releasing,
say, yearly. Sage releases about every week or two at the
moment. The upside of this strategy is that people get the
latest version immediately. The downside of this strategy
is that people are ALWAYS in update mode and big changes
are very hard to manage in a small window (2 days?)

First, there would be a silver and a gold releases. The
silver version is updated continuously and available from
most of the sites with a git pull or git clone. The gold
release would be a time-boxed release every 2 months.

This gives people who care about a particular change a way to
get the latest release immediately. It allows others who just
want the system, a way to update at a more reasonable pace,
maximally, every 2 months. The gold release is maintained
on github, the silver is on all other sites.

VERSIONS

Version numbers get religious really fast and the debate is
not very productive. Essentially, a single number is not
sufficient to carry all of the information about what might
have changed, especially if you have a component system.

Since git maintains a 40-digit SHA1 hash for every commit
it is sufficient for a version number. Any reference to a
single hash number gives all of the required information.
This is sufficient for silver releases.

Since the time-boxed gold releases are 2 months apart it
is sufficient to use the form May 2010 as the unique
release number. This is easy to distinguish from March 2010.

I'm sure that the Sage list will find this method not right
for a variety of reasons but I can tell you that there is no
perfect solution. The Axiom debate raged on for about a year.
Time-boxing isn't perfect but it allows big changes to
occur without breaking everyone and little changes to occur
without annoying everyone.

Every project seems to have this debate. Good luck with it.

Tim Daly


kcrisman wrote:

On May 26, 3:56 pm, William Stein wst...@gmail.com wrote:
  

On Wed, May 26, 2010 at 12:50 PM, Dr. David Kirkby





david.kir...@onetel.net wrote:


On 05/26/10 05:34 PM, leif wrote:
  

On 26 Mai, 18:09, Robert Bradshawrober...@math.washington.edu


I like the risk assessment field idea.
  

Me too, perhaps give it a different name.


What would you call it? There are at least three things to consider I can
think of.
  
1) What are the risks associated with a change?
  
2) The probability of the change causing a problem.
  
3) The impact such a problem would cause.
  
There might be others.
  
Even things that have a fairly high probability of causing a problem are

probably not worth worrying about too much if the impact would be minimal.
  
Conversely, even something which has a low probability of causing a problem,

but would have major consequences, needs to be taken seriously.
  
However, unless there was a *major* change in Sage release practices, it

would be a bit pointless doing any sort of risk analysis. I don't detect
much of an appetite for a major change in Sage release practices. In fact, I
detect quite the converse.
  

At a bare minimum, any major change should be designed by people who
have actually done some Sage releases.




Wouldn't it be easiest for someone to change the 5.0 release date
thingie on Trac to sometime in June, but may be pushed to July or
later in order to fulfill goals (Cygwin, etc.)?  This seems like even
more of a tempest in a teapot than the SPKG.txt thread ;)

- 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
URL: http://www.sagemath.org


Re: [sage-devel] Re: What's the point of two stable releases in two days?

2010-05-26 Thread Tim Daly



William Stein wrote:

On Wed, May 26, 2010 at 3:08 PM, Tim Daly d...@axiom-developer.org wrote:
  

The Axiom project had a long debate about releases
and version numbers which I see is about to happen here.

Axiom decided that a reasonable balance was to make 2 decisions,
one about releases and one about versions.

RELEASES

There is a choice between releasing often and releasing,
say, yearly. Sage releases about every week or two at the
moment. The upside of this strategy is that people get the
latest version immediately. The downside of this strategy
is that people are ALWAYS in update mode and big changes
are very hard to manage in a small window (2 days?)

First, there would be a silver and a gold releases. The
silver version is updated continuously and available from
most of the sites with a git pull or git clone. The gold
release would be a time-boxed release every 2 months.

This gives people who care about a particular change a way to
get the latest release immediately. It allows others who just
want the system, a way to update at a more reasonable pace,
maximally, every 2 months. The gold release is maintained
on github, the silver is on all other sites.

VERSIONS

Version numbers get religious really fast and the debate is
not very productive. Essentially, a single number is not
sufficient to carry all of the information about what might
have changed, especially if you have a component system.

Since git maintains a 40-digit SHA1 hash for every commit
it is sufficient for a version number. Any reference to a
single hash number gives all of the required information.
This is sufficient for silver releases.

Since the time-boxed gold releases are 2 months apart it
is sufficient to use the form May 2010 as the unique
release number. This is easy to distinguish from March 2010.

I'm sure that the Sage list will find this method not right
for a variety of reasons but I can tell you that there is no
perfect solution. The Axiom debate raged on for about a year.
Time-boxing isn't perfect but it allows big changes to
occur without breaking everyone and little changes to occur
without annoying everyone.

Every project seems to have this debate. Good luck with it.



Thanks for sharing the above.

1. How do you think your choice of releases and version numbers
impacted the number of Axiom users?  Developers?
  

I have no way to track the number of users so I can't say.

Axiom forked (twice) and the forks have their own version numbering schemes,
each one different and neither one is clear, at least to me.

Developers will track whatever scheme you use and they won't like it :-)

It is very difficult to introduce large changes to the system if the 
updates are too

frequent. I'm introducing a new package that includes over 50 new pieces of
algebra in this next release. The developer silver version has seen 
each new
piece of algebra as it was introduced, with updates happening several 
times a

day all month long but each new piece is useless standalone.
The gold version will have a fully implemented and tested piece so users
won't see the intermediate states.

At the rate you are currently releasing I don't know how you can introduce
fundamental changes like a reorganization of the categories. If there is 
a mistake
the whole user community gets hit. And if it takes a couple weeks to 
debug then
you'll have the world at your throat. The silver releases give your 
developers
a chance to play before it goes out to the general public. I make NO 
guarantees
about silver releases. They might not even build (although breaking the 
build

is on my list of major sins).

If you succeed wildly then you'll have thousands of universities 
downloading
versions, students will each have a different version depending on the 
day of

the week they decided to download.  A gold version would give professors
something concrete to point at e.g. the September 2010 version.



2. Now that you've had the above version/release schedule for a few
years, is there anything you would change?

  

Well you'd be amazed at how quickly 8 weeks goes by

The pace of 8 weeks between releases leaves  7 weeks of work and a week of
deep test, binary builds, etc. Fedora always seems to break things on every
release so it just takes a lot of time. I see you have the same breakage 
happening

on certain platforms. It is very frustrating.

Having done the silver/gold release mechanism for about 4 years now I 
think it is
just about right. It gives lots of pressure to hit the timebox but 
enough time

to plan for a major change.

Timeboxing also allows estimates of when to stop adding new features (a 
freeze)
and start cleaning up the little details. This subtle side-effect forces 
fixing the little
annoying things that nobody notices but make it cleaner and more 
professional.




3. How did your debate about the above end?  Was their some definitive
argument, or?
  
Originally the development was released every 2 months

Re: [sage-devel] A function to compute Bezout coefficients ?

2010-05-25 Thread Tim Daly

Is anyone else getting duplicate copies of Sage messages? -- Tim

Mike Hansen wrote:

Hello,

  

I've been looking for a function that allows one to compute Bezout
coefficients of two numbers (say natural numbers). There is the GCD
function, but I haven't found anything about Bezout coefficients. This
is not complicated to write one, but it would be better if it was
included somehwere in Sage. Is there already something like that ?



You should use xgcd:

sage: xgcd(5, 7)
(1, 3, -2)
sage: g,a,b = xgcd(5, 7)
sage: a*5 + b*7
1

--Mike

  


--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: icc

2010-05-23 Thread Tim Daly

how about using:

find . -name *.pyx -exec touch {} \;



William A. Stein wrote:

On May 23, 2010, at 1:12 PM, leif wrote:

  

On 23 Mai, 21:40, Dr. David Kirkby david.kir...@onetel.net wrote:


'lcalc' had a particularly annoying attempt to cover up warnings from the
assembler, as it actually caused the build to break on Solaris, as the option to
cover up the warnings was passed directly to the Sun assembler, but it did not
accept the option.
  

They seem to think gcc (the compiler driver) will be smart enough to
know all options passed to any component of the tool chain, even if
passed verbatim ;-)



IMHO, the quality of the coding in Sage leaves a lot to be desired in places.
  

One of my current favorites is a snippet from sage-build:

  cd $SAGE_ROOT/devel/sage/sage
  echo *** TOUCHING ALL CYTHON (.pyx) FILES ***
  touch */*.pyx */*/*.pyx */*/*/*.pyx */*/*/*/*.pyx */*/*/*/*/*.pyx */
*/*/*/*/*.pyx  */*/*/*/*/*/*.pyx 2 /dev/null

Reminds me of M$-DOS, where the shell did not expand wildcards. (If
you have fun, count the asterisks...)

-Leif



Instead of keeping this as a favorite, implement a better version, and post a 
patch.

 -- 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
URL: http://www.sagemath.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
URL: http://www.sagemath.org


Re: [sage-devel] Re: numerically stable fast univariate polynomial multiplication over RR[x]

2010-05-03 Thread Tim Daly



Bill Hart wrote:

That's actually a very interesting paper. I've recently been playing
with Forth, which is a kind of Lisp type language (yeah I know you
won't agree with that), based on a data stack. I also worked through a
book on Lisp up to the point where macros were defined, as I wanted to
understand how that was handled in Lisp. I actually get Lisp now,
but it was a round about way that I got there. It's clearly not for
everyone.

I've also been experimenting with how short programs can be that still
give reasonable performance. The answer is, amazingly short, if one
spends a lot of time thinking about it before coding.

Another thing I've been enjoying lately is literate programming.
Amazingly it turns out to be faster to write a literate program than
an ordinary program because debugging takes almost no time.
  
Can I quote you on that in the Axiom system (which is moving toward 
being fully literate)?

Anyhow, I'm going to read this paper of yours now.

Bill.

On May 3, 3:37 pm, rjf fate...@gmail.com wrote:
  

If you are not doing floating point arithmetic with machine
arithmetic, but using MPFR, then you are sacrificing a huge amount of
time.  You might as well be using rational arithmetic, or the kind of
arithmetic that Collins once proposed, where the denominator is a
power of 2.  Makes reducing to lowest terms relatively fast because
the
GCD is trivial.  Compare that to boosting the overall precision in
MPFR to big enough.

If you want to read more about multiplying polynomials, you can read
the (unpublished, unfinished, too-long) paper here:

www.cs.berkeley.edu/~fateman/papers/shortprog.tex

RJF

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


Re: [sage-devel] Re: numerically stable fast univariate polynomial multiplication over RR[x]

2010-05-03 Thread Tim Daly

I have also found that it has the side-effect you mention.
It makes debugging easier, if it is needed at all.
Hopefully this will also be true of the person who ends up
maintaining our code after we're gone.

Thanks for the permission. Your quote appears on the
documentation page of the axiom website (which I won't
link here)

Tim

Bill Hart wrote:

Ah you arrived right on cue. LOL!

Ha ha, you can quote me if you want, but I have written a couple of
literate programs in my life, so I'm hardly an expert.

But I was surprised at how much difference it made to the debugging
time.

Bill.

On May 3, 10:04 pm, Tim Daly d...@axiom-developer.org wrote:
  

Bill Hart wrote:


That's actually a very interesting paper. I've recently been playing
with Forth, which is a kind of Lisp type language (yeah I know you
won't agree with that), based on a data stack. I also worked through a
book on Lisp up to the point where macros were defined, as I wanted to
understand how that was handled in Lisp. I actually get Lisp now,
but it was a round about way that I got there. It's clearly not for
everyone.
  
I've also been experimenting with how short programs can be that still

give reasonable performance. The answer is, amazingly short, if one
spends a lot of time thinking about it before coding.
  
Another thing I've been enjoying lately is literate programming.

Amazingly it turns out to be faster to write a literate program than
an ordinary program because debugging takes almost no time.
  

Can I quote you on that in the Axiom system (which is moving toward
being fully literate)?







Anyhow, I'm going to read this paper of yours now.
  
Bill.
  
On May 3, 3:37 pm, rjf fate...@gmail.com wrote:
  

If you are not doing floating point arithmetic with machine
arithmetic, but using MPFR, then you are sacrificing a huge amount of
time.  You might as well be using rational arithmetic, or the kind of
arithmetic that Collins once proposed, where the denominator is a
power of 2.  Makes reducing to lowest terms relatively fast because
the
GCD is trivial.  Compare that to boosting the overall precision in
MPFR to big enough.

If you want to read more about multiplying polynomials, you can read

the (unpublished, unfinished, too-long) paper here:

www.cs.berkeley.edu/~fateman/papers/shortprog.tex

RJF

--

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


Re: [sage-devel] Re: Fwd: numerically stable fast univariate polynomial multiplication over RR[x]

2010-04-27 Thread Tim Daly



Bill Hart wrote:

On Apr 27, 8:55 pm, rjf fate...@gmail.com wrote:
  

Oh, just another note.

There are people who have made their whole careers on devising
asymptotically fast algorithms
which have never been implemented, or (if they have been implemented)
are not fast because
their overly-simplified analysis does not fit the currently available
computer efficiency profile.
Indeed, their analysis may not fit any past profile of computers, and
their algorithms were never
practical.



Interesting observation. Furer's algorithm is not practical, as are
some matrix multiplication algorithms. Do you have any other examples
in mind?

  

Note, for example, that memory access is far more expensive than
arithmetic, and that
many computers now can multiply or add in comparable time; and they
have several multipliers. Etc.



I would say that memory access if far more expensive than addition,
but not arithmetic in general. FFT multiplication is n log n
(sometimes with a log log n, depending on what you are multiplying)
and I would say the memory access perhaps adds a hidden log n factor.

Can you perhaps be more specific as to what you are hinting at?
  
On current microprocessors a multiply can be done in a few clock ticks 
(probably one
apparent clock tick if the in-processor pipelines are fully overlapped). 
An L1 cache access
is about 3 clock ticks, an L2 can be dozens, and a memory access can be 
several hundred
or more (depending on DDR/2/3/..., inter-processor MESI cache, prefetch 
instructions, etc.)


By analogy, it is more expensive to peel an egg than to slice a carrot 
but the time is buried
under the time it takes to get one out of the fridge (L1), the 
supermarket (L2), the farm

(main memory) or grow a new one (disk).

So if an FFT that is optimized for, say 128 byte cache lines with 
minimal cache collisions,
then the multiply times will matter. But changing the FFT to ignore 
cache line sizes so the
fetch breaks a cache line on each read and the multiply times are 
completely irrelevant.
  

RJF

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


Re: [sage-devel] Sage and Amazon EC2?

2010-04-16 Thread Tim Daly

I haven't used Sage on EC2 but I have done Axiom builds there
(about a 1.5 hour compile/test). Its simple to configure a machine.
They have hundreds of prebuilt instances. I used an ubuntu instance,
ssh'ed to it, added a few packages, did a build and test.
Worked as expected with no problems.

If you're used to working on linux nothing should come as a surprise.

Tim Daly


Dan Drake wrote:

The current thread about using the notebook server with classes of
students made me think about the possibility of using Amazon EC2
instances to do the computing for a notebook server.

I haven't used EC2 and don't know too much about it, but the idea seem
to be that you can spin up a web-accessible virtual machine very easily
-- it seems to be about as hard as creating a Google group. You pay for
the VM by the hour.

The notebook server does its computing by ssh'ing to an account and
running Sage there. Imagine you provision a bunch of EC2 machines with a
copy of Sage, and point the notebook server to those machines. If your
notebook server needs more power, you just make some more EC2 machines.
You only pay for what you use, so this seems like it could be a very
effective and efficient way to run a heavily-used notebook server.

I looked up prices, and it looks like about 17 cents an hour for a CPU
intensive instance. If 20 students each used a notebook server and each
accessed their own instance, that's $3.40 for each class hour. For a
45-hour semester-long class, that's roughly $150, which seems pretty
cheap. (Consider that for some classes, a single *textbook* is $150.)

Has anyone experimented with using EC2 and Sage? It seems like an
interesting possibility.

Dan

--
---  Dan Drake
-  http://mathsci.kaist.ac.kr/~drake
---
  


--
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: code review tools

2010-04-14 Thread Tim Daly

Speaking of that, why not institute a program committee
where people volunteer to do reviews before your Sage days?
I do a lot of program committee work, which is painful but
is a professional giving back to the community task. It
is always done against a deadline which is a great motivation.

Tim Daly

Jason Grout wrote:

On 04/14/2010 03:04 PM, William Stein wrote:
On Wed, Apr 14, 2010 at 12:43 PM, John 
Cremonajohn.crem...@gmail.com  wrote:

I have been strongly encouraging new students starting out with Sage
to make small (initially) patches  on their very own ticket, so that
they can feel good when these get reviewed positively and then merged.
  But those same people might take quite a while longer before they
feel confident about reviewing others people's tickets.

It's usually a long time after one has started submitting papers for
publication that one starts to get requests for refereeing other
papers -- not that long, but a while.  Isn't that similar?



Yes.  The main intent of what I'm suggesting is that people who are
contributing a *lot* of code, but not doing any reviewing, will be
very, very strongly encouraged to do more reviewing.




Maybe a more balanced system would address the concerns.  You get a 
little karma for posting a patch, a little more karma for posting a 
patch on a ticket with someone else's patch (because you're probably 
sort of reviewing their code as you make your patch), and a lot more 
karma for reviewing a ticket.  You'd get a first-time bonus karma 
for posting your first patch.


Of course, this also might make it more complicated than it is worth.


Jason



--
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
URL: http://www.sagemath.org

To unsubscribe, reply using remove me as the subject.


Re: [sage-devel] Randomised testing against Mathematica

2010-03-03 Thread Tim Daly

There are two test suites with validated results at
http://axiom-developer.org/axiom-website/CATS/

The CATS (Computer Algebra Test Suite) effort targets
the development of known-good answers that get run
against several systems. These end result suites test
large portions of the system. As they are tested against
published results they can be used by all systems.

The integration suite found several bugs in the published
results which are noted in the suite. It also found a bug
introduced by an improper patch to Axiom.

It would be generally useful if Sage developed known-good
test suites in other areas, say infinite sequences and series.
Perhaps such a suite would make a good GSOC effort with
several moderators from different systems.

I have done some more work toward a trigonometric test
suite. So far I have found that Mathematica and Maxima
tend to agree on branch cuts and Axiom and Maple tend
to agree on branch cuts. The choice is arbitrary but
it affects answers. I am having an internal debate about
whether to choose MMA/Maxima compatible answers just to
regularize the expected results users will see.

Standardized test suites give our users confidence that
we are generating known-good results for some (small)
range of expected inputs.

An academic-based effort (which Axiom is not) could
approach NIST for funding an effort to develop such
suites. NIST has a website (http://dlmf.nist.gov/)
Digital Library of Mathematical Functions. I proposed
developing Computer Algebra test suites for their
website but NIST does not fund independent open source
projects. Sage, however, could probably get continuous
funding to develop such suites which would benefit all
of the existing CAS efforts.

NSF might also be convinced since such test suites raise
the level of expected quality of answers without directly
competing against commercial efforts. I'd like to see a
CAS testing research lab that published standardized
answers to a lot of things we all end up debating, such
as branch cuts, sqrt-of-squares, foo^0, etc.

Tim Daly


Dr. David Kirkby wrote:

Joshua Herman wrote:

Is there a mathematica test suite we could adapt or a standardized set
of tests we could use? Maybe we could take the 100 most often used
functions and make a test suite?


I'm not aware of one. A Google found very little of any real use.

I'm sure Wolfram Research have such test suites internally, but they 
are not public. There is discussion of how they have an internal 
version of Mathematica which runs very slowly, but tests things in 
greater detail.


http://reference.wolfram.com/mathematica/tutorial/TestingAndVerification.html 



Of course, comparing 100 things is useful, but comparing millions of 
them in the way I propose would more likely show up problems.


I think we are all aware that it is best to test on the hardware you 
are using to be as confident as possible that the results are right.


Of course, Wolfram Research could supply a test suite to check 
Mathematica on an end user's computer, but they do not do that. They 
could even encrypt it, so users did not know what was wrong, but could 
at least alert Wolfram Research.


I'm aware of one bug in Mathematica that only affected old/slower 
SPARC machines if Solaris was updated to Solaris 10. I suspect it 
would have affected newer machines too, had they been heavily loaded. 
(If I was sufficiently motivated, I would probably prove that, but I'm 
not, so my hypothesis is unproven).


It did not produce incorrect results, but pegged the CPU at 100% 
forever if you computed something as simple as 1+1.) It was amazing 
how that was solved between myself, Casper Dik a kernel engineer at 
Sun and various other people on the Internet. It was Casper who 
finally nailed the problem, after I posted the output of lsof, he 
could see what Mathematica was doing.


I've got a collection of a few Mathematica bugs, mainly affecting only 
Solaris, although one affected at least one Linux distribution too.


http://www.g8wrb.org/mathematica/

One thing I know Mathematica does do, which Sage could do, is to 
automatically generate bug report if it finds a problem. At the most 
primitive level, that code might be


if (x  0)
  function_less()
else if (x == 0)
  function_equal()
else if (x  0)
  function_greater()
else
  function_error()

If the error is generated, a URL is given, which you click and can 
send a bug report to them. It lists the name of the file and line 
number which generated the error. That's something that could be done 
in Sage and might catch some bugs.



Dave


 LOOK ITS A SIGNATURE CLICK IF YOU DARE---
http://www.google.com/profiles/zitterbewegung




On Wed, Mar 3, 2010 at 12:04 AM, David Kirkby 
david.kir...@onetel.net wrote:
Has anyone ever considered randomised testing of Sage against 
Mathematica?


As long as the result is either

a) True or False
b) An integer

then comparison should be very easy. As a dead simple example,

1) Generate a large random number n

Re: [sage-devel] GPL issues again - trivial ones this time !!!

2010-02-09 Thread Tim Daly

Try sending a question to FSF. I'm sure they'd give you
an authoritative answer. Stallman has answered every
question I ever sent him.

Tim Daly

Tom Boothby wrote:

Context is important.  The GPL doesn't say that every GPL'd
interactive program must print a banner.  It says that if such a
banner is printed by a current GPL'd programs, then *if you distribute
a modified copy*, that copy must also print the banner.

The most ordinary manner of running Sage isn't running a modified
interactive GPL'd program.  Looks to me like the closest we've got is
iPython, which is BSD'd, so we don't need to print its banner.  And
the notebook is its own project, so it doesn't have to inherit
anybody's banner either.

  


--
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
URL: http://www.sagemath.org


Re: [sage-devel] A Challenge - what is wrong with this *simple* patch?

2010-01-14 Thread Tim Daly

Dr. David Kirkby wrote:
I submitted a patch which I believe is very simple and should not 
break anything, but it could not be merged into sage-4.3.1.rc0 because 
it breaks the Singular installation on Sage. (It was marked as fixed, 
then changed to 'needs work' as it fails.)


Can anyone spot what is wrong with it?

Here's the patch.
http://trac.sagemath.org/sage_trac/attachment/ticket/7898/singular-variables-to-names.patch 



heres the ticket.

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

Note sage-env has for a long time defined there, and that is 
unchanged. So why should that break.



if [ $RM =  ]; then
RM=rm   export RM
fi

if [ $LN =  ]; then
LN=ln   export LN
fi


if [ $CHMOD =  ]; then
CHMOD=chmod   export CHMOD
fi



Is this change in a Makefile?
Then the syntax is wrong. Try

${CHMOD}

because

$CHMOD is interpreted as $C

Tim

-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: doctest failures due to rounding errors on Solaris.

2009-12-31 Thread Tim Daly
Dr. David Kirkby wrote:
 rjf wrote:
   
 On Dec 31, 11:15 am, Dr. David Kirkby david.kir...@onetel.net
 wrote:

 
 RJF
 
 The point you are missing is that we want to compare the output what Sage 
 prints
 to a human.

   
 The point you are missing is that the following item, which presumably
 could be printed by Sage,
 is perfectly readable to a human:

 6121026514868073 * 2^(-51).

 It exactly dictates the bits in an IEEE double-float, and does not
 require any conversion from binary
 to decimal. It does not need rounding.  This kind of representation
 does not have any hidden unprinted digits.  It does not ever need to
 be longer because of delicate edge conditions of certain numbers.

 It happens to evaluate to
 APPROXIMATELY   2.718281828459045
 

 Sure, Sage could print that. It would also be worth printing the sign bit, so 
 we 
 could verify the values of

 1) Sign bit
 2) Significand
 3) Exponent.

 All of those could be correct. But there is still the software which does the 
 non-trivial task of converting that into the base 10 representation used by 
 humans. Then in additon to that, there is the software which takes a base 10 
 number, shows it with the Sage prompt, adding carriage returns etc where 
 necessary. All of these can go wrong.

 I would think in an almost ideal world, the test would be done at a higher 
 level, using hardware/software which checked what the monitor actually 
 displayed. That's not quite as easy to do though.

 Even better would be some way to scan the brain of the user to see what 
 he/she 
 believes Sage is showing. Perhaps we use a font that is not very good, so 
 despite being displayed properly, it misunderstood.

 Given most of time people want to see a base 10 representation of a number, 
 and 
 not a base 2, base 16 or IEE 754 representation, I believe most testing 
 should 
 be done at the base 10 level.

 If there is a reason for testing the IEEE 754 representation as first choice, 
 then you have yet to convince me of it.


 Dave


   
Dave,

Axiom has the same issues.

My take on this is that what you check depends on the reason you are 
checking.
If you are generating the output for human use (e.g. a table) then you 
want decimal.
If you are generating the output for regression testing (e.g. checking 
the answers on
multiple hardware) then you probably want Fateman's solution.

Tim


-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: doctest failures due to rounding errors on Solaris.

2009-12-31 Thread Tim Daly
William Stein wrote:
 On Thu, Dec 31, 2009 at 9:13 PM, Tim Daly d...@axiom-developer.org wrote:
   
 Dr. David Kirkby wrote:
 
 rjf wrote:

   
 On Dec 31, 11:15 am, Dr. David Kirkby david.kir...@onetel.net
 wrote:


 
 RJF

 
 The point you are missing is that we want to compare the output what Sage 
 prints
 to a human.


   
 The point you are missing is that the following item, which presumably
 could be printed by Sage,
 is perfectly readable to a human:

 6121026514868073 * 2^(-51).

 It exactly dictates the bits in an IEEE double-float, and does not
 require any conversion from binary
 to decimal. It does not need rounding.  This kind of representation
 does not have any hidden unprinted digits.  It does not ever need to
 be longer because of delicate edge conditions of certain numbers.

 It happens to evaluate to
 APPROXIMATELY   2.718281828459045

 
 Sure, Sage could print that. It would also be worth printing the sign bit, 
 so we
 could verify the values of

 1) Sign bit
 2) Significand
 3) Exponent.

 All of those could be correct. But there is still the software which does 
 the
 non-trivial task of converting that into the base 10 representation used by
 humans. Then in additon to that, there is the software which takes a base 10
 number, shows it with the Sage prompt, adding carriage returns etc where
 necessary. All of these can go wrong.

 I would think in an almost ideal world, the test would be done at a higher
 level, using hardware/software which checked what the monitor actually
 displayed. That's not quite as easy to do though.

 Even better would be some way to scan the brain of the user to see what 
 he/she
 believes Sage is showing. Perhaps we use a font that is not very good, so
 despite being displayed properly, it misunderstood.

 Given most of time people want to see a base 10 representation of a number, 
 and
 not a base 2, base 16 or IEE 754 representation, I believe most testing 
 should
 be done at the base 10 level.

 If there is a reason for testing the IEEE 754 representation as first 
 choice,
 then you have yet to convince me of it.


 Dave



   
 Dave,

 Axiom has the same issues.

 My take on this is that what you check depends on the reason you are
 checking.
 If you are generating the output for human use (e.g. a table) then you
 want decimal.
 If you are generating the output for regression testing (e.g. checking
 the answers on
 multiple hardware) then you probably want Fateman's solution.

 Tim
 

 The output is used both for human use and for regression testing.  Its
 primary use is human -- it's an example in the Sage reference manual:

sage: float(e)
2.7182818284590451

 This is something a user will look at when reading the documentation
 for some function.  It illustrates what happens when they convert the
 symbolic constant e to float.

 William

   
And therein lies the problem. We use a regression that does a comparison 
of the
printed representation of the output of the run with a stored copy of 
the output.

All of our regression tests were passing until I installed another, 
unrelated program.
Suddenly about 30 regression tests started failing. It turns out that 
the unrelated
program upgraded one of the system libraries. The net effect of that 
change was
to cause the last digit in the output to wobble so that some of the 
table values
differ in the nth place (20th, 30th, or thereabouts digit). This caused 
the regression
comparisons to fail.

Common lisp will give you the exact bit pattern of the float and this value
does not wobble so the text comparison succeeds with both the old and
the new libraries against the bit pattern.

So I can tell you from experience that what you would like to do is not
going to succeed.

Our solution to the human vs regression problem is to include the stable
bit values in the actual compare and keep the human values in a latex
table. This is easy to do with literate input.

Tim







-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] new version of compmath proposal

2009-11-30 Thread Tim Daly
William Stein wrote:
 Hi,

 I've posted a new version of the compmath proposal here:

 http://wstein.org/grants/compmath09/project_summary.pdf
 http://wstein.org/grants/compmath09/project_description.pdf
 http://wstein.org/grants/compmath09/references_cited.pdf

 This is basically the final version, though I could probably fix some
 typos.  So if you read it and see typos, let me know.   If you see
 anything technically seriously wrong/stupid, also let me know.

 Thanks,

  -- William

   
I'm not on the NSF committee to review this but it appears that
you are asking for funding for Sage days. One of the innovative
Sage days listed for funding is a Bug Smash day. So one of the
four days of funding is for debugging work.

Am I misreading the proposal? Is a Bug Smash day innovative?

If nothing else, you might retitle the day to something else.

Believe me, I understand the critical importance of bug smashing
to the progress and success of the project. I'm just not sure that
the committee might not consider it worth funding. I see a lot of
words, like the S-Dyer proposal but I couldn't get funding at CCNY
to work on the Andrews-Curtis conjecture from Infinite Group Theory
(see http://daly.axiom-developer.org in the bottom right corner)

Magnus is the largest Infinite Group Theory project and was
originally created through NSF funding. At one point, the funding
dried up, about the time I became lead developer, although I'm
not sure that correlation implies causation in this case.

Tim

-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: A Sage NSF proposal to the Computational Mathematics Program

2009-11-23 Thread Tim Daly
Jaap Spies wrote:
 mark mcclure wrote:
   
 On Nov 23, 3:30 pm, William Stein wst...@gmail.com wrote:
 
 That is true.  In fact, I hope in the proposal to not insult or snub
 non-free commercial software either.
   
 But William, just two days ago on sage-support you wrote:
 Let's put Mathworks out of business.
 http://groups.google.com/group/sage-support/browse_thread/thread/b56450bab6d43bf7/a82a770db1abd6dc#msg_d72f94b7ff856c29

 

 Ever heard of the word humor? Even without a smiley this is possible in
 a message.

 Jaap


   

I believe Sage is a very useful piece of software for many people.
But I have had numerous discussions (the last one was at the NSF
workshop in Rhode Island prior to ECCAD) about funding open source
computational mathematics. The definitive statement seems to be:

  NSF will not fund software development that competes with
   existing commercial software.

I pointed out that nowhere in Axiom's goals was there any sense of
competing with commercial software but that response was unheard.

But given the definitive reply from NSF
I am somewhat surprised that NSF funds Sage at all.

-- 
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
URL: http://www.sagemath.org


Re: [sage-devel] Re: A Sage NSF proposal to the Computational Mathematics Program

2009-11-23 Thread Tim Daly
Is there a plan for what happens if funding is not approved?
Do the servers continue? Are the students reassigned?
Do the Sage days continue? Does the code move to 
sourceforge or github? Does this become a free-time only,
non-academic activity? Once Sage becomes a non-academic
free and open source project there is no hope of getting
NSF to pay attention again. (Axiom used to be funded at IBM).

Computational mathematics suffers from one critical flaw
(which I pointed out to the NSF). Someone in an academic
position only gets tenure track credit for published PAPERS.
Source code does not count and it is a net loss to write
working code if you are on a tenure track. This makes it
hard for someone to aspire to a tenure position and also
participate effectively in open-source computational math.

So if (when) Sage is no longer a hot topic, funded, and a
top-of-the-interest-pile for new papers then the momentum
slows a bit. NSF funding is critical for keeping the conference
papers flowing. Without it there will be no papers and Sage
will become venerable software.

It is very difficult to run a large open source project with
no funding at all. Axiom costs me between $4000 and $5000
per year for hosting costs, equipment, personal travel, free
books (I buy old copies of the Axiom book and give them
away), etc. So while Axiom is technically free-as-in-beer
the reality is that it comes out of my personal budget.

I assume that Sage has similar direct and indirect costs.
If these are no longer receiving NSF and/or academic
funding (e.g. free server hosting) what becomes of the
Sage project?

Tim

-- 
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
URL: http://www.sagemath.org


[sage-devel] Axiom trademark and ethics

2009-10-16 Thread Tim Daly

 Hi,
 
 I looked at http://www.uspto.gov/teas/e-TEAS/index.html where one can
 
 search for trademarks, file a trademark application, etc.  It looks
 like it costs $325.  I think filing an application for SageMath
 would be an appropriate use of Sage foundation funds.

 There is a search form here:
 http://tess2.uspto.gov/bin/gate.exe?f=tessstate=4001:pj0t1h.1.1

 I've only ever heard of trademarking math software in the context of
 Tim Daly remarking that Axiom is his registered trademark, so I
 searched Axiom first and found 103 hits -- the first I clicked on was
 for Axiom: Providing Christian evangelistic and ministerial services
 directed towards athletes, athletic coaches and those whom they
 influence, in the sport of skateboarding.  I tried searching Axiom
 and software (and similar searches) but couldn't find anything about
 the Axiom math software (I just thought it would be a good example).
 
 There are at least 359 registered trademarks that contain the word
 Sage in them.   Searching for just Sage and software yields just 5
 or so, including

  http://tess2.uspto.gov/bin/showfield?f=docstate=4001:pj0t1h.13.29

 which is the one for the accounting software.  Their description is:
 Computer software for use in managing accounting and business
 information, retrieving accounting and business information, viewing
 accounting and business information, managing contacts and performing
 accounting functions in the fields of business management, information
 services, and research systems; computer software for use in
 electronic commerce to allow users to perform electronic business
 transactions via a global computer network, electronic mail, Internet
 website hosting, Internet website development, and Internet access;
 and accompanying user manual documentation for use with all of the
 above. 

 If there were a problem trademarking the name Sage, it would I guess
 be most likely to be because of the accounting software.

 The word SageMath does not have any entries at all in the trademark 
 database.

 The point of this email is to discuss:

   (1) Should we trademark SageMath (pretty obvious yes)?

   (2) Should we also trademark Sage in the context of math software,
 if possible?

   (3) Is there somebody who like legal stuff who is willing to help
 out with the application?   Because I'm not such a person.

 I'm not in a hurry, but think it's about time to start moving this
 process forward.


I am not a lawyer but I DID speak to a lawyer about the Axiom
trademark. The issue of a trademark is to make sure that the
mark implies the particular product named. So the trademark is
used to identify a particular product and to protect the
reputation of that product. You do not want someone posting
bugs about Sage that do not apply to your software, thereby
possibly damaging the Sage reputation. Since the GPL2 allows
all of your code to be cloned, the name IS the project.

Trademarks in the United States (I have no idea how this works
in the rest of the world...) can be obtained in two ways
(according to a trademark lawyer). You can register a trademark
or you can use the mark in an exclusive manner for 7 years and
obtain a common law trademark. Axiom has been unregistered
since NAG dropped the registration in 2000. It has been used in
a computer algebra sense to apply to this project since that time.
Legally, then, I am the common law holder of the Axiom trademark
as it applies to Computer Algebra software (there are, as you have
noticed, hundreds of 'Axiom' trademarks in different areas).

In either case, in order to keep a trademark, you need to defend
against any and all infringing uses of the mark or you might lose it.
You also need to keep the mark current with active use, which Axiom
does. Keeping or losing a trademark does not depend on registration.
Registration makes it easier to show that you are the holder but
you can still lose the mark if it is not actively defended.

My campaign with Sage to stop using the name Axiom as a command
to invoke Fricas was part of the necessary defense of the mark.
The Axiom BSD license is copyright-based and allows forking the code
but not use of the name.

Trademark is a different area of intellectual property law and
nothing in the GPL2 or BSD license allows infringing of a trademark.
You'll have the same problems when defending Sage.

I have sent you notes about the use of Sage in the area
of mathematics when I have found other math software using the
same name. If another math software project uses the same name
you would have to show that you were using it first. Even then
you might not be able to be able to defend the name.

If you want a trademark you will need a unique name in the field
of use and you will need to defend it. Registration is little
more than publicly stating ownership but it is not required.

I hated consulting a real, live lawyer. It costs me time and
money I'd rather not have spent. But at this point I am reasonably
certain that I

[sage-devel] Re: Categories restart: call for reviewers

2009-08-24 Thread Tim Daly

Nicolas

Do you have the inheritance graph of the categories?

Tim Daly


Nicolas M. Thiery wrote:
   Hi John!

 On Sun, Aug 23, 2009 at 12:37:11PM +0100, John Cremona wrote:
   
 2009/8/23 Nicolas M. Thiery nicolas.thi...@u-psud.fr:
 
 So you can focus on looking at the code, doc, and tests in the files
 mentioned in:

http://trac.sagemath.org/sage_trac/wiki/CategoriesCategoriesReview

 possibly simply by browsing:


 http://combinat.sagemath.org/hgwebdir.cgi/code/file/tip/sage/categories)

 and make sure they makes sense.
   
 I don't really know how this type of reviewing differs from normal
 Sage reviewing of patches attached to trac tickets.  
 

 Just that you don't need to worry about the technical side (checking
 that the patch applies, pass test, ...). Also setting a positive
 review will be on the wiki page, file by file, rather than on the trac
 ticket. Finally, there is essentially no datastructure/algorithm issue
 in the current code (that will change!)

   
 But anyway, I looked at one file, finite_fields.py, and the method
 _call_() in there looks wrong -- it raises an error whatever the
 input, while the dicstring suggests that it is supposed to try using
 __call__() and only change the error message if that does not work.
 

 It's the converse: __call__ tries to do generic stuff (like C(P)
 returns P if P is readilly a parent in the category C), and if that
 does not work calls _call_ (similar to what happens for __mul__ /
 _mul). I actually haven't changed that part; that's how it is in the
 original category framework.

 See the doc of _call_ / __call__ in Category (sage.category.category.py).

 Suggestions to improve the doctests to clarify this are welcome!

   
 If I have completely misunderstood what is going on, then I will
 carry on ignoring the category activity until it is finished,
 

 Please don't!

   
 at which point I'm sure I will use it all the time!
 

 Which is why I want as much early feedback from you as possible :-)

 Cheers,
   Nicolas
 --
 Nicolas M. Thiéry Isil nthi...@users.sf.net
 http://Nicolas.Thiery.name/

 

   


--~--~-~--~~~---~--~~
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 build failure

2008-04-23 Thread daly

The install.log file is at 
http://daly.axiom-developer.org/install.log


This fails on fedora 5

[EMAIL PROTECTED] sage-3.0]# uname -a
Linux localhost.localdomain 2.6.18-1.2239.fc5 #1 Fri Nov 10 13:04:06 EST 2006 
i686 i686 i386 GNU/Linux
You have new mail in /var/spool/mail/root
[EMAIL PROTECTED] sage-3.0]# cat /proc/cpuinfo
processor   : 0
vendor_id   : GenuineIntel
cpu family  : 6
model   : 14
model name  : Genuine Intel(R) CPU   T2050  @ 1.60GHz
stepping: 8
cpu MHz : 1595.293
cache size  : 2048 KB
fdiv_bug: no
hlt_bug : no
f00f_bug: no
coma_bug: no
fpu : yes
fpu_exception   : yes
cpuid level : 10
wp  : yes
flags   : fpu vme de pse tsc msr pae mce cx8 apic mtrr pge mca cmov pat 
clflush dts acpi mmx fxsr sse sse2 ss nx constant_tsc pni
bogomips: 3233.79




building 'sage.modules.real_double_vector' extension
gcc -fno-strict-aliasing -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes 
-fPIC -DGSL_DISABLE_DEPRECATED=1 
-I/research/sage-3.0/local/lib/python2.5/site-packages/numpy/core/include/numpy 
-I/research/sage-3.0/local//include -I/research/sage-3.0/local//include/csage 
-I/research/sage-3.0/devel//sage/sage/ext 
-I/research/sage-3.0/local/include/python2.5 -c 
sage/modules/real_double_vector.c -o 
build/temp.linux-i686-2.5/sage/modules/real_double_vector.o -w -w
sage/modules/real_double_vector.c: In function 
'__pyx_pf_4sage_7modules_18real_double_vector_28RealDoubleVectorSpaceElement___init__':
sage/modules/real_double_vector.c:2014: internal compiler error: in 
merge_alias_info, at tree-ssa-copy.c:235
Please submit a full bug report,
with preprocessed source if appropriate.
See URL:http://bugzilla.redhat.com/bugzilla for instructions.
Preprocessed source stored into /tmp/ccwUCwx8.out file, please attach this to 
your bugreport.
error: command 'gcc' failed with exit status 1
sage: There was an error installing modified sage library code.

ERROR installing SAGE

real13m47.698s
user11m26.741s
sys 2m9.727s
sage: An error occurred while installing sage-3.0
Please email sage-devel http://groups.google.com/group/sage-devel
explaining the problem and send the relevant part of
of /research/sage-3.0/install.log.  Describe your computer, operating system, 
etc.
If you want to try to fix the problem, yourself *don't* just cd to
/research/sage-3.0/spkg/build/sage-3.0 and type 'make'.
Instead type /research/sage-3.0/sage -sh
in order to set all environment variables correctly, then cd to
/research/sage-3.0/spkg/build/sage-3.0
(When you are done debugging, you can type exit to leave the
subshell.)
make[1]: *** [installed/sage-3.0] Error 1
make[1]: Leaving directory `/research/sage-3.0/spkg'

real150m43.177s
user74m23.338s
sys 69m26.373s

--~--~-~--~~~---~--~~
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://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-devel] Sage 3.0 notebook fails to display

2008-04-22 Thread daly

On a clean build (see specs below)
(log is at http://daly.axiom-developer.org/install.log)

./sage
sage: notebook()

on Fedora 8 86_64

on
processor   : 0
vendor_id   : AuthenticAMD
cpu family  : 15
model   : 104
model name  : AMD Athlon(tm) 64 X2 Dual-Core Processor TK-57
stepping: 2
cpu MHz : 1900.113
cache size  : 256 KB
fpu : yes
fpu_exception   : yes
cpuid level : 1
wp  : yes
flags   : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov 
pat pse36 clflush mmx fxsr sse sse2 syscall nx mmxext fxsr_opt rdtscp lm 
3dnowext 3dnow up rep_good pni cx16 lahf_lm extapic misalignsse
bogomips: 3803.70
TLB size: 1024 4K pages
clflush size: 64
cache_alignment : 64
address sizes   : 36 bits physical, 48 bits virtual
power management: ts fid vid ttp tm stc 100mhzsteps


this opens Firefox (version 2.0.0.8) to:
https://:8000/?startup_token=(long hex string)

and says Server not found



tar -xf sage-3.0.tar 
[EMAIL PROTECTED] sage]# cd sage-3.0
[EMAIL PROTECTED] sage-3.0]# make
cd spkg  ./install all 21 | tee -a ../install.log
make[1]: Entering directory `/space/sage/sage-3.0/spkg'
.

Host system
uname -a:
Linux localhost.localdomain 2.6.23.1-42.fc8 #1 SMP Tue Oct 30 13:18:33 EDT 2007 
x86_64 x86_64 x86_64 GNU/Linux


GCC Version
gcc -v
Using built-in specs.
Target: x86_64-redhat-linux
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man 
--infodir=/usr/share/info --enable-shared --enable-threads=posix 
--enable-checking=release --with-system-zlib --enable-__cxa_atexit 
--disable-libunwind-exceptions 
--enable-languages=c,c++,objc,obj-c++,java,fortran,ada --enable-java-awt=gtk 
--disable-dssi --enable-plugin 
--with-java-home=/usr/lib/jvm/java-1.5.0-gcj-1.5.0.0/jre 
--enable-libgcj-multifile --enable-java-maintainer-mode 
--with-ecj-jar=/usr/share/java/eclipse-ecj.jar --with-cpu=generic 
--host=x86_64-redhat-linux
Thread model: posix
gcc version 4.1.2 20070925 (Red Hat 4.1.2-33)





I tried

sage: hg_sage.pull()
sage: hg_sage.update()
sage: hg_sage.merge()
but it says there is nothing to merge.

Tim

--~--~-~--~~~---~--~~
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://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-devel] Approximating Ei using polynomials

2008-01-17 Thread daly

The AS handbook lists polynomial coefficients for approximation of E1,
the exponential integral. Does anyone know how these coefficients were
derived? Is it a chebyshev polynomial? I want to dynamically compute
these coefficients to the required precision.

Tim

--~--~-~--~~~---~--~~
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] Axiom and the Numerical Mathematics Consortium

2008-01-17 Thread daly

I have been concentrating on Axiom's numerical capabilities. 
I am making a set of regression tests against the published values
in Abramowitz and Stegun (1965). You might find it interesting to
run these same tests in Sage. I can send them to anyone who would 
like to volunteer. They are basically the published table values
versus the computed values. For instance, one row reads:

[0.01, 0.00841468254, sin(0.01), 
sin(0.01)-0.00841468254]

where the first entry is the point, the second entry is the AS table value,
the third entry is a function call, and the fourth entry is the computed
difference.

I'm a member of the Numerical Mathematics Consortium
(http://www.nmconsortium.org).A recently published draft
standard, which I'm reviewing, is available at:
http://www.nmconsortium.org/docs/NMC_Technical_Specification%20(9-24-2007).pdf

You might find it useful to track these standards.

Tim

--~--~-~--~~~---~--~~
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] Two Computational Mathematics Job Openings

2008-01-17 Thread daly

City College of New York (my prior place of employment) and the 
Center for Algorithms and Interactive Scientific Software (CAISS) has 
two tenure track job openings. Headed by Gilbert Baumslag, the designer
of Magnus http://sourceforge.net/projects/magnus, this is a group
dedicated to computational mathematics. There is a strong emphasis
on group-theoretic work, as Dr. Baumslag is the leading expert in
infinite group theory.

Dr. Baumslag has invented and reduced to practice a new interface idea
called the zero learning curve front end. It changes the way users
think about solving problems, allows parallel computations naturally,
and, as you'd expect from the title, is trivial to learn.

As a former employee I can highly recommend the people and the
working environment. There are many visitors to the group who are
known worldwide so there are many interesting connections.

Visit http://grouptheory.org

Tim Daly

--~--~-~--~~~---~--~~
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://www.sagemath.org
-~--~~~~--~~--~--~---



[sage-devel] Axiom and Sage

2007-12-09 Thread daly

Well,per your request, I logged in to the Sage VM and did
  sage -f fricas-0.3.1
simply hangs. However,
  sage -f axiom4sage-0.3.1
succeeds and shows a total time of 
  real 18m42
or, if I include network time
  real 19.6
which is about the wall-clock time.

So there appears to be a suggestion that it might
be a good idea to do package installs directly rather
than thru the notebook interface. Potentially this
could be due to the large amount of screen output.

Apparently the package rename didn't work.

Tim


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