Re: [sage-devel] iOS app is for sale

2012-01-31 Thread Ivan Andrus
On Jan 31, 2012, at 7:51 AM, Iftikhar Burhanuddin wrote:
> On Mon, Jan 30, 2012 at 9:52 PM, Justin C. Walker  wrote:
>> Hi, Ifti,
>> On Jan 30, 2012, at 21:36 , Iftikhar Burhanuddin wrote:
>> 
>>> On Mon, Jan 30, 2012 at 9:00 PM, Iftikhar Burhanuddin
>>>  wrote:
 On Mon, Jan 30, 2012 at 8:34 PM, Iftikhar Burhanuddin
>> [snip]
 
 I think I figured it out. I first have to upgrade my iTunes on my Mac
 and then upgrade iOS on my iPhone.
>>> 
>>> I am on Mac OS X 10.4.11. I downloaded the latest iTunes (10.5.3) dmg
>>> and installation pops up
>>> 
>>> """
>>> Open Failed
>>> 
>>> Couldn't open "Install iTunes.pkg". This package type requires Mac OS X 10.5
>>> """
>>> 
>>> What is the appropriate iTunes version to download (to get my hands on
>>> the Sage Math app on my iPhone 4) and where can I find it?
>> 
>> I think you're stuck in a maze of twisty passages, all subtly different :-}
>> 
>> In order to run the "sage math " app, you need to have iOS 5.x installed on 
>> your iDevice.  In order to install iOS 5, you have to run iTunes 10.x.  In 
>> order to run iTunes 10.x, you need at least 10.5 [AKA Leopard] (maybe even 
>> 10.6; I'm not positive about that).
>> 
>> That, at least, is my understanding.
> 
> Thanks, Justin.
> 
> Looks like I have to get the Bigger Cats to tame the Sage. :)

Oops.  There's nothing that requires iOS 5, it's just the default.  I used to 
build it XCode 3 and it worked on iOS 4.  Then I wanted to test on iOS 5 and so 
I had to upgrade to XCode 4 and the default for XCode 4 is iOS 5 and I forgot 
to change it.  I've fixed it now, I think--I no longer have an iOS 4 device to 
test.

I want to wait a few days to get any more bug reports and then I'll push 
another version (say, Friday) fixing this and anything else not too major.  Of 
course it will take a few days to get through the review process, but I'm 
hoping it's faster the second time around.

-Ivan

-- 
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] Naming runs of Sage

2012-01-31 Thread Ivan Andrus
On Jan 31, 2012, at 8:37 AM, Iftikhar Burhanuddin wrote:
> Hi folks,
> 
> When I execute a Sage script using the 'nohup' command [1], for instance
> 
> nohup sage test.sage > out.txt &
> 
> the process is listed in the 'top' command display as 'python'. How do
> I give user-generated names to this 'python' process for the purpose
> of identification?


According to [1] it requires the procname library which can be found at [2].  
Remember you'll need to install it in Sage's version of python, not the system 
one.  So do everything with `sage -python` or `sage -sh`.

-Ivan

[1] 
http://stackoverflow.com/questions/2255444/changing-the-process-name-of-a-python-script
[2] http://code.google.com/p/procname/

-- 
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] iOS app is for sale

2012-01-31 Thread Justin C. Walker

On Jan 31, 2012, at 00:16 , Ivan Andrus wrote:

> On Jan 31, 2012, at 7:51 AM, Iftikhar Burhanuddin wrote:
>> On Mon, Jan 30, 2012 at 9:52 PM, Justin C. Walker  wrote:
>>> Hi, Ifti,
>>> On Jan 30, 2012, at 21:36 , Iftikhar Burhanuddin wrote:
[snip]
>> 
>> Thanks, Justin.
>> 
>> Looks like I have to get the Bigger Cats to tame the Sage. :)
> 
> Oops.  There's nothing that requires iOS 5, it's just the default.  I used to 
> build it XCode 3 and it worked on iOS 4.  Then I wanted to test on iOS 5 and 
> so I had to upgrade to XCode 4 and the default for XCode 4 is iOS 5 and I 
> forgot to change it.  I've fixed it now, I think--I no longer have an iOS 4 
> device to test.
> 
> I want to wait a few days to get any more bug reports and then I'll push 
> another version (say, Friday) fixing this and anything else not too major.  
> Of course it will take a few days to get through the review process, but I'm 
> hoping it's faster the second time around.

Cool.  I'd like to try it, but since I haven't upgraded to iCloud yet, I've 
been avoiding iOS 5.  I wasn't going to complain (since it's free :-}), but 
it's great to have the app available.

Thanks for the hard work.

Justin

--
Justin C. Walker, Curmudgeon at Large
Director
Institute for the Enhancement of the Director's Income
---
Nobody knows the trouble I've been
---



-- 
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] Naming runs of Sage

2012-01-31 Thread Julien Puydt

Le 31/01/2012 08:37, Iftikhar Burhanuddin a écrit :

When I execute a Sage script using the 'nohup' command [1], for instance

nohup sage test.sage>  out.txt&


I generally use gnu screen [1] when I want to let some process run. That 
still makes it possible to go Ctrl+C on the process if I'm unhappy with it.


Snark on #sagemath

[1] http://www.gnu.org/software/screen/

--
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: sagemath.org, sagenb.org and mobile devices

2012-01-31 Thread Ivan Andrus
On Jan 30, 2012, at 1:48 PM, Jason Grout wrote:
> On 1/29/12 9:41 AM, Ivan Andrus wrote:
>> On Jan 25, 2012, at 2:52 PM, kcrisman wrote:
>> 
>>> Ivan's iPhone app is cool.  However, when it links to sagenb or
>>> sagemath.org, it looks ... unhelpful.  Perhaps this is possible to fix
>>> easily - exchange below.  Is there someone for whom this would be only
>>> epsilon/two of effort to fix, who has epsilon/two time available?
>>> 
>>> - kcrisman
>>> 
>>> +++
 Incidentally, the Sage website is totally sucky for iDevice,
 apparently.  Screenshot attached :( though I don't think there is much
 you can do about that.   Sagenb is similar :(
>>> 
>>> Yes indeed!  It would be very nice to fix this someday.  I think it
>>> would simply be a matter of add a css files specifically for mobile
>>> devices:
>>> 
>>> >> media="handheld" />
>>> 
>>> Also adding an iPhone icon would be nice:
>>> 
>>> http://www.icantinternet.org/
>>> icon.png”>
>>> 
>>> I guess I should just do it since it probably takes more effort to
>>> ignore it than to do it. :-)
>> 
>> Actually, it might be easier than that even, at least for the notebook.  
>> According to a stack overflow question [1] the problem with iPhone is that 
>> it tries to "scale your content for optimal viewing".  The solution is to add
>> 
>> 
>> 
>> which tells the (mobile) browser to use the actual width of the device.  
>> IMHO this makes it (much more) usable on the iPhone. There could probably be 
>> some tweaks to the css just for mobile devices, but the notebook actually 
>> scales really well layout-wise.  Some of the plots and such are cut off, but 
>> they fit pretty well when viewed in landscape.
> 
> 
> What about the changes listed here: 
> http://code.google.com/p/sagenb/issues/detail?id=24 ?
> 
> How is  different than 
> what you did?

That's a good question.  I didn't think there was a difference, but reading 
Apple's documentation [1] it seems that device-width always means the same 
thing, even when in landscape mode, so that the content won't resize (it will 
zoom?) when you switch orientations.  If the scaling factor is 1 then it will 
resize so that the width of the page is the device-height when in landscape.  I 
haven't actually tested that though, nor do I know how that would affect 
non-Safari browsers.

On another note, do all of those tickets need to be moved over to github or 
will they be tracked on google?  In particular should I move this one over to 
github or should we (read someone else) try something automated like [2]?

-Ivan

[1] 
http://developer.apple.com/library/safari/#documentation/AppleApplications/Reference/SafariWebContent/UsingtheViewport/UsingtheViewport.html

[2] https://github.com/dave0/gcode-issue-import

-- 
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] iOS app is for sale

2012-01-31 Thread Ivan Andrus
On Jan 31, 2012, at 9:24 AM, Justin C. Walker wrote:
> On Jan 31, 2012, at 00:16 , Ivan Andrus wrote:
>> On Jan 31, 2012, at 7:51 AM, Iftikhar Burhanuddin wrote:
>>> On Mon, Jan 30, 2012 at 9:52 PM, Justin C. Walker  wrote:
 Hi, Ifti,
 On Jan 30, 2012, at 21:36 , Iftikhar Burhanuddin wrote:
> [snip]
>>> 
>>> Thanks, Justin.
>>> 
>>> Looks like I have to get the Bigger Cats to tame the Sage. :)
>> 
>> Oops.  There's nothing that requires iOS 5, it's just the default.  I used 
>> to build it XCode 3 and it worked on iOS 4.  Then I wanted to test on iOS 5 
>> and so I had to upgrade to XCode 4 and the default for XCode 4 is iOS 5 and 
>> I forgot to change it.  I've fixed it now, I think--I no longer have an iOS 
>> 4 device to test.
>> 
>> I want to wait a few days to get any more bug reports and then I'll push 
>> another version (say, Friday) fixing this and anything else not too major.  
>> Of course it will take a few days to get through the review process, but I'm 
>> hoping it's faster the second time around.
> 
> Cool.  I'd like to try it, but since I haven't upgraded to iCloud yet, I've 
> been avoiding iOS 5.  I wasn't going to complain (since it's free :-}), but 
> it's great to have the app available.

But you're supposed to complain!  You're a curmudgeon.  It's what you're paid 
for. :-)

> Thanks for the hard work.

I should definitely thank William (Sage foundation, NSF, whoever) for providing 
the iPod that I tested this on... and maybe once or twice listened to some 
podcasts on as well. :-)

> Justin
> 
> --
> Justin C. Walker, Curmudgeon at Large
> Director
> Institute for the Enhancement of the Director's Income
> ---
> Nobody knows the trouble I've been
> ---

-Ivan

-- 
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: Sage 4.8 and 5.0.beta1 (OS X 10.6)-> Error installing package R

2012-01-31 Thread Guilherme Brondani Torri

On 30/01/12 22:06, François Bissey wrote:

On Mon, 30 Jan 2012 16:20:50 Guilherme Brondani Torri wrote:

Hello!

I jut tried to compile Sage 4.8 and 5.0.beta1 on a OS X 10.6.8 (Snow
Leopard) without success.

I just did:
export MAKE="make -j8"
make

Even after R fails the compilation goes a bit further and stops.  Please
see in attach the and r-2.14.0 log. Also attached the environment
variables form install.log.

For some reason R cannot find the symbols, it seems that the symbol *is*
available on the system, but the Sage lib doesn't have it. See below the
inspection of the libraries R tries to reach.

guilherme$ nm /usr/local/lib/libgomp.1.dylib | grep get_address
   U ___emutls_get_address
guilherme$ nm
/Users/guilherme/sage-5.0.beta1/local/lib//libgcc_s.1.dylib | grep
get_address


Symbol is in another library:

guilherme$ nm /usr/local/lib/libgcc_s.1.dylib | grep get_address
00011450 T ___emutls_get_address

I hope is not my system that is causing the failure.
Any ideas?

Looking at your R build log I'd say you have an issue with LD_LIBRARY_PATH.
You are after a symbol used by libgomp which is implementing openmp feature in
gcc, I am guessing you have installed some stuff in /usr/local (a gcc?).
In any case I am guessing this symbol should be provided by
/usr/local/libcc_s.1.dylib or possibly something else provided by xcode. But
because LD_LIBRARY_PATH doesn't include this location the linker is searching
in $SAGE_LOCAL/lib.
So what does your LD_LIBRARY_PATH read at this point and do you have
/usr/local/lib/libgcc_s.1.dylib ?

Francois



Thank you François!

Indeed I had a forgotten gcc compilation with the wrong prefix...
I cleaned it up and now Sage compiles as expected.

Sorry for the noise...

Guilherme

--
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: iOS app is for sale

2012-01-31 Thread Jason Grout

On 1/31/12 2:16 AM, Ivan Andrus wrote:

I want to wait a few days to get any more bug reports and then I'll push 
another version (say, Friday) fixing this and anything else not too major.  Of 
course it will take a few days to get through the review process, but I'm 
hoping it's faster the second time around.


Great work on this!  If you're looking for small things to fix, here is 
one: can the default computations that come with the app not have errors 
as the top two computations (or maybe not have errors at all in the 
saved computations)?


This is a bigger issue: when I type in a computation, I'm in the full 
screen mode (i.e., the one computation is taking the full screen, with 
its output.  How do I stay in that mode when I submit the computation? 
All I see is the Done button, which takes me back to the index listing. 
 I then have to click on the computation again to examine the output. 
It'd be great if I could stay in that single-computation full screen, 
and maybe just have a "+" button to make a new computation, which would 
clear the screen and let me input another computation.  THe only time I 
would go back to the index screen is to look at the history of computations.


Also: is it easy to make an ipad version?  I don't know how easy it is 
to scale up from an ipod version.


Thanks,

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


[sage-devel] Re: Naming runs of Sage

2012-01-31 Thread Jason Grout

On 1/31/12 2:23 AM, Ivan Andrus wrote:

On Jan 31, 2012, at 8:37 AM, Iftikhar Burhanuddin wrote:

Hi folks,

When I execute a Sage script using the 'nohup' command [1], for instance

nohup sage test.sage>  out.txt&

the process is listed in the 'top' command display as 'python'. How do
I give user-generated names to this 'python' process for the purpose
of identification?



According to [1] it requires the procname library which can be found at [2].  
Remember you'll need to install it in Sage's version of python, not the system 
one.  So do everything with `sage -python` or `sage -sh`.

-Ivan

[1] 
http://stackoverflow.com/questions/2255444/changing-the-process-name-of-a-python-script
[2] http://code.google.com/p/procname/



Cool! Do you happen to know if that prevents 'killall python' from 
working, then?


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


[sage-devel] Re: no space left under /tmp on sage.math

2012-01-31 Thread Jonathan Bober
"Instantly" makes sense. [Maybe everyone knows this.] If a process creates
a file, and that file is deleted (either by the original process or by some
other process), that file still exists and can be written to by that
process until it is closed, and it takes up space on the file system. (I'm
not sure if any other process would be able to access the file, but you
certainly wouldn't see it with ls.) You can see the effect by running
something like
#--
import sys
import os
import subprocess
import time

subprocess.call('df')
outfile = open('space', 'w')
 for n in xrange(1):
outfile.write("blah")
subprocess.call('df')
os.remove('space')
time.sleep(1)
subprocess.call('df')
 outfile.close()
time.sleep(1)
subprocess.call('df')
#--

Perhaps neither call to time.sleep() should not be necessary, but the
second can change the output on my system, which probably comes down to
some multiprocess race conditions, and the first is there to make sure that
the OS has actually had time to delete the file. Also, you could actually
move the os.remove() to right after the open(). (I think some parts of this
might work differently on windows, though.)

The output I get is:

bober@pafnuty:~/test$ python blah.py | grep sda
/dev/sda51179091124 726301120 392895580  65% /< before
writing
 /dev/sda51179091124 726692892 392503808  65% /< after
writing, before deleting
/dev/sda51179091124 726692892 392503808  65% /< after
deleting, before closing
/dev/sda51179091124 726301116 392895584  65% /< after
closing

So what is happening is that something, either in the doctesting system
itself, or in some part of sage that is tested, is creating and deleting
some files, but then the processes using those files are hanging, and the
files are never being closed, so the space is never being freed by the OS.
This would happen if, for example, the doctesting system used
tempfile.TemporaryFile() to create files which hold the output of child
processes, and then never closed those files, and then it hung at some
point. Or it could happen if a doctest did a similar thing, and then hung
and was never killed. (I'm not completely sure what will happen if a child
process creates a temporary file and then is killed, but I'm pretty sure
that the space will immediately be freed.)

I don't think this is from core dumps, as suggested on sage-devel, unless
they were specifically enabled, since they are disabled by default on
sage.math. Also, I don't think they would have this kind of behavior.

Anyway, I'm ccing sage-devel, since that is probably where any further
discussion of patchbot problems belongs.

On Tue, Jan 31, 2012 at 1:21 AM, Jeroen Demeyer wrote:

> On 2012-01-31 07:06, William Stein wrote:
> > then manually "kill -9"'d all of the robertwb jobs there, and
> > instantly got all of /tmp back.
> You literally mean "instantly" (as opposed to after some minutes/hours)?
>

-- 
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: iOS app is for sale

2012-01-31 Thread Ivan Andrus
On Jan 31, 2012, at 11:15 AM, Jason Grout wrote:
> On 1/31/12 2:16 AM, Ivan Andrus wrote:
>> I want to wait a few days to get any more bug reports and then I'll push 
>> another version (say, Friday) fixing this and anything else not too major.  
>> Of course it will take a few days to get through the review process, but I'm 
>> hoping it's faster the second time around.
> 
> Great work on this!  If you're looking for small things to fix, here is one: 
> can the default computations that come with the app not have errors as the 
> top two computations (or maybe not have errors at all in the saved 
> computations)?

Hmm.  That was deliberate so that people would see what errors looked like, but 
maybe that's not important.

> This is a bigger issue: when I type in a computation, I'm in the full screen 
> mode (i.e., the one computation is taking the full screen, with its output.  
> How do I stay in that mode when I submit the computation? All I see is the 
> Done button, which takes me back to the index listing.  I then have to click 
> on the computation again to examine the output.  It'd be great if I could 
> stay in that single-computation full screen, and maybe just have a "+" button 
> to make a new computation, which would clear the screen and let me input 
> another computation.  The only time I would go back to the index screen is to 
> look at the history of computations.

That's a good point.  I'll see if I can fix that.  I wasn't sure how to do that 
many things in the interface, but there has to be a way.

> Also: is it easy to make an ipad version?  I don't know how easy it is to 
> scale up from an ipod version.

I don't know.  I haven't really looked into that yet.  I think mostly it's a 
matter of creating the interface.  The "problem" is that the interface is so 
spartan right now I'm not sure how to "fill up" an iPad without looking silly. 
:-)  It's definitely on my list of things to think about though.  I'm also not 
familiar with what other iPad applications do since I don't have one.

-Ivan

-- 
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: Naming runs of Sage

2012-01-31 Thread Ivan Andrus

On Jan 31, 2012, at 11:18 AM, Jason Grout wrote:

> On 1/31/12 2:23 AM, Ivan Andrus wrote:
>> On Jan 31, 2012, at 8:37 AM, Iftikhar Burhanuddin wrote:
>>> Hi folks,
>>> 
>>> When I execute a Sage script using the 'nohup' command [1], for instance
>>> 
>>> nohup sage test.sage>  out.txt&
>>> 
>>> the process is listed in the 'top' command display as 'python'. How do
>>> I give user-generated names to this 'python' process for the purpose
>>> of identification?
>> 
>> 
>> According to [1] it requires the procname library which can be found at [2]. 
>>  Remember you'll need to install it in Sage's version of python, not the 
>> system one.  So do everything with `sage -python` or `sage -sh`.
>> 
>> -Ivan
>> 
>> [1] 
>> http://stackoverflow.com/questions/2255444/changing-the-process-name-of-a-python-script
>> [2] http://code.google.com/p/procname/
>> 
> 
> Cool! Do you happen to know if that prevents 'killall python' from working, 
> then?

I think so yes.  I haven't tried this exactly (it's linux only), but changing 
argv[0] in a little C program makes it so that killall only works with the new 
name.

-Ivan

-- 
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: iOS app is for sale

2012-01-31 Thread kcrisman

> Looks like I have to get the Bigger Cats to tame the Sage. :)
>
> Regards,
> Ifti
>
Luckily, we have a binary for you - or should, at least.  I'm not sure
if Georg has made a 10.4 Intel binary lately...

-- 
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: iOS app is for sale

2012-01-31 Thread kcrisman

> > Also: is it easy to make an ipad version?  I don't know how easy it is to 
> > scale up from an ipod version.
>
> I don't know.  I haven't really looked into that yet.  I think mostly it's a 
> matter of creating the interface.  The "problem" is that the interface is so 
> spartan right now I'm not sure how to "fill up" an iPad without looking 
> silly. :-)  It's definitely on my list of things to think about though.  I'm 
> also not familiar with what other iPad applications do since I don't have one.

Umm, I have only ever *looked* at the iPad version when using the
simulator on Xcode 3.  It worked fine.  It seemed to only require
switching the target to iPad on the left, if I recall (I don't have it
open now, of course).

- 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


[sage-devel] Re: iOS app is for sale

2012-01-31 Thread Jason Grout

On 1/31/12 5:27 AM, Ivan Andrus wrote:

On Jan 31, 2012, at 11:15 AM, Jason Grout wrote:

On 1/31/12 2:16 AM, Ivan Andrus wrote:

I want to wait a few days to get any more bug reports and then
I'll push another version (say, Friday) fixing this and anything
else not too major.  Of course it will take a few days to get
through the review process, but I'm hoping it's faster the second
time around.


Great work on this!  If you're looking for small things to fix,
here is one: can the default computations that come with the app
not have errors as the top two computations (or maybe not have
errors at all in the saved computations)?


Hmm.  That was deliberate so that people would see what errors looked
like, but maybe that's not important.


I figured, but I could also see it be a little unnerving to see that the 
top two computations were "mistakes", when it looked like there should 
have been a library of cool computations I could modify.





This is a bigger issue: when I type in a computation, I'm in the
full screen mode (i.e., the one computation is taking the full
screen, with its output.  How do I stay in that mode when I submit
the computation? All I see is the Done button, which takes me back
to the index listing.  I then have to click on the computation
again to examine the output.  It'd be great if I could stay in that
single-computation full screen, and maybe just have a "+" button to
make a new computation, which would clear the screen and let me
input another computation.  The only time I would go back to the
index screen is to look at the history of computations.


That's a good point.  I'll see if I can fix that.  I wasn't sure how
to do that many things in the interface, but there has to be a way.



Great!  I hope it's not hard, but I have no idea.



Also: is it easy to make an ipad version?  I don't know how easy it
is to scale up from an ipod version.


I don't know.  I haven't really looked into that yet.  I think mostly
it's a matter of creating the interface.  The "problem" is that the
interface is so spartan right now I'm not sure how to "fill up" an
iPad without looking silly. :-)  It's definitely on my list of things
to think about though.  I'm also not familiar with what other iPad
applications do since I don't have one.



The Sage output would fill up the ipad just fine in the single-cell 
screen.  Just a plain textbox at the top and leave all the rest of the 
room for the command output.  We could spice it up later, but that 
itself would make it much more usable on the ipad.  As for the index, 
just showing more index entries would be great.


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


[sage-devel] Re: webgl

2012-01-31 Thread Jason Grout

On 1/30/12 5:11 PM, Jason Grout wrote:

On 1/29/12 1:49 PM, Keshav Kini wrote:

Well, I wonder if we shouldn't ask around a bit more. If a day later you
found something better than pre3d, maybe soon you will find something
even better than three.js? :P As to who would be a good community to ask
about this stuff, though, I have no idea.


I sat down the other day and tried to write a simple three.js viewer.
The biggest frustration I had was the lack of documentation (for
example, apparently there is a way to specify a scene using json---what
is the format? I used the obj->json converter; but of course we don't
want to do that all the time. So I guess it's a matter of reading the
source for the JSON loader or reverse engineering the converter or the
converter output.)

Anyways, I or a student will likely look at this again in the next few
weeks, so if someone is working making a three.js backend, please ping
me (and certainly don't wait for me either!)


A three.js backend is now http://trac.sagemath.org/sage_trac/ticket/12402

Thanks,

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


Re: [sage-devel] iOS app is for sale

2012-01-31 Thread William Stein
On Tue, Jan 31, 2012 at 1:07 AM, Ivan Andrus  wrote:
> On Jan 31, 2012, at 9:24 AM, Justin C. Walker wrote:
>> On Jan 31, 2012, at 00:16 , Ivan Andrus wrote:
>>> On Jan 31, 2012, at 7:51 AM, Iftikhar Burhanuddin wrote:
 On Mon, Jan 30, 2012 at 9:52 PM, Justin C. Walker  wrote:
> Hi, Ifti,
> On Jan 30, 2012, at 21:36 , Iftikhar Burhanuddin wrote:
>> [snip]

 Thanks, Justin.

 Looks like I have to get the Bigger Cats to tame the Sage. :)
>>>
>>> Oops.  There's nothing that requires iOS 5, it's just the default.  I used 
>>> to build it XCode 3 and it worked on iOS 4.  Then I wanted to test on iOS 5 
>>> and so I had to upgrade to XCode 4 and the default for XCode 4 is iOS 5 and 
>>> I forgot to change it.  I've fixed it now, I think--I no longer have an iOS 
>>> 4 device to test.
>>>
>>> I want to wait a few days to get any more bug reports and then I'll push 
>>> another version (say, Friday) fixing this and anything else not too major.  
>>> Of course it will take a few days to get through the review process, but 
>>> I'm hoping it's faster the second time around.
>>
>> Cool.  I'd like to try it, but since I haven't upgraded to iCloud yet, I've 
>> been avoiding iOS 5.  I wasn't going to complain (since it's free :-}), but 
>> it's great to have the app available.
>
> But you're supposed to complain!  You're a curmudgeon.  It's what you're paid 
> for. :-)
>
>> Thanks for the hard work.
>
> I should definitely thank William (Sage foundation, NSF, whoever) for 
> providing the iPod that I tested this on... and maybe once or twice listened 
> to some podcasts on as well. :-)
>

You're welcome.  In fact, that was bought using Sage Foundation money
that was donated to
Sage by The Beatrice Yormark Fund.

 -- William

>> Justin
>>
>> --
>> Justin C. Walker, Curmudgeon at Large
>> Director
>> Institute for the Enhancement of the Director's Income
>> ---
>> Nobody knows the trouble I've been
>> ---
>
> -Ivan
>
> --
> 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


Re: [sage-devel] Re: webgl

2012-01-31 Thread William Stein
On Tue, Jan 31, 2012 at 6:27 AM, Jason Grout
 wrote:
> On 1/30/12 5:11 PM, Jason Grout wrote:
>>
>> On 1/29/12 1:49 PM, Keshav Kini wrote:
>>>
>>> Well, I wonder if we shouldn't ask around a bit more. If a day later you
>>> found something better than pre3d, maybe soon you will find something
>>> even better than three.js? :P As to who would be a good community to ask
>>> about this stuff, though, I have no idea.
>>
>>
>> I sat down the other day and tried to write a simple three.js viewer.
>> The biggest frustration I had was the lack of documentation (for
>> example, apparently there is a way to specify a scene using json---what
>> is the format? I used the obj->json converter; but of course we don't
>> want to do that all the time. So I guess it's a matter of reading the
>> source for the JSON loader or reverse engineering the converter or the
>> converter output.)
>>
>> Anyways, I or a student will likely look at this again in the next few
>> weeks, so if someone is working making a three.js backend, please ping
>> me (and certainly don't wait for me either!)
>
>
> A three.js backend is now http://trac.sagemath.org/sage_trac/ticket/12402

Thanks!!   I really want to work on this as soon as I get time, and
your initial work is massively appreciated.

 - William


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



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


[sage-devel] Re: webgl

2012-01-31 Thread Jason Grout

On 1/31/12 8:53 AM, William Stein wrote:

On Tue, Jan 31, 2012 at 6:27 AM, Jason Grout
  wrote:

On 1/30/12 5:11 PM, Jason Grout wrote:


On 1/29/12 1:49 PM, Keshav Kini wrote:


Well, I wonder if we shouldn't ask around a bit more. If a day later you
found something better than pre3d, maybe soon you will find something
even better than three.js? :P As to who would be a good community to ask
about this stuff, though, I have no idea.



I sat down the other day and tried to write a simple three.js viewer.
The biggest frustration I had was the lack of documentation (for
example, apparently there is a way to specify a scene using json---what
is the format? I used the obj->json converter; but of course we don't
want to do that all the time. So I guess it's a matter of reading the
source for the JSON loader or reverse engineering the converter or the
converter output.)

Anyways, I or a student will likely look at this again in the next few
weeks, so if someone is working making a three.js backend, please ping
me (and certainly don't wait for me either!)



A three.js backend is now http://trac.sagemath.org/sage_trac/ticket/12402


Thanks!!   I really want to work on this as soon as I get time, and
your initial work is massively appreciated.


No problem.  Here is the demo that I'm basing my work on:

http://sage.math.washington.edu/home/jason/threejsboilerplate/

You can get a screenshot by doing 'p' and can go fullscreen too.  It's 
pretty cool.  This was from the learningthreejs.com site.


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


[sage-devel] stackexchange's metrics

2012-01-31 Thread kcrisman
meta:I figure this belongs on sage-marketing, so reply there, but
putting on sage-devel.

Mathematica now has a Q&A site on Stack Exchange (the thing our askbot
is modeled on, I think).

http://area51.stackexchange.com/proposals/37304/mathematica

It's in public beta, only a few weeks old.

What I think is interesting about this is that there are these well-
defined metrics that SX has for what a "healthy" Q&A site (i.e., one
that will bring them ad revenue?) will be.  Here are a couple
interesting ones.

++
2.5 answers per question is good, only 1 answer per question needs
some work. In a healthy site, questions receive multiple answers and
the best answer is voted to the top.
++
(I disagree.  A really healthy site will have one completely correct
and useful answer showing up within minutes of being posted!  At least
for some types of questions.)
++
Eventually, 90% of a site's traffic should come from search engines.
++
(Really?  I wonder why; presumably they have thought about this.  I
know that almost all my LaTeX questions are now easy to find by
searching for the question and then picking the tex.SX.com link.)

Thoughts for ask.sagemath anyone has?  Just trying to get some
discussion going on how to improve this side of things.

- 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


[sage-devel] Re: [sage-marketing] stackexchange's metrics

2012-01-31 Thread William Stein
On Tue, Jan 31, 2012 at 7:27 AM, kcrisman  wrote:
> meta:I figure this belongs on sage-marketing, so reply there, but
> putting on sage-devel.
>
> Mathematica now has a Q&A site on Stack Exchange (the thing our askbot
> is modeled on, I think).
>
> http://area51.stackexchange.com/proposals/37304/mathematica
>
> It's in public beta, only a few weeks old.
>
> What I think is interesting about this is that there are these well-
> defined metrics that SX has for what a "healthy" Q&A site (i.e., one
> that will bring them ad revenue?) will be.

We aren't trying to generate ad revenue... so ?

>   Here are a couple
> interesting ones.
>
> ++
> 2.5 answers per question is good, only 1 answer per question needs
> some work. In a healthy site, questions receive multiple answers and
> the best answer is voted to the top.
> ++
> (I disagree.  A really healthy site will have one completely correct
> and useful answer showing up within minutes of being posted!  At least
> for some types of questions.)
> ++
> Eventually, 90% of a site's traffic should come from search engines.
> ++
> (Really?  I wonder why; presumably they have thought about this.  I
> know that almost all my LaTeX questions are now easy to find by
> searching for the question and then picking the tex.SX.com link.)
>
> Thoughts for ask.sagemath anyone has?  Just trying to get some
> discussion going on how to improve this side of things.
>
> - kcrisman
>
> --
> You received this message because you are subscribed to the Google group 
> "sage-marketing".
> To post to this group, send email to sage-market...@googlegroups.com
> To unsubscribe from this group, send email to 
> sage-marketing+unsubscr...@googlegroups.com
> For more options, visit this group at 
> http://groups.google.com/group/sage-marketing
> More about Sage: 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


Re: [sage-devel] Re: iOS app is for sale

2012-01-31 Thread Ivan Andrus
On Jan 31, 2012, at 2:56 PM, Jason Grout wrote:
> On 1/31/12 5:27 AM, Ivan Andrus wrote:
>> On Jan 31, 2012, at 11:15 AM, Jason Grout wrote:
>>> On 1/31/12 2:16 AM, Ivan Andrus wrote:
 I want to wait a few days to get any more bug reports and then
 I'll push another version (say, Friday) fixing this and anything
 else not too major.  Of course it will take a few days to get
 through the review process, but I'm hoping it's faster the second
 time around.
>>> 
>>> Great work on this!  If you're looking for small things to fix,
>>> here is one: can the default computations that come with the app
>>> not have errors as the top two computations (or maybe not have
>>> errors at all in the saved computations)?
>> 
>> Hmm.  That was deliberate so that people would see what errors looked
>> like, but maybe that's not important.
> 
> I figured, but I could also see it be a little unnerving to see that the top 
> two computations were "mistakes", when it looked like there should have been 
> a library of cool computations I could modify.

Yes, I can definitely see that now. :-) 

On a related topic what other cool (but short) examples should be included?  
For example, I would like something from number theory (about which I know 
nothing), and maybe an ODE or something.  A few to show off the breadth of Sage.

>>> This is a bigger issue: when I type in a computation, I'm in the
>>> full screen mode (i.e., the one computation is taking the full
>>> screen, with its output.  How do I stay in that mode when I submit
>>> the computation? All I see is the Done button, which takes me back
>>> to the index listing.  I then have to click on the computation
>>> again to examine the output.  It'd be great if I could stay in that
>>> single-computation full screen, and maybe just have a "+" button to
>>> make a new computation, which would clear the screen and let me
>>> input another computation.  The only time I would go back to the
>>> index screen is to look at the history of computations.
>> 
>> That's a good point.  I'll see if I can fix that.  I wasn't sure how
>> to do that many things in the interface, but there has to be a way.
> 
> Great!  I hope it's not hard, but I have no idea.

We'll see.  I already have a few ideas.

>>> Also: is it easy to make an ipad version?  I don't know how easy it
>>> is to scale up from an ipod version.
>> 
>> I don't know.  I haven't really looked into that yet.  I think mostly
>> it's a matter of creating the interface.  The "problem" is that the
>> interface is so spartan right now I'm not sure how to "fill up" an
>> iPad without looking silly. :-)  It's definitely on my list of things
>> to think about though.  I'm also not familiar with what other iPad
>> applications do since I don't have one.
>> 
> 
> The Sage output would fill up the ipad just fine in the single-cell screen.  
> Just a plain textbox at the top and leave all the rest of the room for the 
> command output.  We could spice it up later, but that itself would make it 
> much more usable on the ipad.  As for the index, just showing more index 
> entries would be great.


That sounds like it should be easy then.

-Ivan

-- 
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: is_singular method for matrices

2012-01-31 Thread javier
Hi all,

this is now #12370, patch ready for review at [1].

When making the proposed change I spotted an inconsistency in
the error messages when calling A.determinant() for A a non-square
matrix. If A is defined over QQ the error message says

ValueError: incompatible matrix dimensions

whereas over any other ring or field

ValueError: self must be a square matrix

so I changed the error message over QQ and the doctests using it
to be consistent with all the other rings.

Cheers,
Javier

[1]: http://trac.sagemath.org/sage_trac/ticket/12370

-- 
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: iOS app is for sale

2012-01-31 Thread William Stein
>
> On a related topic what other cool (but short) examples should be included?  
> For example, I would like something from number theory (about which I know 
> nothing), and maybe an ODE or something.  A few to show off the breadth of 
> Sage.
>

factor(2012)

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


[sage-devel] Re: webgl

2012-01-31 Thread Jonathan
That looks much better than the previous webgl stuff!

Jonathan

On Jan 31, 8:57 am, Jason Grout  wrote:

>
> No problem.  Here is the demo that I'm basing my work on:
>
> http://sage.math.washington.edu/home/jason/threejsboilerplate/
>
> You can get a screenshot by doing 'p' and can go fullscreen too.  It's
> pretty cool.  This was from the learningthreejs.com site.
>
> 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


[sage-devel] Re: stackexchange's metrics

2012-01-31 Thread Volker Braun
On Tuesday, January 31, 2012 7:27:48 AM UTC-8, kcrisman wrote:
>
> 2.5 answers per question is good, only 1 answer per question needs 
> some work. In a healthy site, questions receive multiple answers and 
> the best answer is voted to the top.


I would have thought this is uncontroversial. If you have only one answer 
then you can't up/downvote. If you strive for one correct answer per 
question then you want a support ticketing system, not stackexchange.

Eventually, 90% of a site's traffic should come from search engines. 
>

Since stackexchange doesn't operate their own search this also sounds like 
a no-brainer. If you want to collaborate on a manual that is supposed to be 
read in a linear manner then you want a wiki, not stackexchange.


-- 
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: no space left under /tmp on sage.math

2012-01-31 Thread Volker Braun
If you get the space back after a kill -9 then it must be open file 
descriptors, as Jonathan said. Robert or root should do a 'lsof' after 
running the buildbot for a while to see which file descriptors are open.

-- 
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] Strange doctest failure

2012-01-31 Thread Julien Puydt

Hi,

I was patching happily, when I was hit by this:

sage -t --long "devel/sage-main/sage/rings/arith.py"
**
File "/home/jpuydt/sage-4.8/devel/sage-main/sage/rings/arith.py", line 3061:
sage: n(binomial(0.5r, 5),prec=53)
Expected:
0.02734375
Got:
doctest:1172: DeprecationWarning: Substitution using function-call 
syntax and unnamed arguments is deprecated and will be removed from a 
future release of Sage; you can use named arguments instead, like 
EXPR(x=..., y=...)

0.027343751


which is pretty strange since when I type the same command in sage 
itself, things work like a charm:


sage: n(binomial(0.5r, 5),prec=53)
0.02734375

As you'll see, I get both a deprecation warning... and a different result!

What am I missing?

Snark on #sagemath

--
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-5.0.x and OS X 10.7 Lion

2012-01-31 Thread R. Andrew Ohana
On Mon, Jan 30, 2012 at 10:04, John H Palmieri  wrote:
>
> On Tuesday, January 17, 2012 1:59:45 PM UTC-8, William wrote:
>>
>> On Tue, Jan 17, 2012 at 1:39 PM, William Stein  wrote:
>>
>> > On Mon, Jan 16, 2012 at 3:43 PM, William Stein  wrote:
>> >> On Mon, Jan 16, 2012 at 9:26 AM, John H Palmieri 
>> >> wrote:
>> >>>
>> >>>
>> >>> On Monday, January 16, 2012 7:42:49 AM UTC-8, William wrote:
>> 
>>  Hi,
>> 
>>  A major blocker for Sage-5.0 is supporting OS X (version 10.7 -- the
>>  version that has been out for months now).
>> 
>>  Fortunately, it is now "relatively easy" to build sage-5.0.beta1 on
>>  OS
>>  X 10.7 with XCode 4.x, and have it start up.
>> >>
>> >> After building Sage on OS X 10.7, "make test" did this:
>> >
>> > For the record, running tests with "sage -t devel/sage/sage" yields
>> > hundred(s) of failing files:
>> >
>> >   http://wstein.org/home/wstein/tmp/test-sage-5.0.beta1-osx10.7.txt
>> >
>> > It could be that most of these boil down to some code at the core of
>> > PARI (the bezout function) being miscompiled.
>> >
>> > There is a discussion about this from August 2011 here:
>> >
>> >   http://pari.math.u-bordeaux.fr/archives/pari-dev-1108/msg0.html
>> >
>> > It unfortunately appears based on the mailing list -- and searching
>> > through the ** 5 months ** since then -- that nothing at all was done
>> > to try to fix the problem, even though I had setup access to 10.7 for
>> > the Pari developers.   Probably the main problem is that the machine I
>> > setup -- sqrt5.math.washington.edu -- is on the CS network, and for
>> > some reason it keeps getting kicked off.
>> >
>> > This really sucks.   Maybe I can rewrite their bezout to get around
>> > the problem.
>>
>> Another option is to turn of optimization (-O0) when building part of
>> PARI under XCode 4.x, since the problem is bad compiler optimization.
>>   I just tried, export SAGE_DEBUG="yes", then building PARI with
>> SAGE_CHECK="yes", and I get: "The PARI self-tests all passed".
>>
>> So something based on optimization flags is the workaround I'll pursue
>> for now.   Something that is slightly slower than optimal is way
>> better than infinitely slower.
>
>
> I've been trying to build Sage with OS X Lion over the past few days, and
> things are going pretty well: there are a few doctest failures, but I think
> most are numerical noise.  Most spkgs build just fine, but because of bugs
> in Apple's compiler, a few -- pari, gsl, symmetrica -- have problems unless
> we modify them.  So I propose the following modifications in the
> spkg-install scripts for those packages:
>
>  - check to see if running Lion, and if so
>  - check to see if /usr/bin/gcc-4.2 exists.  this might be available from an
> older installation of XCode, or it can be installed using the gcc package
> Georg posted a link to: http://r.research.att.com/tools/.  If it's there,
> set CC=gcc-4.2.
>  - otherwise, turn off optimization (compile with -O0) for those packages.
> This seems to avoid the bugs, although it will slow down those specific
> pieces of code.
>
> Opinions?
Do we know which files build incorrectly, we should only set the flag
for those (and not the whole library). Also, we should see if -O1
works too.
>
> We also seem to need to delete the file
> SAGE_ROOT/local/lib/python/config/libpython2.7.a.  Any reasons why doing
> this is a bad idea?  (See
> .)
>
> There are still a few remaining problems with OS X Lion, like self-tests for
> cvxopt, but maybe someone can figure out how to fix them.
>
> See  for the trac
> metaticket about building Sage on Lion.
>
> --
> John
>
> --
> To post to this group, send an email to sage-devel@googlegroups.com
> To unsubscribe from this group, send an email to
> sage-devel+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/sage-devel
> URL: http://www.sagemath.org

I've started looking into the difficulties of getting sage to build
with clang (on lion), and have made some progress on the sage
libraries.

Using CC=clang, CXX=clang++, and SAGE_CHECK=yes for all spkgs except

eclib
givaro
libm4rie
gap
lcalc
linbox
matplotlib
polybori
pynac
libfplll
singular
ratpoints
sage

where I used gcc instead (all Xcode 4). Most of the spkgs not listed
here that don't just build only needed some flags set (the exceptions
being python, which needed a patch, and ecm, which will probably need
a patch to the asm).

I've built sage with roughly the same doctest failures as you get when
you turn off optimization for pari and symmetrica, although there are
likely some spkgs that aren't respecting CC and CXX. So far I've found
that flint, flintqs, ratpoints, f2c, and a small part of sage haven't
been, but thanfully all of them have been trivial fixes (except for
the last one, I haven't yet found where exactly it is calling gcc).

(Beyond the issue o

Re: [sage-devel] Re: sage-5.0.x and OS X 10.7 Lion

2012-01-31 Thread Volker Braun
On Tuesday, January 31, 2012 1:01:41 PM UTC-8, R. Andrew Ohana wrote:
>
> (Beyond the issue of fortran) I'm not sure if it will be possible to
> build all of the sage libraries with clang. For instance, it currently
> doesn't yet support nested functions, which I know at least ratpoints
> uses.
>
C does't have nested functions, this is a GNU extension. Any code that uses 
them should be rewritten to be standards-compliant C.
 

>

-- 
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-5.0.x and OS X 10.7 Lion

2012-01-31 Thread R. Andrew Ohana
On Tue, Jan 31, 2012 at 13:13, Volker Braun  wrote:
> On Tuesday, January 31, 2012 1:01:41 PM UTC-8, R. Andrew Ohana wrote:
>>
>> (Beyond the issue of fortran) I'm not sure if it will be possible to
>> build all of the sage libraries with clang. For instance, it currently
>> doesn't yet support nested functions, which I know at least ratpoints
>> uses.
>
> C does't have nested functions, this is a GNU extension.

True, however clang aims to be gcc compatible, and intends to support
nested functions at some (indeterminate) point in the future.

> Any code that uses
> them should be rewritten to be standards-compliant C.
>
>
> --
> 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



-- 
Andrew

-- 
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-5.0.x and OS X 10.7 Lion

2012-01-31 Thread John H Palmieri


On Tuesday, January 31, 2012 1:01:41 PM UTC-8, R. Andrew Ohana wrote:
>
> On Mon, Jan 30, 2012 at 10:04, John H Palmieri  
> wrote:
> >
> > On Tuesday, January 17, 2012 1:59:45 PM UTC-8, William wrote:
> >>
> >> On Tue, Jan 17, 2012 at 1:39 PM, William Stein  
> wrote:
> >>
> >> > On Mon, Jan 16, 2012 at 3:43 PM, William Stein  
> wrote:
> >> >> On Mon, Jan 16, 2012 at 9:26 AM, John H Palmieri 
> >> >> wrote:
> >> >>>
> >> >>>
> >> >>> On Monday, January 16, 2012 7:42:49 AM UTC-8, William wrote:
> >> 
> >>  Hi,
> >> 
> >>  A major blocker for Sage-5.0 is supporting OS X (version 10.7 -- 
> the
> >>  version that has been out for months now).
> >> 
> >>  Fortunately, it is now "relatively easy" to build sage-5.0.beta1 on
> >>  OS
> >>  X 10.7 with XCode 4.x, and have it start up.
> >> >>
> >> >> After building Sage on OS X 10.7, "make test" did this:
> >> >
> >> > For the record, running tests with "sage -t devel/sage/sage" yields
> >> > hundred(s) of failing files:
> >> >
> >> >   http://wstein.org/home/wstein/tmp/test-sage-5.0.beta1-osx10.7.txt
> >> >
> >> > It could be that most of these boil down to some code at the core of
> >> > PARI (the bezout function) being miscompiled.
> >> >
> >> > There is a discussion about this from August 2011 here:
> >> >
> >> >   http://pari.math.u-bordeaux.fr/archives/pari-dev-1108/msg0.html
> >> >
> >> > It unfortunately appears based on the mailing list -- and searching
> >> > through the ** 5 months ** since then -- that nothing at all was done
> >> > to try to fix the problem, even though I had setup access to 10.7 for
> >> > the Pari developers.   Probably the main problem is that the machine I
> >> > setup -- sqrt5.math.washington.edu -- is on the CS network, and for
> >> > some reason it keeps getting kicked off.
> >> >
> >> > This really sucks.   Maybe I can rewrite their bezout to get around
> >> > the problem.
> >>
> >> Another option is to turn of optimization (-O0) when building part of
> >> PARI under XCode 4.x, since the problem is bad compiler optimization.
> >>   I just tried, export SAGE_DEBUG="yes", then building PARI with
> >> SAGE_CHECK="yes", and I get: "The PARI self-tests all passed".
> >>
> >> So something based on optimization flags is the workaround I'll pursue
> >> for now.   Something that is slightly slower than optimal is way
> >> better than infinitely slower.
> >
> >
> > I've been trying to build Sage with OS X Lion over the past few days, and
> > things are going pretty well: there are a few doctest failures, but I 
> think
> > most are numerical noise.  Most spkgs build just fine, but because of 
> bugs
> > in Apple's compiler, a few -- pari, gsl, symmetrica -- have problems 
> unless
> > we modify them.  So I propose the following modifications in the
> > spkg-install scripts for those packages:
> >
> >  - check to see if running Lion, and if so
> >  - check to see if /usr/bin/gcc-4.2 exists.  this might be available 
> from an
> > older installation of XCode, or it can be installed using the gcc package
> > Georg posted a link to: http://r.research.att.com/tools/.  If it's 
> there,
> > set CC=gcc-4.2.
> >  - otherwise, turn off optimization (compile with -O0) for those 
> packages.
> > This seems to avoid the bugs, although it will slow down those specific
> > pieces of code.
> >
> > Opinions?
> Do we know which files build incorrectly, we should only set the flag
> for those (and not the whole library). 


I tried that and still got self-test failures.  I didn't try all possible 
combinations of compiling some files with -O3 and some with -O0 until tests 
passed.
 

> Also, we should see if -O1
> works too.
>

No, it doesn't.  I tried that. 

[snip]

I've started looking into the difficulties of getting sage to build
> with clang (on lion), and have made some progress on the sage
> libraries.
>
> Using CC=clang, CXX=clang++, and SAGE_CHECK=yes for all spkgs except
>
I thought I had tried this with pari and had failures, but now it seems to 
work.  In an existing Sage build, installing cvxopt this way doesn't work 
for me -- I get self test failures -- but maybe setting CC=clang (etc.) and 
building the whole thing from scratch will work better.

Please keep working on this; it sounds like you're getting somewhere.

-- 
John

-- 
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an email to 
sage-devel+unsubscr...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/sage-devel
URL: http://www.sagemath.org


Re: [sage-devel] Re: sage-5.0.x and OS X 10.7 Lion

2012-01-31 Thread Volker Braun
What I'm trying to say is: Upstream needs to be informed that they 
shouldn't use non-standard C extensions. Nested functions especially are a 
bad design choice in a world that is moving away from executable stacks.

-- 
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-5.0.x and OS X 10.7 Lion

2012-01-31 Thread Dr. David Kirkby

On 01/31/12 09:20 PM, R. Andrew Ohana wrote:

On Tue, Jan 31, 2012 at 13:13, Volker Braun  wrote:

On Tuesday, January 31, 2012 1:01:41 PM UTC-8, R. Andrew Ohana wrote:


(Beyond the issue of fortran) I'm not sure if it will be possible to
build all of the sage libraries with clang. For instance, it currently
doesn't yet support nested functions, which I know at least ratpoints
uses.


C does't have nested functions, this is a GNU extension.


True, however clang aims to be gcc compatible, and intends to support
nested functions at some (indeterminate) point in the future.


But it makes the code unportable. What hope do we have with the Sun/Oracle 
compiler if idiots use non-standard C? What hope do we have if we try to build 
on Windows at some point in the future using a native compiler? All these GNU 
extensions are a headache for everyone except the linux community.


If there was not so much poor code in Sage, building with the Sun compiler would 
be possible, but it rejects much of the code.



Any code that uses
them should be rewritten to be standards-compliant C.


Agreed.

--
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing in e-mail?

--
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-5.0.x and OS X 10.7 Lion

2012-01-31 Thread R. Andrew Ohana
On Tue, Jan 31, 2012 at 15:52, Dr. David Kirkby  wrote:
> On 01/31/12 09:20 PM, R. Andrew Ohana wrote:
>>
>> On Tue, Jan 31, 2012 at 13:13, Volker Braun  wrote:
>>>
>>> On Tuesday, January 31, 2012 1:01:41 PM UTC-8, R. Andrew Ohana wrote:


 (Beyond the issue of fortran) I'm not sure if it will be possible to
 build all of the sage libraries with clang. For instance, it currently
 doesn't yet support nested functions, which I know at least ratpoints
 uses.
>>>
>>>
>>> C does't have nested functions, this is a GNU extension.
>>
>>
>> True, however clang aims to be gcc compatible, and intends to support
>> nested functions at some (indeterminate) point in the future.
>
>
> But it makes the code unportable. What hope do we have with the Sun/Oracle
> compiler if idiots use non-standard C? What hope do we have if we try to
> build on Windows at some point in the future using a native compiler? All
> these GNU extensions are a headache for everyone except the linux community.
>
> If there was not so much poor code in Sage, building with the Sun compiler
> would be possible, but it rejects much of the code.
>
>
>>> Any code that uses
>>> them should be rewritten to be standards-compliant C.
>
>
> Agreed.

To clarify, I was not arguing for using GNU extensions, I was merely
trying to point out what clang intends to do, and some current
troubles with it. I agree that we should have standards-compliant C,
which is part of the reason I started working on a clang port, since
it is more restrict in this regards that gcc (but less so than other c
compilers).
>
> --
> A: Because it messes up the order in which people normally read text.
> Q: Why is top-posting such a bad thing?
> A: Top-posting.
> Q: What is the most annoying thing in e-mail?
>
>
> --
> 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



-- 
Andrew

-- 
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-5.0.x and OS X 10.7 Lion

2012-01-31 Thread R. Andrew Ohana
On Tue, Jan 31, 2012 at 14:13, John H Palmieri  wrote:
>
>
> On Tuesday, January 31, 2012 1:01:41 PM UTC-8, R. Andrew Ohana wrote:
>>
>> On Mon, Jan 30, 2012 at 10:04, John H Palmieri 
>> wrote:
>> >
>> > On Tuesday, January 17, 2012 1:59:45 PM UTC-8, William wrote:
>> >>
>> >> On Tue, Jan 17, 2012 at 1:39 PM, William Stein 
>> >> wrote:
>> >>
>> >> > On Mon, Jan 16, 2012 at 3:43 PM, William Stein 
>> >> > wrote:
>> >> >> On Mon, Jan 16, 2012 at 9:26 AM, John H Palmieri 
>>
>> >> >> wrote:
>> >> >>>
>> >> >>>
>> >> >>> On Monday, January 16, 2012 7:42:49 AM UTC-8, William wrote:
>> >> 
>> >>  Hi,
>> >> 
>> >>  A major blocker for Sage-5.0 is supporting OS X (version 10.7 --
>> >>  the
>> >>  version that has been out for months now).
>> >> 
>> >>  Fortunately, it is now "relatively easy" to build sage-5.0.beta1
>> >>  on
>> >>  OS
>> >>  X 10.7 with XCode 4.x, and have it start up.
>> >> >>
>> >> >> After building Sage on OS X 10.7, "make test" did this:
>> >> >
>> >> > For the record, running tests with "sage -t devel/sage/sage" yields
>> >> > hundred(s) of failing files:
>> >> >
>> >> >   http://wstein.org/home/wstein/tmp/test-sage-5.0.beta1-osx10.7.txt
>> >> >
>> >> > It could be that most of these boil down to some code at the core of
>> >> > PARI (the bezout function) being miscompiled.
>> >> >
>> >> > There is a discussion about this from August 2011 here:
>> >> >
>> >> >   http://pari.math.u-bordeaux.fr/archives/pari-dev-1108/msg0.html
>> >> >
>> >> > It unfortunately appears based on the mailing list -- and searching
>> >> > through the ** 5 months ** since then -- that nothing at all was done
>> >> > to try to fix the problem, even though I had setup access to 10.7 for
>> >> > the Pari developers.   Probably the main problem is that the machine
>> >> > I
>> >> > setup -- sqrt5.math.washington.edu -- is on the CS network, and for
>> >> > some reason it keeps getting kicked off.
>> >> >
>> >> > This really sucks.   Maybe I can rewrite their bezout to get around
>> >> > the problem.
>> >>
>> >> Another option is to turn of optimization (-O0) when building part of
>> >> PARI under XCode 4.x, since the problem is bad compiler optimization.
>> >>   I just tried, export SAGE_DEBUG="yes", then building PARI with
>> >> SAGE_CHECK="yes", and I get: "The PARI self-tests all passed".
>> >>
>> >> So something based on optimization flags is the workaround I'll pursue
>> >> for now.   Something that is slightly slower than optimal is way
>> >> better than infinitely slower.
>> >
>> >
>> > I've been trying to build Sage with OS X Lion over the past few days,
>> > and
>> > things are going pretty well: there are a few doctest failures, but I
>> > think
>> > most are numerical noise.  Most spkgs build just fine, but because of
>> > bugs
>> > in Apple's compiler, a few -- pari, gsl, symmetrica -- have problems
>> > unless
>> > we modify them.  So I propose the following modifications in the
>> > spkg-install scripts for those packages:
>> >
>> >  - check to see if running Lion, and if so
>> >  - check to see if /usr/bin/gcc-4.2 exists.  this might be available
>> > from an
>> > older installation of XCode, or it can be installed using the gcc
>> > package
>> > Georg posted a link to: http://r.research.att.com/tools/.  If it's
>> > there,
>> > set CC=gcc-4.2.
>> >  - otherwise, turn off optimization (compile with -O0) for those
>> > packages.
>> > This seems to avoid the bugs, although it will slow down those specific
>> > pieces of code.
>> >
>> > Opinions?
>> Do we know which files build incorrectly, we should only set the flag
>> for those (and not the whole library).
>
>
> I tried that and still got self-test failures.  I didn't try all possible
> combinations of compiling some files with -O3 and some with -O0 until tests
> passed.

Well that is fair :)
>
>>
>> Also, we should see if -O1
>> works too.
>
>
> No, it doesn't.  I tried that.

Too bad
>
> [snip]
>
>> I've started looking into the difficulties of getting sage to build
>> with clang (on lion), and have made some progress on the sage
>> libraries.
>>
>> Using CC=clang, CXX=clang++, and SAGE_CHECK=yes for all spkgs except
>
> I thought I had tried this with pari and had failures, but now it seems to
> work.  In an existing Sage build, installing cvxopt this way doesn't work
> for me -- I get self test failures -- but maybe setting CC=clang (etc.) and
> building the whole thing from scratch will work better.

Hmm, now I'm getting self test failures, however the package seems to
still be installing for me. I wasn't paying attention during the whole
build process, so this may have happened before as well.
>
> Please keep working on this; it sounds like you're getting somewhere.

I plan to, although I think I'm going to move to working on a system
where sage works (such as sage.math), and then hopefully the changes I
make there apply to Lion.

You should continue working on the lion issues. If you need/want,
Wil