[sage-support] Plot saving segfault on 6.8, works on 6.7 (same machine, same config)
Hello again, I have fresh build of sage 6.8 that (after setting locale) passed all tests. Unfortunately when I tried to build my book which works with sage 6.7 built on same machine with same options - I'm getting segfault. It occurs when I try to save the plot into svg for the second time after using matplotlib.rc('text', usetex=True) - if I don't make matplotlib use TeX, saving to svg works. If I write png after setting use TeX, it also works. Using savefig from matplotlib also fails, also when using ./sage -ipython. Full output in http://pastebin.com/ZfEj7WgY including gdb. Log from installing matplotlib: http://pastebin.com/qFY8y8wN Machine is Arch Linux (last updated 2 years ago), gcc 4.8.0. Failing code: sage: import matplotlib sage: matplotlib.rc('text', usetex=True) sage: plot(sin).save('test.svg') # works sage: plot(sin).save('test.svg') # segfault Tried with and without custom CFLAGS optimizations - same effect. Any idea what it might be? Smells like freetype, but on sage 6.7 everything works. Thanks in advance, Andrzej. -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-support+unsubscr...@googlegroups.com. To post to this group, send email to sage-support@googlegroups.com. Visit this group at http://groups.google.com/group/sage-support. For more options, visit https://groups.google.com/d/optout.
[sage-support] Re: Is horner available in sage?
Not so much time needed to google "sagemath Horner" in order to get an answer... # http://doc.sagemath.org/html/en/reference/calculus/sage/calculus/wester.html R = PolynomialRing(QQ,5,names='a') S. = PolynomialRing(R) p = S(list(R.gens()))*x print "p = ",p.substitute(a0=17,a1=3,a2=4,a3=6,a4=8) restore('x') #p(x) f(x) = p.substitute(a0=17,a1=3,a2=4,a3=6,a4=8); print "f : ",f working just now in the sagemath cloud : p = 8*x^5 + 6*x^4 + 4*x^3 + 3*x^2 + 17*xf : x |--> ((2*((4*x + 3)*x + 2)*x + 3)*x + 17)*x Dominique. -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-support+unsubscr...@googlegroups.com. To post to this group, send email to sage-support@googlegroups.com. Visit this group at http://groups.google.com/group/sage-support. For more options, visit https://groups.google.com/d/optout.
[sage-support] Is horner available in sage?
Hi, horner is available in matlab. I don't find it in sage. Is horner available in sage? Thanks. http://www.mathworks.com/help/symbolic/horner.html -- Regards, Peng -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-support+unsubscr...@googlegroups.com. To post to this group, send email to sage-support@googlegroups.com. Visit this group at http://groups.google.com/group/sage-support. For more options, visit https://groups.google.com/d/optout.
[sage-support] Re: sage-6.8 - two failed tests for R interface
Just a follow up, when built with locale set, all tests passed - including one with multiply returned completions. Regards, Andrzej. -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-support+unsubscr...@googlegroups.com. To post to this group, send email to sage-support@googlegroups.com. Visit this group at http://groups.google.com/group/sage-support. For more options, visit https://groups.google.com/d/optout.
[sage-support] Re: sage-6.8 - two failed tests for R interface
Good point, we SHOULD always set LC_ALL=C before calling interpreters whose output we are parsing but we don't systematically test it. On Tuesday, July 28, 2015 at 9:26:56 AM UTC+2, Andrzej Giniewicz wrote: > > This is built from scratch on Arch Linux (not updated since 2013). GCC > is 4.8. This is compile script I use on this machine (earlier 6.7 > worked with same build script): http://pastebin.com/gnh4Qivm > > I had other issue with build before but it was easily fixed. It > stopped when building patch with: > > Found local metadata for patch-2.7.1 > /usr/bin/env: python: No such file or directory > Found local metadata for patch-2.7.1 > /usr/bin/env: python: No such file or directory > > It was fixed by creating symlink from /usr/bin/python2 to > /usr/local/bin/python (as this machine does not have python 3 > installed, which is default on Arch). Anyway this shouldn't be realted > to R tests. > > I checked those cases that failed in compiled version trough console, > and this is result: http://pastebin.com/LtDKUF37 - on running system, > completions worked. About library, I found out that this is due to > locale (which is pl_PL.UTF-8 on this machine): > > sage: r.eval('require(foobar)') > "\xc5\x81adowanie wymaganego pakietu: foobar\nKomunikat > ostrzegawczy:\nW poleceniu 'library(package, lib.loc = lib.loc, > character.only = TRUE, logical.return = TRUE, ':\n nie ma pakietu o > nazwie \xe2\x80\x98foobar\xe2\x80\x99" > > As you see, in this locale there is no space before library( which is > checked in r.library function. Probably the "if ' library(' in ret:" > should be changed to regular expression matching non-word character > (instead of space) and then 'library(' - or something similar. For > now, I set locale to en_US.UTF-8 in build script. > > Any ideas why completions might work in installed system and not > during test? Any logs that might help? Would be happy to send. Right > now I'm doing fresh rebuild with locale set. > > Regards, > Andrzej. > > On Tue, Jul 28, 2015 at 1:14 AM, Volker Braun > wrote: > > Haven't seen that one before. Did you build from scratch? Which OS? > > > > > > > > On Monday, July 27, 2015 at 10:07:42 PM UTC+2, Andrzej Giniewicz wrote: > >> > >> Hello, > >> > >> today I compiled sage-6.8 on my machine. Got two failures in R > >> interface - very strange ones I must say - > >> http://pastebin.com/Lvt6Lqt6 - all other tests pass. > >> > >> Anyone seen such error? In completions each method is listed twice and > >> importing foobar does not raise exception. > >> > >> Regards, > >> Andrzej. > -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-support+unsubscr...@googlegroups.com. To post to this group, send email to sage-support@googlegroups.com. Visit this group at http://groups.google.com/group/sage-support. For more options, visit https://groups.google.com/d/optout.
[sage-support] Re: sage-6.8 - two failed tests for R interface
This is built from scratch on Arch Linux (not updated since 2013). GCC is 4.8. This is compile script I use on this machine (earlier 6.7 worked with same build script): http://pastebin.com/gnh4Qivm I had other issue with build before but it was easily fixed. It stopped when building patch with: Found local metadata for patch-2.7.1 /usr/bin/env: python: No such file or directory Found local metadata for patch-2.7.1 /usr/bin/env: python: No such file or directory It was fixed by creating symlink from /usr/bin/python2 to /usr/local/bin/python (as this machine does not have python 3 installed, which is default on Arch). Anyway this shouldn't be realted to R tests. I checked those cases that failed in compiled version trough console, and this is result: http://pastebin.com/LtDKUF37 - on running system, completions worked. About library, I found out that this is due to locale (which is pl_PL.UTF-8 on this machine): sage: r.eval('require(foobar)') "\xc5\x81adowanie wymaganego pakietu: foobar\nKomunikat ostrzegawczy:\nW poleceniu 'library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE, ':\n nie ma pakietu o nazwie \xe2\x80\x98foobar\xe2\x80\x99" As you see, in this locale there is no space before library( which is checked in r.library function. Probably the "if ' library(' in ret:" should be changed to regular expression matching non-word character (instead of space) and then 'library(' - or something similar. For now, I set locale to en_US.UTF-8 in build script. Any ideas why completions might work in installed system and not during test? Any logs that might help? Would be happy to send. Right now I'm doing fresh rebuild with locale set. Regards, Andrzej. On Tue, Jul 28, 2015 at 1:14 AM, Volker Braun wrote: > Haven't seen that one before. Did you build from scratch? Which OS? > > > > On Monday, July 27, 2015 at 10:07:42 PM UTC+2, Andrzej Giniewicz wrote: >> >> Hello, >> >> today I compiled sage-6.8 on my machine. Got two failures in R >> interface - very strange ones I must say - >> http://pastebin.com/Lvt6Lqt6 - all other tests pass. >> >> Anyone seen such error? In completions each method is listed twice and >> importing foobar does not raise exception. >> >> Regards, >> Andrzej. -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-support+unsubscr...@googlegroups.com. To post to this group, send email to sage-support@googlegroups.com. Visit this group at http://groups.google.com/group/sage-support. For more options, visit https://groups.google.com/d/optout.