[sage-devel] Re: How to verify this computation using Sage?

2012-01-26 Thread Jason Grout
On 1/26/12 11:49 PM, Iftikhar Burhanuddin wrote: http://www.itsokaytobesmart.com/post/16530098836/mind-melter-of-the-day-it-turns-out-that-if-you (1/998001).n(digits=3500) Thanks, Jason -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, se

[sage-devel] How to verify this computation using Sage?

2012-01-26 Thread Iftikhar Burhanuddin
http://www.itsokaytobesmart.com/post/16530098836/mind-melter-of-the-day-it-turns-out-that-if-you -- 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 h

Re: [sage-devel] Re: DYLD on Mac... again

2012-01-26 Thread Justin C. Walker
On Jan 26, 2012, at 20:00 , kcrisman wrote: > > > On Jan 26, 10:55 pm, kcrisman wrote: >> My apologies if I have missed a reference to this elsewhere; it's late >> and I didn't search as thoroughly as I might have, though I did >> search. >> >> Found while reviewing #11977: >> >> sage: matri

[sage-devel] Re: Literal matrix syntax

2012-01-26 Thread Rob Beezer
First, like Simon said: "But I wouldn't be so mean to prevent other people from using it." But I have trouble getting too excited about this new syntax. What we have works well for me and for my students. Second, I agree strongly when William said: "I'm more for *consistency* between the matrix

[sage-devel] Re: xcode and gcc

2012-01-26 Thread kcrisman
On Jan 26, 10:53 pm, William Stein wrote: > On Thu, Jan 26, 2012 at 7:42 PM, Dima Pasechnik wrote: > > > On Friday, 27 January 2012 04:15:32 UTC+8, William wrote: > > >> Hi, > > >> Earlier today I was arguing that we need to support Xcode 4.x, etc., > >> in the context of the PARI bugs. > > >>

[sage-devel] Re: DYLD on Mac... again

2012-01-26 Thread kcrisman
On Jan 26, 10:55 pm, kcrisman wrote: > My apologies if I have missed a reference to this elsewhere; it's late > and I didn't search as thoroughly as I might have, though I did > search. > > Found while reviewing #11977: > > sage: matrix_plot(matrix(2,[1,2,3,4])) > dyld: Library not loaded: /usr/

[sage-devel] DYLD on Mac... again

2012-01-26 Thread kcrisman
My apologies if I have missed a reference to this elsewhere; it's late and I didn't search as thoroughly as I might have, though I did search. Found while reviewing #11977: sage: matrix_plot(matrix(2,[1,2,3,4])) dyld: Library not loaded: /usr/X11/lib/libfreetype.6.dylib Referenced from: /usr/X1

Re: [sage-devel] Re: xcode and gcc

2012-01-26 Thread William Stein
On Thu, Jan 26, 2012 at 7:42 PM, Dima Pasechnik wrote: > > > On Friday, 27 January 2012 04:15:32 UTC+8, William wrote: >> >> Hi, >> >> Earlier today I was arguing that we need to support Xcode 4.x, etc., >> in the context of the PARI bugs. >> >> I'm sitting here with a grad student with a solid Ma

[sage-devel] Re: xcode and gcc

2012-01-26 Thread Dima Pasechnik
On Friday, 27 January 2012 04:15:32 UTC+8, William wrote: > > Hi, > > Earlier today I was arguing that we need to support Xcode 4.x, etc., > in the context of the PARI bugs. > > I'm sitting here with a grad student with a solid Mac running OS X > 10.6.8, and trying to get XCode 3.x on it is HELL.

[sage-devel] Re: Literal matrix syntax

2012-01-26 Thread Jason Grout
On 1/26/12 8:21 PM, Tom Boothby wrote: On Thu, Jan 26, 2012 at 5:15 PM, David Roe wrote: Another issue: do we allow [1..10; 10..20]? We probably shouldn't go to extra effort to support it. I can't seem to construct matrices with matrix entries (this is not absurd) -- but should the preparse

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

2012-01-26 Thread Robert Bradshaw
On Thu, Jan 26, 2012 at 6:21 PM, Tom Boothby wrote: > On Thu, Jan 26, 2012 at 5:15 PM, David Roe wrote: Another issue: do we allow [1..10; 10..20]? >>> >>> We probably shouldn't go to extra effort to support it. >>> I can't seem to construct matrices with matrix entries (this is no

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

2012-01-26 Thread Tom Boothby
On Thu, Jan 26, 2012 at 5:15 PM, David Roe wrote: >>> Another issue: do we allow [1..10; 10..20]? >> >> We probably shouldn't go to extra effort to support it. >> >>> I can't seem to construct >>> matrices with matrix entries (this is not absurd) -- but should the >>> preparser grok it? [[1..10; 1

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

2012-01-26 Thread Robert Bradshaw
On Thu, Jan 26, 2012 at 5:15 PM, David Roe wrote: >>> Another issue: do we allow [1..10; 10..20]? >> >> We probably shouldn't go to extra effort to support it. >> >>> I can't seem to construct >>> matrices with matrix entries (this is not absurd) -- but should the >>> preparser grok it? [[1..10; 1

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

2012-01-26 Thread David Roe
>> Another issue: do we allow [1..10; 10..20]? > > We probably shouldn't go to extra effort to support it. > >> I can't seem to construct >> matrices with matrix entries (this is not absurd) -- but should the >> preparser grok it? [[1..10; 10..20] ; [2..12; 14..24]] > > Yes, for sure. And [[1..10;

[sage-devel] Re: webgl

2012-01-26 Thread kcrisman
On Jan 26, 7:19 pm, Robert Bradshaw wrote: > On Thu, Jan 26, 2012 at 3:41 PM, Volker Braun wrote: > > On Thursday, January 26, 2012 2:14:36 PM UTC-8, William wrote: > > >> [1] If you're using Chrome, check out > >>http://www.chromeexperiments.com/webgl > > > Unless you use Linux, where chrome d

Re: [sage-devel] Re: webgl

2012-01-26 Thread Robert Bradshaw
On Thu, Jan 26, 2012 at 3:41 PM, Volker Braun wrote: > On Thursday, January 26, 2012 2:14:36 PM UTC-8, William wrote: >> >> [1] If you're using Chrome, check out >> http://www.chromeexperiments.com/webgl > > > Unless you use Linux, where chrome doesn't support webgl despite what the > documentatio

[sage-devel] Re: webgl

2012-01-26 Thread Jason Grout
On 1/26/12 4:14 PM, William Stein wrote: Hi, Is anybody interested in creating a webGL [1] renderer for 3d graphics for the Sage notebook? We have JMOL, Tachyon, Java3d and x3d renderers for 3d graphics. Webgl support would be very forward looking. It's also *3d accelerated* unlike Jmol, so c

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

2012-01-26 Thread Robert Bradshaw
On Thu, Jan 26, 2012 at 3:51 PM, Tom Boothby wrote: > On Thu, Jan 26, 2012 at 3:21 PM, Robert Bradshaw > wrote: >> On Thu, Jan 26, 2012 at 3:08 PM, Tom Boothby wrote: >>> On Thu, Jan 26, 2012 at 2:36 PM, Robert Bradshaw >>> wrote: On Thu, Jan 26, 2012 at 1:51 PM, Michael Orlitzky wr

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

2012-01-26 Thread Tom Boothby
On Thu, Jan 26, 2012 at 3:21 PM, Robert Bradshaw wrote: > On Thu, Jan 26, 2012 at 3:08 PM, Tom Boothby wrote: >> On Thu, Jan 26, 2012 at 2:36 PM, Robert Bradshaw >> wrote: >>> On Thu, Jan 26, 2012 at 1:51 PM, Michael Orlitzky >>> wrote: On 01/26/12 16:36, William Stein wrote: >> >

[sage-devel] Re: webgl

2012-01-26 Thread Volker Braun
On Thursday, January 26, 2012 2:14:36 PM UTC-8, William wrote: > > [1] If you're using Chrome, check out > http://www.chromeexperiments.com/webgl > Unless you use Linux, where chrome doesn't support webgl despite what the documentation says. Works in Firefox, though. > -- To post to this gro

[sage-devel] Re: Android app

2012-01-26 Thread Michael Madison
Jason, This is an android phone. The the space I just get an "ok" nothing else. Mike On Jan 25, 6:46 pm, Jason Grout wrote: > On 1/25/12 5:13 PM, Michael Madison wrote: > > > Jason,  On a HTC Thunderbolt with Android 2.3.4 if I put a couple of > > spaces I get an "ok", but not 2.  Mike > > Tha

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

2012-01-26 Thread Robert Bradshaw
On Thu, Jan 26, 2012 at 3:08 PM, Tom Boothby wrote: > On Thu, Jan 26, 2012 at 2:36 PM, Robert Bradshaw > wrote: >> On Thu, Jan 26, 2012 at 1:51 PM, Michael Orlitzky >> wrote: >>> On 01/26/12 16:36, William Stein wrote: > > Why *not* use it? The standard argument against prepar

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

2012-01-26 Thread Tom Boothby
On Thu, Jan 26, 2012 at 2:36 PM, Robert Bradshaw wrote: > On Thu, Jan 26, 2012 at 1:51 PM, Michael Orlitzky > wrote: >> On 01/26/12 16:36, William Stein wrote: Why *not* use it? >>> >>> The standard argument against preparser stuff like this is that you >>> have to be careful to not us

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

2012-01-26 Thread Robert Bradshaw
On Thu, Jan 26, 2012 at 1:51 PM, Michael Orlitzky wrote: > On 01/26/12 16:36, William Stein wrote: >>> >>> Why *not* use it? >> >> The standard argument against preparser stuff like this is that you >> have to be careful to not use it when writing .py code for the Sage >> core library.     But at

[sage-devel] webgl

2012-01-26 Thread William Stein
Hi, Is anybody interested in creating a webGL [1] renderer for 3d graphics for the Sage notebook? We have JMOL, Tachyon, Java3d and x3d renderers for 3d graphics. Webgl support would be very forward looking. It's also *3d accelerated* unlike Jmol, so could provide amazingly good performance. W

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

2012-01-26 Thread Michael Orlitzky
On 01/26/12 17:00, William Stein wrote: > On Thu, Jan 26, 2012 at 1:51 PM, Michael Orlitzky > wrote: >> On 01/26/12 16:36, William Stein wrote: Why *not* use it? >>> >>> The standard argument against preparser stuff like this is that you >>> have to be careful to not use it when writing

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

2012-01-26 Thread William Stein
On Thu, Jan 26, 2012 at 1:51 PM, Michael Orlitzky wrote: > On 01/26/12 16:36, William Stein wrote: >>> >>> Why *not* use it? >> >> The standard argument against preparser stuff like this is that you >> have to be careful to not use it when writing .py code for the Sage >> core library.     But at

Re: [sage-devel] Re: xcode and gcc

2012-01-26 Thread William Stein
On Thu, Jan 26, 2012 at 1:52 PM, Georg S. Weber wrote: >  Hi William, > > unlike OS X 10.7 Lion (for which no official install DVDs exist), OS X > 10.6 Snow Leopard came with/on a install DVD (either with the Mac when > one bought it, or when one bought Snow Leopard later). And on those > DVD(s),

[sage-devel] Re: xcode and gcc

2012-01-26 Thread Georg S. Weber
Hi William, unlike OS X 10.7 Lion (for which no official install DVDs exist), OS X 10.6 Snow Leopard came with/on a install DVD (either with the Mac when one bought it, or when one bought Snow Leopard later). And on those DVD(s), there is also the XCode 3.x package --- to the best of my knowledge

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

2012-01-26 Thread Michael Orlitzky
On 01/26/12 16:36, William Stein wrote: >> >> Why *not* use it? > > The standard argument against preparser stuff like this is that you > have to be careful to not use it when writing .py code for the Sage > core library. But at least this matrix notation will always result > in a SyntaxError

Re: [sage-devel] xcode and gcc

2012-01-26 Thread Jeroen Demeyer
Interesting idea: we could probably replace the fortran.spkg by a gcc.spkg and have it compile gcc, gfortran on systems where this is needed. The size of the gcc spkg would roughly be the same as the current fortran spkg. On bsd, I compiled gfortran-4.4.6 from source, compiled the Sage LAPACK wit

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

2012-01-26 Thread William Stein
On Thu, Jan 26, 2012 at 1:33 PM, kcrisman wrote: > > > On Jan 26, 3:19 pm, Jason Grout wrote: >> On 1/26/12 12:13 PM, Robert Bradshaw wrote: >> >> > To get a quick sense of what people think about this, I've decided to >> > rephrase this as a survey.  To be clear, though this coincides with >> >

Re: [sage-devel] Re: xcode and gcc

2012-01-26 Thread David Roe
> So the idea would be that one would develop on Mac by doing > > ./sage -i gcc > ./sage -b +1 David -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group

Re: [sage-devel] xcode and gcc

2012-01-26 Thread William Stein
On Thu, Jan 26, 2012 at 1:28 PM, Jeroen Demeyer wrote: > On 2012-01-26 21:52, Jeroen Demeyer wrote: >> I might look into this.  I will try a proof-of-concept test on bsd. > Proof-of-concept successful on bsd.  Compiled gcc-4.4.6 and compiled > PARI with it, PARI passes all tests. > > I'd like to t

Re: [sage-devel] Re: xcode and gcc

2012-01-26 Thread William Stein
On Thu, Jan 26, 2012 at 1:30 PM, kcrisman wrote: >> We're not including it with Sage.  We would make it available since >> XCode is such a pain in the ass (and is not free).    That Cython >> and even "sage -b" don't work without having to pay Apple additional >> money, gets in the way of our goal

[sage-devel] Re: Literal matrix syntax

2012-01-26 Thread kcrisman
On Jan 26, 3:19 pm, Jason Grout wrote: > On 1/26/12 12:13 PM, Robert Bradshaw wrote: > > > To get a quick sense of what people think about this, I've decided to > > rephrase this as a survey.  To be clear, though this coincides with > > Matlab syntax, the intent is not to try to make Sage a Matl

[sage-devel] Re: xcode and gcc

2012-01-26 Thread kcrisman
> We're not including it with Sage.  We would make it available since > XCode is such a pain in the ass (and is not free).    That Cython > and even "sage -b" don't work without having to pay Apple additional > money, gets in the way of our goals for Sage. Yeah, I was always wondering why we neede

Re: [sage-devel] xcode and gcc

2012-01-26 Thread Jeroen Demeyer
On 2012-01-26 21:52, Jeroen Demeyer wrote: > I might look into this. I will try a proof-of-concept test on bsd. Proof-of-concept successful on bsd. Compiled gcc-4.4.6 and compiled PARI with it, PARI passes all tests. I'd like to try an OS X 10.7 machine if anybody can give me access to such a ma

Re: [sage-devel] xcode and gcc

2012-01-26 Thread Jeroen Demeyer
On 2012-01-26 21:52, Christopher Swenson wrote: > 5) why don't you choose clang + llvm? Because that's what Apple did and it's clearly not working. -- 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...@googl

Re: [sage-devel] xcode and gcc

2012-01-26 Thread Christopher Swenson
Ah, my bad. I misinterpreted the original intent as "requiring" GCC as part of building Sage from source. Carry on. :) --Christopher On Thu, Jan 26, 2012 at 15:57, William Stein wrote: > On Thu, Jan 26, 2012 at 12:52 PM, Christopher Swenson > wrote: > > -1 for distributing our own version o

Re: [sage-devel] xcode and gcc

2012-01-26 Thread William Stein
On Thu, Jan 26, 2012 at 12:52 PM, Christopher Swenson wrote: > -1 for distributing our own version of gcc. > > As someone who has been peripherally involved with this sort of thing at > Google, here are some downsides: > > 1) several hours of extra compiling and testing (a full boostrap build of >

Re: [sage-devel] xcode and gcc

2012-01-26 Thread Christopher Swenson
-1 for distributing our own version of gcc. As someone who has been peripherally involved with this sort of thing at Google, here are some downsides: 1) several hours of extra compiling and testing (a full boostrap build of GCC can be very painful, and running every test can take a very long time

Re: [sage-devel] xcode and gcc

2012-01-26 Thread Jeroen Demeyer
I might look into this. I will try a proof-of-concept test on bsd. -- 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

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

2012-01-26 Thread Fernando Perez
On Thu, Jan 26, 2012 at 12:19 PM, Jason Grout wrote: > I waffle between Yes, and Yes with convincing.  I'm trying it out now to see > how I feel about it.  I feel like we shouldn't extend python too much, but > this syntax is very tempting. > BTW, at the upcoming pydata workshop: http://pydatawo

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

2012-01-26 Thread William Stein
On Thu, Jan 26, 2012 at 12:19 PM, Jason Grout wrote: > On 1/26/12 12:13 PM, Robert Bradshaw wrote: >> >> To get a quick sense of what people think about this, I've decided to >> rephrase this as a survey.  To be clear, though this coincides with >> Matlab syntax, the intent is not to try to make S

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

2012-01-26 Thread Tom Boothby
On Thu, Jan 26, 2012 at 12:09 PM, Jason Grout wrote: > Another option would be: > > [QQ: 1,2,3; 4,5,6] QQ:1 is a slice... > or, as Robert suggests: > > [1,2,3; 4,5,6, base_ring=QQ] -- but then it looks like base_ring=QQ is > another element. assignments aren't literals... but I don't like this

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

2012-01-26 Thread Robert Bradshaw
On Thu, Jan 26, 2012 at 12:09 PM, Jason Grout wrote: > On 1/26/12 1:57 PM, Tom Boothby wrote: > >> It would be nice to be able to specify a type.  Perhaps >> >> R.[1,2,3;2,3,4] ->  Matrix(R,[[1,2,3],[2,3,4]]) >> >> or perhaps even >> >> R[1,2,3;2,3,4] > > > Another option would be: > > [QQ: 1,2,3;

[sage-devel] Re: Literal matrix syntax

2012-01-26 Thread Jason Grout
On 1/26/12 12:13 PM, Robert Bradshaw wrote: To get a quick sense of what people think about this, I've decided to rephrase this as a survey. To be clear, though this coincides with Matlab syntax, the intent is not to try to make Sage a Matlab clone, rather it is to add a missing feature to Sage.

[sage-devel] xcode and gcc

2012-01-26 Thread William Stein
Hi, Earlier today I was arguing that we need to support Xcode 4.x, etc., in the context of the PARI bugs. I'm sitting here with a grad student with a solid Mac running OS X 10.6.8, and trying to get XCode 3.x on it is HELL. None of our Apple ID's work for the Developer network, etc. We can't fin

[sage-devel] Re: Literal matrix syntax

2012-01-26 Thread Jason Grout
On 1/26/12 2:04 PM, William Stein wrote: [X] No, matrices over QQ are for sissies, real mathematicians work over ZZ unless otherwise specified. That would go great in our linear algebra article or in the Sage docs ;) Jason -- To post to this group, send an email to sage-devel@googlegroups.co

[sage-devel] Re: Literal matrix syntax

2012-01-26 Thread mhampton
> Should [a, b; c, d] be a valid syntax for matrix construction in Sage? > > [x ] Yes, I love this syntax! It would be make life better for me and > my students. > Why? This makes it easier to win over people used to Matlab. > > Should the default basering be more linear-algebra friendly? E.g. R

[sage-devel] Re: Literal matrix syntax

2012-01-26 Thread Jason Grout
On 1/26/12 1:57 PM, Tom Boothby wrote: It would be nice to be able to specify a type. Perhaps R.[1,2,3;2,3,4] -> Matrix(R,[[1,2,3],[2,3,4]]) or perhaps even R[1,2,3;2,3,4] Another option would be: [QQ: 1,2,3; 4,5,6] or, as Robert suggests: [1,2,3; 4,5,6, base_ring=QQ] -- but then it lo

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

2012-01-26 Thread William Stein
On Thu, Jan 26, 2012 at 10:13 AM, Robert Bradshaw wrote: > To get a quick sense of what people think about this, I've decided to > rephrase this as a survey.  To be clear, though this coincides with > Matlab syntax, the intent is not to try to make Sage a Matlab clone, > rather it is to add a miss

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

2012-01-26 Thread Tom Boothby
On Thu, Jan 26, 2012 at 10:13 AM, Robert Bradshaw wrote: > To get a quick sense of what people think about this, I've decided to > rephrase this as a survey.  To be clear, though this coincides with > Matlab syntax, the intent is not to try to make Sage a Matlab clone, > rather it is to add a miss

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

2012-01-26 Thread Marco Streng
> Should [a, b; c, d] be a valid syntax for matrix construction in Sage? [ X ] Yes, I love this syntax! It would be make life better for me and my students. [ ] I wouldn't oppose, but may require some convincing. [ ] No, that's a horrible idea. > Why? Short, intuitive, clear, coincides with gp n

[sage-devel] Re: Literal matrix syntax

2012-01-26 Thread Simon King
Hi Robert, On 26 Jan., 19:13, Robert Bradshaw wrote: > Should [a, b; c, d] be a valid syntax for matrix construction in Sage? > > [ ] Yes, I love this syntax! It would be make life better for me and > my students. [X ] I wouldn't oppose, but may require some convincing. > [ ] No, that's a horribl

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

2012-01-26 Thread Robert Bradshaw
To get a quick sense of what people think about this, I've decided to rephrase this as a survey.  To be clear, though this coincides with Matlab syntax, the intent is not to try to make Sage a Matlab clone, rather it is to add a missing feature to Sage. Should [a, b; c, d] be a valid syntax for ma

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

2012-01-26 Thread Robert Bradshaw
On Thu, Jan 26, 2012 at 2:51 AM, daly wrote: [...lots of axiom examples and Sage questions...] Sage, like Axiom, distinguishes between Integers and Rationals with a trivial denominator, has a strong notion of a basering (for matrices, polynomials), etc. You may want to look up coercion and the p

Re: [sage-devel] Re: A Cython module requiring -librt. But not on Mac computers

2012-01-26 Thread Volker Braun
E.g. Fedora only has librt.so and no librt.a. So even the best makefile will not be able to statically link with librt in that case. -- 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 Fo

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

2012-01-26 Thread William Stein
On Thu, Jan 26, 2012 at 6:12 AM, Jason Grout wrote: > On 1/26/12 7:54 AM, Marco Streng wrote: >> >> 2012/1/26 Jason Grout: >>> >>> That's part of the problem pointed out in an earlier message---our RR >>> matrices really are pretty bad for numerical things, but RDF matrices are >>> the way to go (

[sage-devel] Re: Literal matrix syntax

2012-01-26 Thread Jason Grout
On 1/26/12 7:54 AM, Marco Streng wrote: 2012/1/26 Jason Grout: That's part of the problem pointed out in an earlier message---our RR matrices really are pretty bad for numerical things, but RDF matrices are the way to go (the RDF matrices use standard numerical algorithms for the most part, wher

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

2012-01-26 Thread Marco Streng
2012/1/26 Jason Grout : > That's part of the problem pointed out in an earlier message---our RR > matrices really are pretty bad for numerical things, but RDF matrices are > the way to go (the RDF matrices use standard numerical algorithms for the > most part, whereas RR matrices use naive algorith

[sage-devel] Please someone upgrade sagenb so it has R graphics support

2012-01-26 Thread kcrisman
See for instance http://ask.sagemath.org/question/1102/using-r-in-sage-can-not-plot-errors-of-x11-and-png I've had this problem giving talks to (otherwise friendly) R audiences and had to sort of skirt the issue. Given Jason and Volker's work tracking this down, I don't think it should be too ha

[sage-devel] Re: Literal matrix syntax

2012-01-26 Thread Jason Grout
On 1/26/12 5:30 AM, Marco Streng wrote: What would Matlab users think of having to learn the habit of putting "." behind their integers in Sage, e.g.? sage: matrix([[1.,2],[3,4]]).base_ring() Real Field with 53 bits of precision sage: matrix([[1/1,2],[3,4]]).base_ring() Rational Field This wou

Re: [sage-devel] [ARM] sage-4.8 ptestlong failures with graphs

2012-01-26 Thread Nathann Cohen
> Copyright issue? For 4 lines of code in a forum thread, given as an answer to a guy asking "how to code a popcount efficiently" ? If this can be a copyright issue, by itself it is sufficient to say that we would be better without copyrights :-p Nathann -- To post to this group, send an email

Re: [sage-devel] [ARM] sage-4.8 ptestlong failures with graphs

2012-01-26 Thread Julien Puydt
Le 26/01/2012 12:33, Nathann Cohen a écrit : And I did not write this popcount myself, I found it on the (many) pages on which everybody contributes with his own version of that code :-D Copyright issue? Snark on #sagemath -- To post to this group, send an email to sage-devel@googlegroups.com

Re: [sage-devel] [ARM] sage-4.8 ptestlong failures with graphs

2012-01-26 Thread Nathann Cohen
Helloo !! > I'm sure this is configurable, and it should be configured, when building > Sage. Hmmm. That would be GREAT. Definitely worth asking the wise guys working on Cython. > And, calling a (very fast) function is faster than using your code, anyway, > IMHO. Nonono, I remember I re

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

2012-01-26 Thread Marco Streng
What would Matlab users think of having to learn the habit of putting "." behind their integers in Sage, e.g.? sage: matrix([[1.,2],[3,4]]).base_ring() Real Field with 53 bits of precision sage: matrix([[1/1,2],[3,4]]).base_ring() Rational Field This would be a possible warning to engineers: "Ma

Re: [sage-devel] [ARM] sage-4.8 ptestlong failures with graphs

2012-01-26 Thread Dima Pasechnik
On Thursday, January 26, 2012 6:46:30 PM UTC+8, Nathann Cohen wrote: > > > Actually, newer Intel and AMD processors (I guess, ARM too) have POPCNT > > wired in, so __builtin_popcount(), which is a gcc function, will beat > your > > implementation, as time goes by. > > Yep but there's a functio

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 dyna

[sage-devel] Re: Literal matrix syntax

2012-01-26 Thread Simon King
Hi all! On 26 Jan., 10:37, Marco Streng wrote: > 2012/1/26 Dima Pasechnik : > > > No, that's not good. > > > Cause this syntax forbids 1-row matrices to be entered in this format > > (as it won't be possible to distinguish it from a list!) > > How about [1,2,3;] for matrix([[1,2,3]])? > This prob

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

2012-01-26 Thread David Roe
> 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 f

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

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

2012-01-26 Thread Dima Pasechnik
Matlab users are spoiled, as everything is a matrix of floats there. Do you know that 0==0.0 and 0==[0] in Matlab? Going this way, we will end up renaming binomial() to nchoosek(), and creating a Matlab clone :-) -- To post to this group, send an email to sage-devel@googlegroups.com To unsubsc

Re: [sage-devel] [ARM] sage-4.8 ptestlong failures with graphs

2012-01-26 Thread Nathann Cohen
> Actually, newer Intel and AMD processors (I guess, ARM too) have POPCNT > wired in, so __builtin_popcount(), which is a gcc function,  will beat  your > implementation, as time goes by. Yep but there's a function call "becase" it is a function, while the current one is inlined. I really have no

Re: [sage-devel] [ARM] sage-4.8 ptestlong failures with graphs

2012-01-26 Thread Dima Pasechnik
On Thursday, January 26, 2012 5:59:39 PM UTC+8, Nathann Cohen wrote: > > > So one quick test would be to use __builtin_popcount(i) and see if it > makes > > a difference... > > Yepyep It's commented in the code, actually. I used it on a > machine which had the popcount instruction enable, b

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

2012-01-26 Thread Robert Bradshaw
On Thu, Jan 26, 2012 at 2:16 AM, daly 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 complex

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

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

2012-01-26 Thread David Roe
> 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 bot

Re: [sage-devel] [ARM] sage-4.8 ptestlong failures with graphs

2012-01-26 Thread Nathann Cohen
> So one quick test would be to use  __builtin_popcount(i) and see if it makes > a difference... Yepyep It's commented in the code, actually. I used it on a machine which had the popcount instruction enable, but on others the __builtin_popcount is slower that the current code. This being said,

Re: [sage-devel] [ARM] sage-4.8 ptestlong failures with graphs

2012-01-26 Thread Dima Pasechnik
Is the popcount() there even big-endian/little-endian safe? It's not obvious. As well, it will blow on architectures that have a different from x86 idea about the length of int... So one quick test would be to use __builtin_popcount(i) and see if it makes a difference... -- To post to this g

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

2012-01-26 Thread Robert Bradshaw
On Thu, Jan 26, 2012 at 1:37 AM, Marco Streng wrote: > 2012/1/26 Dima Pasechnik : >> No, that's not good. >> >> Cause this syntax forbids 1-row matrices to be entered in this format >> (as it won't be possible to distinguish it from a list!) > > How about [1,2,3;] for matrix([[1,2,3]])? > This pro

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

2012-01-26 Thread Keshav Kini
Python does (1,) but allows and encourages (1, 2) rather than (1, 2,), so IMO we should do [1, 2;] but allow and encourage [1, 2; 3, 4] rather than [1, 2; 3, 4;]. Great idea btw, I like this. This would make it as easy to enter matrices quickly into Sage as it is in Mathematica, MATLAB, etc. I

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

2012-01-26 Thread Mike Hansen
On Thu, Jan 26, 2012 at 1:43 AM, Dima Pasechnik wrote: > then, for consistency, it should be then > [1,2;3,4;], i.e. end each row with ; It can be optional: In [6]: (1,2,3) Out[6]: (1, 2, 3) In [7]: (1,2,3,) Out[7]: (1, 2, 3) --Mike -- To post to this group, send an email to sage-devel@google

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

2012-01-26 Thread Dima Pasechnik
On Thursday, January 26, 2012 5:37:14 PM UTC+8, Marco Streng wrote: > > 2012/1/26 Dima Pasechnik : > > No, that's not good. > > > > Cause this syntax forbids 1-row matrices to be entered in this format > > (as it won't be possible to distinguish it from a list!) > > How about [1,2,3;] for matrix(

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

2012-01-26 Thread Marco Streng
2012/1/26 Dima Pasechnik : > No, that's not good. > > Cause this syntax forbids 1-row matrices to be entered in this format > (as it won't be possible to distinguish it from a list!) How about [1,2,3;] for matrix([[1,2,3]])? This problem and solution are similar to (1,) for a 1-tuple in Python. >

Re: [sage-devel] Re: A Cython module requiring -librt. But not on Mac computers

2012-01-26 Thread Nathann Cohen
> I am trying to compile it with the --ensable-static to see whether it > would solve the problem cheaply But God it is long O_O sage: MixedIntegerLinearProgram(solver="Coin") --- ImportError

[sage-devel] Re: Literal matrix syntax

2012-01-26 Thread Dima Pasechnik
No, that's not good. Cause this syntax forbids 1-row matrices to be entered in this format (as it won't be possible to distinguish it from a list!) Dima -- 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..

Re: [sage-devel] Re: A Cython module requiring -librt. But not on Mac computers

2012-01-26 Thread Nathann Cohen
> The cbc library is linked with librt if it is available. The problem is that > any other library (like any Cython extension class) then also must > explicitly link against librt. I am trying to compile it with the --ensable-static to see whether it would solve the problem cheaply But God it

Re: [sage-devel] Re: A Cython module requiring -librt. But not on Mac computers

2012-01-26 Thread Volker Braun
The cbc library is linked with librt if it is available. The problem is that any other library (like any Cython extension class) then also must explicitly link against librt. You can't do it by setting some CFLAGS and friends. Ideally configure would have a switch to turn it off; since it does

Re: [sage-devel] Re: How can I delete the patch files that I add to a ticket

2012-01-26 Thread Dr. David Kirkby
On 01/26/12 05:56 AM, Keshav Kini wrote: Unfortunately you cannot delete attachments on trac. Just put at the bottom of the ticket description a short description of which attachments are relevant, leaving out the irrelevant or outdated patches, like this: Apply: 1. [attachment:first_patch.ne

Re: [sage-devel] Literal matrix syntax

2012-01-26 Thread David Roe
>> I would like to propose the addition of a matrix literal syntax, namely >> >> sage: [1, 2; 3, 4] >> [1 2] >> [3 4] > +1 +1 from me as well > >> A second question, what of the basering? > > Consistency with "[Mm]atrix([[1,2],[3,4]])" would be most clear. So would > you argue to change basering o

Re: [sage-devel] Re: A Cython module requiring -librt. But not on Mac computers

2012-01-26 Thread Nathann Cohen
Oh, I understand, it was a mistake. Because the way I wanted to do it the "configure" scripts plans for everything to be compiled with -lrt, and I prevent that with this flag... What I need is a way to force "configure" to understand that it should *NOT* use librt, or to make it believe it actually

Re: [sage-devel] Re: A Cython module requiring -librt. But not on Mac computers

2012-01-26 Thread Nathann Cohen
>> Unless there is any marked benefit to using the high-resolution timer its >> probably best to just #define HAVE_CLOCK_GETTIME 1 in config.h after running >> configure. I thought I had found a nice way to do that. I updated the spkg-install file with : export CPPFLAGS="-DHAVE_CLOCK_GETTIME=0"

Re: [sage-devel] Literal matrix syntax

2012-01-26 Thread Marco Streng
Op 26-01-2012 8:22, Robert Bradshaw schreef: I would like to propose the addition of a matrix literal syntax, namely sage: [1, 2; 3, 4] [1 2] [3 4] +1 even gp has this A second question, what of the basering? Consistency with "[Mm]atrix([[1,2],[3,4]])" would be most clear. So would you a

[sage-devel] Literal matrix syntax

2012-01-26 Thread Robert Bradshaw
I would like to propose the addition of a matrix literal syntax, namely sage: [1, 2; 3, 4] [1 2] [3 4] sage: [1, 2; 3, 4] * [5, 6; 7, 8] [19 22] [43 50] Currently one must write sage: matrix([[1, 2], [3, 4]]) [1 2] [3 4] sage: matrix([[1, 2], [3, 4]]) * matrix([[5, 6], [7, 8]]) [19 22] [43 50]

Re: [sage-devel] [ARM] sage-4.8 ptestlong failures with graphs

2012-01-26 Thread Nathann Cohen
Hell !!! HMmmm... Yep, those two patches are pretty new (though the first one was partly there before, it mainly moves some methods into a new module). This being said, the second patch has no reason to call the functions defined in the first. Actually the second was applied