[sage-devel] Re: Comparing complex numbers

2008-08-23 Thread Nils Bruin
On Aug 23, 1:27 pm, "William Stein" <[EMAIL PROTECTED]> wrote: > Did you read through the article Alfredo Portes posted, which > also explains some of the gotchas and subtleties of disallowing > comparisons? I'm curious what you thought of it. At the very least, "<" should be transitive wherev

[sage-devel] Re: adding custom canonical coercions

2008-08-23 Thread Robert Bradshaw
On Aug 23, 2008, at 7:24 PM, Nils Bruin wrote: > With the advent of the new coercion model, did we get the incredibly > cool possibility of adding canonical coercions locally, as promissed > at SD7? I'd love to be able to type something like: > > K.=Numberfield(x^2-2) > E=EllipticCurve([0,0,r2,0,

[sage-devel] adding custom canonical coercions

2008-08-23 Thread Nils Bruin
With the advent of the new coercion model, did we get the incredibly cool possibility of adding canonical coercions locally, as promissed at SD7? I'd love to be able to type something like: K.=Numberfield(x^2-2) E=EllipticCurve([0,0,r2,0,0] for m in K.real_embeddings(): with CanonicalEmbeddin

[sage-devel] Re: Comparing complex numbers

2008-08-23 Thread David Philp
On 24/08/2008, at 6:15 AM, William Stein wrote: > > On Sat, Aug 23, 2008 at 1:00 PM, Fredrik Johansson > <[EMAIL PROTECTED]> wrote: >> >> On Sat, Aug 23, 2008 at 9:57 PM, Nils Bruin <[EMAIL PROTECTED]> wrote: >>> >>> Would it break Python too much if comparison would simply throw an >>> exceptio

[sage-devel] Re: plot_division option in plot

2008-08-23 Thread Arnaud Bergeron
2008/8/23 Philippe Saade <[EMAIL PROTECTED]>: > > On Sat, Aug 23, 2008 at 8:58 PM, William Stein <[EMAIL PROTECTED]> wrote: >> >> On Sat, Aug 23, 2008 at 11:47 AM, Philippe Saade <[EMAIL PROTECTED]> wrote: > >> >> If it is about plot_division and plot_points, then yes, it will be garbage >> in a f

[sage-devel] Re: Comparing complex numbers

2008-08-23 Thread William Stein
On Sat, Aug 23, 2008 at 1:17 PM, Nils Bruin <[EMAIL PROTECTED]> wrote: > > On Aug 23, 1:00 pm, "Fredrik Johansson" <[EMAIL PROTECTED]> > wrote: > >> Hardly, considering that this is what Python itself does: >> >> >>> 1+1j > 1-1j >> >> Traceback (most recent call last): >> File "", line 1, in >>

[sage-devel] Re: Comparing complex numbers

2008-08-23 Thread Alfredo Portes
On Sat, Aug 23, 2008 at 4:00 PM, Fredrik Johansson <[EMAIL PROTECTED]> wrote: > > On Sat, Aug 23, 2008 at 9:57 PM, Nils Bruin <[EMAIL PROTECTED]> wrote: >> >> Would it break Python too much if comparison would simply throw an >> exception in these cases? > > Hardly, considering that this is what P

[sage-devel] Re: Comparing complex numbers

2008-08-23 Thread Nils Bruin
On Aug 23, 1:00 pm, "Fredrik Johansson" <[EMAIL PROTECTED]> wrote: > Hardly, considering that this is what Python itself does: > > >>> 1+1j > 1-1j > > Traceback (most recent call last): > File "", line 1, in > TypeError: no ordering relation is defined for complex numbers Ah, well, if python

[sage-devel] Re: Comparing complex numbers

2008-08-23 Thread William Stein
On Sat, Aug 23, 2008 at 1:00 PM, Fredrik Johansson <[EMAIL PROTECTED]> wrote: > > On Sat, Aug 23, 2008 at 9:57 PM, Nils Bruin <[EMAIL PROTECTED]> wrote: >> >> Would it break Python too much if comparison would simply throw an >> exception in these cases? > > Hardly, considering that this is what P

[sage-devel] Re: Comparing complex numbers

2008-08-23 Thread Fredrik Johansson
On Sat, Aug 23, 2008 at 9:57 PM, Nils Bruin <[EMAIL PROTECTED]> wrote: > > Would it break Python too much if comparison would simply throw an > exception in these cases? Hardly, considering that this is what Python itself does: >>> 1+1j > 1-1j Traceback (most recent call last): File "", line 1

[sage-devel] Comparing complex numbers

2008-08-23 Thread Nils Bruin
I understand that Python really likes things to be comparable with "<", but from a mathematical point of view the following makes me cringe: sage: C.=ComplexField() sage: 1+i > 1-i True sage: 1+i < 1-i False Imagine being shown this by a student after you have explained your complex variables cl

[sage-devel] Re: Sage mentioned in American Scientist

2008-08-23 Thread Ondrej Certik
On Sat, Aug 23, 2008 at 9:48 PM, William Stein <[EMAIL PROTECTED]> wrote: > > On Sat, Aug 23, 2008 at 12:35 PM, Jason Merrill <[EMAIL PROTECTED]> wrote: >> >> Brian Hayes writes a regular column for American Scientist called >> Computing Science. In his latest article, "Calculemus!" >> http://www.

[sage-devel] Re: Sage mentioned in American Scientist

2008-08-23 Thread William Stein
On Sat, Aug 23, 2008 at 12:35 PM, Jason Merrill <[EMAIL PROTECTED]> wrote: > > Brian Hayes writes a regular column for American Scientist called > Computing Science. In his latest article, "Calculemus!" > http://www.americanscientist.org/issues/pub/2008/5/calculemus/1, Hayes > suggests that widel

[sage-devel] Sage mentioned in American Scientist

2008-08-23 Thread Jason Merrill
Brian Hayes writes a regular column for American Scientist called Computing Science. In his latest article, "Calculemus!" http://www.americanscientist.org/issues/pub/2008/5/calculemus/1, Hayes suggests that widely available tools for doing simple calculations and mathematical experiments have not

[sage-devel] Re: plot_division option in plot

2008-08-23 Thread Philippe Saade
On Sat, Aug 23, 2008 at 8:58 PM, William Stein <[EMAIL PROTECTED]> wrote: > > On Sat, Aug 23, 2008 at 11:47 AM, Philippe Saade <[EMAIL PROTECTED]> wrote: > > If it is about plot_division and plot_points, then yes, it will be garbage > in a few days. You should read and/or apply the patches at 38

[sage-devel] Re: What happens during "plot" in notebook

2008-08-23 Thread William Stein
On Sat, Aug 23, 2008 at 11:58 AM, Philippe Saade <[EMAIL PROTECTED]> wrote: > > On Sat, Aug 23, 2008 at 7:47 PM, Arnaud Bergeron <[EMAIL PROTECTED]> wrote: >> >> 2008/8/23 Philippe Saade <[EMAIL PROTECTED]>: >>> >>> Hi group, >>> >>> i'am a little bit confused while analysing Sage Python packages

[sage-devel] Re: plot_division option in plot

2008-08-23 Thread William Stein
On Sat, Aug 23, 2008 at 11:47 AM, Philippe Saade <[EMAIL PROTECTED]> wrote: > > On Sat, Aug 23, 2008 at 8:03 PM, William Stein <[EMAIL PROTECTED]> wrote: >> >> This is a moot point since the plot command was recently >> completely rewritten: >> >> http://trac.sagemath.org/sage_trac/ticket/3813 >>

[sage-devel] Re: What happens during "plot" in notebook

2008-08-23 Thread Philippe Saade
On Sat, Aug 23, 2008 at 7:47 PM, Arnaud Bergeron <[EMAIL PROTECTED]> wrote: > > 2008/8/23 Philippe Saade <[EMAIL PROTECTED]>: >> >> Hi group, >> >> i'am a little bit confused while analysing Sage Python packages and >> (newbie's default) a would like to ask a simple question : > > For the next tim

[sage-devel] Re: plot_division option in plot

2008-08-23 Thread Philippe Saade
On Sat, Aug 23, 2008 at 8:03 PM, William Stein <[EMAIL PROTECTED]> wrote: > > This is a moot point since the plot command was recently > completely rewritten: > > http://trac.sagemath.org/sage_trac/ticket/3813 > as far as i am writing a doc on the plot command, does it means that it will all be ga

[sage-devel] Re: What happens during "plot" in notebook

2008-08-23 Thread Arnaud Bergeron
2008/8/23 Philippe Saade <[EMAIL PROTECTED]>: > > Hi group, > > i'am a little bit confused while analysing Sage Python packages and > (newbie's default) a would like to ask a simple question : For the next time, this sort of question goes to [EMAIL PROTECTED] > when one types > > var('x') > f_ex

[sage-devel] Testing the Notebook using Selenium

2008-08-23 Thread Mike Hansen
Hello all, While we continue to add tests to the notebook code, there are some things that we just can't test directly in Python such as browser interactions / Javascript / etc. Luckily, there is a nice software package designed to handle this problem: Selenium http://selenium.openqa.org/ . Se

[sage-devel] Re: plot_division option in plot

2008-08-23 Thread William Stein
On Sat, Aug 23, 2008 at 10:14 AM, Philippe Saade <[EMAIL PROTECTED]> wrote: > > hi, > > when one uses plot_points and plot_division in a plot command, there > is something misleading (imho) : > > plot_points = 3 gives exactely 3 points in the initial plot (before > refinement) > plot_division = 5

[sage-devel] Re: Things I miss from Maple in Sage

2008-08-23 Thread Nils Bruin
On Aug 22, 10:43 am, Harald Schilly <[EMAIL PROTECTED]> wrote: > >>> data = [-1,2,3] > >>> gt0 = lambda x: x>0 and x or 0 > >>> map(gt0, data) > > [0, 2, 3] > > in python - or more geeky > > >>> map(lambda x: x>0 and x or 0, data) I'm sorry for derailing the thread a little bit, but this is actua

[sage-devel] plot_division option in plot

2008-08-23 Thread Philippe Saade
hi, when one uses plot_points and plot_division in a plot command, there is something misleading (imho) : plot_points = 3 gives exactely 3 points in the initial plot (before refinement) plot_division = 5 can add up to 6 points to the original 3 It is not obvious also that this number of subdivi

[sage-devel] Re: ANN: mpmath 0.9 released

2008-08-23 Thread Ondrej Certik
On Sat, Aug 23, 2008 at 5:35 PM, Fredrik Johansson <[EMAIL PROTECTED]> wrote: > > Hi, > > Mpmath version 0.9 is now available from the website: > http://code.google.com/p/mpmath/ > > It can also be downloaded from the Python Package Index: > http://pypi.python.org/pypi/mpmath/0.9 > > Mpmath is a p

[sage-devel] What happens during "plot" in notebook

2008-08-23 Thread Philippe Saade
Hi group, i'am a little bit confused while analysing Sage Python packages and (newbie's default) a would like to ask a simple question : when one types var('x') f_exp = exp(x) plot_f_exp = plot(f_exp) plot_f_exp.show() what happens exactly in the "plot()" part ? is sage/plot/plot.py in charge o

[sage-devel] Re: factorization patches

2008-08-23 Thread John Cremona
2008/8/22 William Stein <[EMAIL PROTECTED]>: >> This leaves a question almost certainly for William: is it really >> sensible to have one class serve both as the structure to hold "prime >> factorizations" for UFDs and other rings, as well as to hold lists of >> subspaces with multiplicities? >

[sage-devel] Re: Things I miss from Maple in Sage

2008-08-23 Thread Ondrej Certik
On Sat, Aug 23, 2008 at 7:19 AM, rjf <[EMAIL PROTECTED]> wrote: > > > 1. There is a public mathematica language parser (version 3.0 > mathematica) that I wrote in common lisp. > WRI knows about it, inquired about it, made various claims. I > disputed them. They went away. This apparently > has l

[sage-devel] possible typo on "Source Code" page?

2008-08-23 Thread Minh Nguyen
Hi group, At the URL: http://www.sagemath.org/download-source.html the following sentences sound funny to me: [1] "You can get the complete source for Sage to compile it your own Linux or OS X system." Should [1] read: "You can get the complete source for Sage to compile under (in?) your own

[sage-devel] Re: trivial typo in Roadmap web page

2008-08-23 Thread William Stein
On Sat, Aug 23, 2008 at 12:32 AM, Minh Nguyen <[EMAIL PROTECTED]> wrote: > > Hi group, > > I've noticed a possible minor typo at the following URL: > > http://trac.sagemath.org/sage_trac/roadmap > > Under the heading "Milestone: sage-symbolics", here's a "diff" of the said > typo: > > - This mile

[sage-devel] trivial typos on "Download and Media" page

2008-08-23 Thread Minh Nguyen
Hi group, I think there are typos at the following URL: http://www.sagemath.org/download.html Here's a "diff": - Utilites Useful utilites when working with Sage + Utilities Useful utilities when working with Sage -- Regards Minh Van Nguyen Web: http://nguyenminh2.googlepages.com Blog: http:

[sage-devel] trivial typo on "Help and Support" page

2008-08-23 Thread Minh Nguyen
Hi group, At the URL: http://www.sagemath.org/help.html I think the dot point "Google I/O: Painles Python Part 1 / Part 2 ..." should be "Google I/O: Painless Python Part 1 / Part 2 ..." At least that's what shown in my browser after navigating to the page that the dot point links to: http

[sage-devel] trivial typo in Roadmap web page

2008-08-23 Thread Minh Nguyen
Hi group, I've noticed a possible minor typo at the following URL: http://trac.sagemath.org/sage_trac/roadmap Under the heading "Milestone: sage-symbolics", here's a "diff" of the said typo: - This milestone servers as a focal point + This milestone serves as a focal point Although I logged i

[sage-devel] Graph theory, 2D plots and Emily Kirkman's blog

2008-08-23 Thread Philippe Saade
Hi, I am interested in modifying the way Sage draws Graphs and, especially, multi-edged graphs. Emily Kirkman seems to be working on that point but her blog doesn't give any information on recent success. I also want to use Matplotlib to draw graphs. Should i start from scratch or try to contact