Re: [sage-devel] Re: Sage runs in Window's 10's new Unix subsystem
On Friday, May 13, 2016 at 11:57:50 PM UTC-7, Ralf Stephan wrote: > > Quote from the article: > "WSL also doesn't include X Windows or any other graphical subsystem; > it's strictly for command-line applications only." > In an off-list email Brian Beavers (OP) told me: "Also, with Xming X server, you can even get graphical Linux applications to run" So maybe there is an avenue there for graphical applications. Rob -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at https://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: Sage runs in Window's 10's new Unix subsystem
Dear Brian, Appears it is some flavor of Ubuntu Linux running within Windows? https://blogs.windows.com/buildingapps/2016/03/30/run-bash-on-ubuntu-on-windows/ I hadn't heard. ;-) Rob -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at https://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: symbolic_poly(matrix) : bug report in linear algebra quickref!
Well, it might have worked in 2011! ;-) I guess this QuickRef could use a review and update. Even better would be a way to doctest these and have them routinely tested as part of the usual development process. I'll give the later some thought if/when I tackle the former. Rob On Wednesday, May 4, 2016 at 12:10:07 PM UTC-7, William wrote: > > It (column 2 of [1]) says this should work (see [2] below also), but it > doesn't: > > A = matrix(QQ, [[1,2],[3,4]]) > f(x) = x^3 - 2*x + 1 > f(A) # FAIL -- this is maybe a bug though (the quickref says it should > work) > > Making f an actual polynomial (not symbolic) works. > > [1] > https://wiki.sagemath.org/quickref?action=AttachFile=get=quickref-linalg.pdf > > [2] Complete session in latest sage: > > ~$ sage-develop > ┌┐ > │ SageMath version 7.2.beta6, Release Date: 2016-04-28 │ > │ Type "notebook()" for the browser-based notebook interface.│ > │ Type "help()" for help.│ > └┘ > ┏┓ > ┃ Warning: this is a prerelease version, and it may be unstable. ┃ > ┗┛ > sage: A = random_matrix(QQ,2) > sage: f(x) = x^2 > sage: f(A) > --- > > TypeError Traceback (most recent call > last) > in () > > 1 f(A) > > /projects/sage/sage-develop/src/sage/symbolic/expression.pyx in > sage.symbolic.expression.Expression.__call__ > (/projects/sage/sage-develop/src/ > build/cythonized/sage/symbolic/expression.cpp:28249)() > > /projects/sage/sage-develop/local/lib/python2.7/site-packages/sage/symbolic/callable.pyc > > > in _call_element_(self, _the_element, *args, **kwds) > 485 d = dict(zip([repr(_) for _ in self.arguments()], args)) > 486 d.update(kwds) > --> 487 return SR(_the_element.substitute(**d)) > 488 > 489 > > /projects/sage/sage-develop/src/sage/symbolic/expression.pyx in > sage.symbolic.expression.Expression.substitute > (/projects/sage/sage-develop/sr > c/build/cythonized/sage/symbolic/expression.cpp:27754)() > > /projects/sage/sage-develop/src/sage/symbolic/expression.pyx in > sage.symbolic.expression.Expression.coerce_in > (/projects/sage/sage-develop/src > /build/cythonized/sage/symbolic/expression.cpp:20144)() > > /projects/sage/sage-develop/src/sage/structure/parent_old.pyx in > sage.structure.parent_old.Parent._coerce_ > (/projects/sage/sage-develop/src/bu > ild/cythonized/sage/structure/parent_old.c:4547)() > 237 def _coerce_(self, x):# Call this from Python > (do not override!) > 238 if self._element_constructor is not None: > --> 239 return self.coerce(x) > 240 check_old_coerce(self) > 241 return self._coerce_c(x) > > /projects/sage/sage-develop/src/sage/structure/parent.pyx in > sage.structure.parent.Parent.coerce > (/projects/sage/sage-develop/src/build/cython > ized/sage/structure/parent.c:1)() > > TypeError: no canonical coercion from Full MatrixSpace of 2 by 2 dense > matrices over Rational Field to Callable function ring with argument x > sage: > > -- > William (http://wstein.org) > -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at https://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: Moving compiled Sage on SMC no longer possible
Thanks, Dima. I hadn't thought to try that. I'll give it a whirl. Rob On Thursday, January 28, 2016 at 11:14:47 PM UTC-8, Dima Pasechnik wrote: > > > > On Friday, 29 January 2016 05:30:58 UTC, Rob Beezer wrote: >> >> I've seen some messages about the "relocatability" of compiled Sage >> recently, but cannot find them now. >> >> I've been building compiled versions of Sage on SageMathCloud, to make it >> easier for people to begin development. >> >> >> https://cloud.sagemath.com/projects/53b77207-8614-4086-a032-432af4b4cdbd/files/sage-dev-images/ >> >> In response to a user's question, I tried copying 7.1.beta0 and when >> trying to start Sage got: >> >> ERROR: The Sage installation tree has moved >> >> from /projects/53b77207-8614-4086-a032-432af4b4cdbd/sage-dev-images/sage- >> 7.1.beta0 >> to /projects/53b77207-8614-4086-a032-432af4b4cdbd/sage-7.1.beta0 >> >> This is not supported, and Sage will not work. To install Sage from a >> binary package: >> >> That seems pretty unambiguous, but I wanted to confirm that is now >> pointless for me to make these images available. >> >> they should be appropriately packaged; either you make a proper > distribution image, (sage -bdist --- or is it broken now?), > or perhaps using https://github.com/sagemath/binary-pkg ? > > > >> Thanks, >> Rob >> > -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at https://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Moving compiled Sage on SMC no longer possible
I've seen some messages about the "relocatability" of compiled Sage recently, but cannot find them now. I've been building compiled versions of Sage on SageMathCloud, to make it easier for people to begin development. https://cloud.sagemath.com/projects/53b77207-8614-4086-a032-432af4b4cdbd/files/sage-dev-images/ In response to a user's question, I tried copying 7.1.beta0 and when trying to start Sage got: ERROR: The Sage installation tree has moved from /projects/53b77207-8614-4086-a032-432af4b4cdbd/sage-dev-images/sage-7.1 .beta0 to /projects/53b77207-8614-4086-a032-432af4b4cdbd/sage-7.1.beta0 This is not supported, and Sage will not work. To install Sage from a binary package: That seems pretty unambiguous, but I wanted to confirm that is now pointless for me to make these images available. Thanks, Rob -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at https://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: [sage-edu] Re: Article with beautiful math and pictures by SageMath in Notices
On 12/11/2015 08:51 AM, Volker Braun wrote: Copy from pdf is generally troublesome, anything thats not just letter+number is likely to cough up unicode stuff. Yep, and that's why I've been super-careful about the PDF's produced from MathBook XML. Left, right, single, double quotes, and dashes are the worst. This example went from MathBook XML (text editor) to LaTeX to PDF (via xelatex) to SMC (cut/paste) with no loss. Rob -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: [sage-edu] Python toolkit for music theory
lilypond uses TeX to create "engraved sheet music." So I'd imagine it would create PDFs that could be converted to other formats. From a cursory look it appears that music21 has good support for MusicXML so that might be a way to interoperate between the pieces. Sample (unencumbered) scores can be found in various formats at: https://musescore.org/ Rob On 12/08/2015 02:20 PM, William Stein wrote: Installing music21 is trivial -- just use "pip install music21". I tried with SMC: https://cloud.sagemath.com/projects/4a5f0542-5873-4eed-a85c-a18c706e8bcd/files/support/2015-12-08-141248-music21.sagews However, to display music, one would need a way to get a png or svg image written to a file; it would then be easy to display it inline by doing smc.file('filename.png'). Question: Is there a way to save one of the music formats to an image file? How? What other software (something called lilypond?) has to be installed? -- William On Tue, Dec 8, 2015 at 11:37 AM, kcrismanwrote: Possibly of interest to some people on these lists - I'd love to see Sage or Jupyter notebooks using this: http://web.mit.edu/music21/ -- You received this message because you are subscribed to the Google Groups "sage-edu" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-edu+unsubscr...@googlegroups.com. To post to this group, send email to sage-...@googlegroups.com. Visit this group at http://groups.google.com/group/sage-edu. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] NSF research study proposal, open textbooks and mathematics software
The UTMOST Project investigates the affordances and challenges of integrating powerful open source software for advanced mathematics (ie Sage) with textbooks and course materials provided with open licenses and available in a variety of formats. The project seeks to understand the ways in which these tools change instruction of undergraduate mathematics courses and the opportunities to learn that are created with these tools. We are proposing a research project to the National Science Foundation's Improving Undergraduate STEM Education (IUSE) program and are soliciting the participation of undergraduate mathematics faculty to be part of this research study. Please see the attached description, or follow the link below to learn about the activities, stipends and application procedure. You can learn more about SageMathCloud at: https://vimeo.com/147383564 http://mathbook.pugetsound.edu/utmost-call-for-participation.html (Apologies for the cross-posting. -Rob) -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout. utmost-call-for-participation.pdf Description: Adobe PDF document
Re: [sage-devel] Graph() construction with edge function
Nathann - Looks great - thanks! -Rob On Friday, October 16, 2015 at 3:38:41 AM UTC-7, Nathann Cohen wrote: > > Helloo, > > > Yes, I think if the documentation screams "implements a symmetric > relation" > > that would be a big improvement. And maybe a doctest illustrating how > it > > can go bad? > > I added a mention that the function should be symmetric, and just > pushed a new doctest for that: > > > http://git.sagemath.org/sage.git/commit/?id=3b724240f9aba068d4495b4600c3f4a9190d5043 > > > (still on #19390) > > Have fuun, > > Nathann > -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
Re: [sage-devel] Graph() construction with edge function
Dear Nathann, Yes, I think if the documentation screams "implements a symmetric relation" that would be a big improvement. And maybe a doctest illustrating how it can go bad? Thanks very much for looking after this one. I am a little familiar with that constructor, I'm sure you will have fun with it. ;-) Rob On Wednesday, October 14, 2015 at 11:35:11 PM UTC-7, Nathann Cohen wrote: > > Hello, > > Sorry for the change in behaviour, perhaps I should write somewhere that > 'f' must be symmetric. I could do so in #19390, for it actually cleans the > constructor code and their documentation. > > So should the "edge-detection" function be required to return true for any >> pair of vertices joined by an edge, or should there be an edge constructed >> between any pair of vertices for which the edge-detection function returns >> true? >> > > The best for me is to request that the function should be symmetric (as it > is required in theory anyway: a graph is the result of a symmetric binary > relation), and that anything else is "undefined behaviour". This way > building a graph calls f for a total of n(n-1)/2 times (if there are no > loops), and not twice that amount. > > Furthermore, I wonder where that change came from. It "may" come from the > graph code but really I do not see how: the constructor was patched heavily > recently, but that's not in the beta yet. itertools.combinations always > respected the ordering you give it: if 0 comes before 1 in the list, it > will give you (0,1) (thus the -1 in your code) and not (1,0). I don't think > that [0..8] ever returned [8,7,6,,0] either. Weird. > > I'd argue the former requires some help with the documentation, while the >> latter would be a change to the code/behavior. >> > > I will add a "symmetric" somewhere in the doc. The amount of of guessing > that the graph constructor does is already beyond sanity. Just a funny > example I showed to a colleague yesterday: > > {1 : [2,3], 2: [3, 4]} # we all think of the same graph, even if 2 does > not name 1 as its neighbors > > {1 : [2,3], 2: [3, 4]} # with multiedges=True. Same result ? What do you > expect now ? > > {1 : [2,3], 2: [3, 4], 3: [1]} # with multiedges=True. And now ? > > {1 : [2,2], 2: [1]} # with multiedges=True. And now ? How many edges > between 1 and 2 ? > > More headaches in the two comments starting at: > http://trac.sagemath.org/ticket/19385#comment:17 > > Have fuuun, > > Nathann > > > -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Graph() construction with edge function
The following used to work (based on regular private doctesting outside of Sage source code) and give you the path you wanted: P9 = Graph([[0..8], lambda i,j: i-j == 1]) Now it silently produces an empty graph (9 vertices, no edges). The fix: P9 = Graph([[0..8], lambda i,j: i-j == -1]) Is this a bug, or does part 4 of the Graph() constructor documentation need clarification? Rob -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
Re: [sage-devel] Graph() construction with edge function
Well, the first thing I tried was (i-j)^2 == 1. ;-) Partially answering my own question, by reading the code (graphs/graph.py): from itertools import combinations self.add_vertices(verts) self.add_edges(e for e in combinations(verts,2) if f(*e)) self.add_edges((v,v) for v in verts if f(v,v)) The "combinations()" iterator appears to produce unordered pairs, as you would expect (and "f" is the supplied function). So should the "edge-detection" function be required to return true for any pair of vertices joined by an edge, or should there be an edge constructed between any pair of vertices for which the edge-detection function returns true? I'd argue the former requires some help with the documentation, while the latter would be a change to the code/behavior. Rob -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: [sage-edu] Re: Sage-enabled textbook for Abstract Algebra
Thanks for all the discussion and hints about working with the left sidebar. I like Dima's suggestion of a 2-up mode. You'll notice we did not center the fixed-width text in the browser window. We are reserving the real-estate on the right for some generally useful purpose, though we have not decided yet what that will be. We will revisit all this once we get some support again for some serious CSS/Javascript development. On Thursday, August 6, 2015 at 1:56:55 AM UTC-7, Dima Pasechnik wrote: besides being a distraction, the sidebar is a waste of screen space. On a 13 laptop screen I could comfortably view two pages of this side by side. (this might be another suggestion for the design - make such a layout possible.) On Wednesday, 5 August 2015 16:39:36 UTC+1, kcrisman wrote: You could zoom in (control plus) the browser window, which should be equivalent for testing purposes. That's what we ended up telling my students. -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: [sage-edu] Re: Sage-enabled textbook for Abstract Algebra
On Sunday, August 2, 2015 at 1:12:29 AM UTC-7, Dima Pasechnik wrote: One thing I didn't like was the inability to hide the contents frame(?) on the left-hand side. It just sits there for no good reason, and is a distraction. IMHO it should automatically hide itself... Yes, we discussed that one a lot. Try slowly making your browser window skinny and eventually the interface will go into small-device-mode. Now the button at the bottom-left should slide the contents sidebar in and out nicely. -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: Sage-enabled textbook for Abstract Algebra
Looks good. Glad to hear your Chrome problem got sorted out. You are at about the limit of what I know about configuration. The mathjax-users group is *very* prompt and helpful if you follow their posting guidelines when you ask for help: https://groups.google.com/forum/#!topic/mathjax-users/Dhk3bQgThaM On Sunday, August 2, 2015 at 8:00:50 AM UTC-7, parisse wrote: I have updated the giac.tex http://www-fourier.ujf-grenoble.fr/~parisse/giac/giac.tex file (and also Xcas offline in the browser http://www-fourier.ujf-grenoble.fr/~parisse/giac/xcasen.html), if the HTML file is loaded from hard disk it detects Chrome (or IE) and renders with mathjax for these browsers, and otherwise use mathml for rendering. But it does not work if loaded from url, mathjax refuses to load under Chrome (the console displays net err_FAILED), I have no idea why. I think I will revert to plain text output for Chrome. -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: [sage-edu] Re: Sage-enabled textbook for Abstract Algebra
On Saturday, August 1, 2015 at 2:05:07 AM UTC-7, Dima Pasechnik wrote: Perhaps they should rather generate your XML? (beezertex filename ;-)) No, seriously... Yes, seriously. ;-) I hope that something like this will be in place eventually. Please note that I actually rather like the way the e-book in question looks like, it's great in this way. And, by the way, looks good on an Android tablet too... Thanks for the testing, and I'm glad you like the end-product. All the CSS/Javascript is by a student of mine, Michael DuBois, who was supported at the tail end of the last NSF education grant (UTMOST). The small-screen interface never would have happened without him. -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: [sage-edu] Re: Sage-enabled textbook for Abstract Algebra
On Saturday, August 1, 2015 at 2:45:16 AM UTC-7, Volker Braun wrote: It would be nice if Sage cells would know about which cells they depend on; Right now evaluating a cell in the middle is very likely to cough up an error message about something not being defined. Yes, Sage Cells are linked with all the others on a page, but you typically want to execute them in order, so starting in the middle can be a disaster. MathBook XML is very flexible about chunking - so you can decide whether a section is a whole web page, or if a subsection is a webpage, or ... So you have some control about how many cells are enclosed as a unit. (And you should make this decision early while writing Sage cells!) There is also the inverse problem of defining some complicated object in a Sage Cell on some previous page and wanting to reuse it. This is solved partially by being able to use a cross-reference from the second page back to the cell on the previous page. The code still needs to re-run, but the author does not need to create and maintain the second version. IMHO we should think about moving non-technical Sage docs to mathbook. Of course, I'd stand ready to help with technical advice and additions to MathBook XML to support this. The underlying HTML is meant to be very semantic/structural/skinnable (without being too impractical), so ideally it would be possible to retain all the navigation, but also give a Sage-blue look and branding. An example with lots of Sage, which has a feel similar to the thematic tutorials, is at: http://linear.ups.edu/eagts/ With Sage 6.7, nineteen (out of 417) doctests are failing since the last update was Sage 5.12, so it needs just a bit of clean-up. Mostly deprecations, and rearrangments of output format. -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: Sage-enabled textbook for Abstract Algebra
Thanks, Bill. It continues to be fun and there's lots more to do. But I am also looking forward to writing more content myself. ;-) Rob On Saturday, August 1, 2015 at 2:54:37 AM UTC-7, Bill Hart wrote: Rob, this is truly fantastic work. I want to congratulate you on getting this up and running! -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: Sage-enabled textbook for Abstract Algebra
Dear Bernard, I was thinking more of the static HTML pages you sent that had been generated from TeX/LaTeX with your GIAC extensions (giac.tex). The mathematics on those pages might look better with MathJax and that would be an easier scenario to configure. For the calculator page you just sent in this message, you need to be more careful. When you output some result and add it to the page, then you have to instruct MathJax to process that material again. This gets a bit tricky and I can't say I fully understand the order in which MathJax processes a page (relative to everything else). And the delimiters may need to be \[, \] rather than double-dollar for display math. http://docs.mathjax.org/en/latest/typeset.html The later processing is something knowls (like embedded pop-ups) need to handle. So there could b some hints in the Javascript here: http://aimath.org/knowl.js Rob On Saturday, August 1, 2015 at 1:28:01 AM UTC-7, parisse wrote: Le samedi 1 août 2015 02:17:34 UTC+2, Rob Beezer a écrit : Dear Bernard, Thanks for the note and links. I was not very aware of GIAC. It could be a useful thing for MathBook XML authors to have available. Have you considered using MathJax within your HTML output? It too is Javascript and can be configured to execute locally. I got disappointing results for dynamic rendering (bugs, slowness) when using latex/mathjax for Xcas offline in the browser, perhaps because I do not use mathjax properly. Compare latex/mathjax http://www-fourier.ujf-grenoble.fr/~parisse/giac/xcasenie.html with Firefox/mathml http://www-fourier.ujf-grenoble.fr/~parisse/giac/xcasen.html -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: [sage-edu] Re: Sage-enabled textbook for Abstract Algebra
On Saturday, August 1, 2015 at 3:12:38 AM UTC-7, Dima Pasechnik wrote: IMHO we should think about moving non-technical Sage docs to mathbook. write an automatic converted, why not... Sage-flavored ReST/Sphinx might be structured/predictable enough to be very amenable to this. -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: Sage-enabled textbook for Abstract Algebra
Dear Bernard, Thanks for the note and links. I was not very aware of GIAC. It could be a useful thing for MathBook XML authors to have available. Have you considered using MathJax within your HTML output? It too is Javascript and can be configured to execute locally. Rob On Friday, July 31, 2015 at 12:07:13 AM UTC-7, parisse wrote Thanks for the clarifications. It has some common features with what I'm exploring by combining latex, hevea, giac and HTML5, but also big differences. In my current prototype, you add \input{giac.tex} in the tex file preamble, this defines a few new latex commands like \giaccmdmath{factor}{x^4-1}. If you compile with hevea instead of latex or pdflatex, you get a HTML output where the input x^4-1 can be replaced by the reader, pressing Enter or clicking factor will evaluate the command. Similar to your sage-enabled book. The main difference is that the source code is a latex file, it's straightforward to add interactivity to existing files. Moreover, the HTML output does not depend on a server to execute the commands. The javascript compilation of giac (giac.js) is downloaded once, then it executes locally all commands (tested with Firefox, Safari and Chrome, for IE plot outputs are not rendered correctly). Compiling requires hevea http://hevea.inria.fr and giac.tex http://www-fourier.ujf-grenoble.fr/%7Eparisse/giac/giac.tex, see example of commands in test.tex http://www-fourier.ujf-grenoble.fr/%7Eparisse/giac/test.tex or a more complete example I started a few weeks ago by adapting a course in French http://www-fourier.ujf-grenoble.fr/~parisse/mat249/mat237.html (replace html by tex in the link above to see the source code). There are probably some ideas that could be shared between the two projects. For example, your output could also use giac.js for computation and be server-independant. -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: [sage-edu] Re: Sage-enabled textbook for Abstract Algebra
On Friday, July 31, 2015 at 4:06:01 PM UTC-7, Dima Pasechnik wrote: You don't need a closing tag that can be inserted by software, as certainly is the case for \section or \item.. (unless you spent a large part of your life writing HTML or XML by hand, of course :-)) So where does a LaTeX subparagraph end? When the next line is a \begin for another subparagraph, or a paragraph, or a subsubsection, or a subsection, or a section, or a chapter, or a part, or the \end{document}. And if it is so easy to convert LaTeX into HTML, why hasn't anybody done it successfully? tex4ht is the only one I know that comes close, and only because it is the only one that uses the tex executable. But try to extend it to convert LaTeX into a Sage Notebook worksheet, like I did for several years.Current project is borne of many such experiences. I wish Knuth did review (X)HTML format proposals for sanity... Me too. ;-) -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: [sage-edu] Re: Sage-enabled textbook for Abstract Algebra
On Friday, July 31, 2015 at 4:06:01 PM UTC-7, Dima Pasechnik wrote: I wish Knuth did review (X)HTML format proposals for sanity... I should add that MathBook XML adds no new syntax for mathematics proper. In other words, symbols, equations, displays are not written in something like MathML (that would be painful for a human). Instead, all the symbols and constructions you already know can be used. LaTeX is great between the dollar signs. ;-) -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: [sage-edu] Re: Sage-enabled textbook for Abstract Algebra
On 07/31/2015 05:25 PM, Dima Pasechnik wrote: And if it is so easy to convert LaTeX into HTML, why hasn't anybody done it successfully? tex4ht is the only one I know that comes close, and only because it is the only one that uses the tex executable. sure, why is this bad to use the tex executable? Because it has to be done on the fly in your browser? Well, I cannot care less -- perhaps someone should develop a NaCL implementation of (La)TeX to be runnable in the browser? Not bad to use the tex executable. That is the key design decision in tex4ht that makes it as good as it is. Seems only tex can understand TeX. ;-) -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: Sage-enabled textbook for Abstract Algebra
On Friday, July 31, 2015 at 3:47:56 AM UTC-7, Dima Pasechnik wrote: XML? I wish pandoc (http://pandoc.org/) could handle conversions to and from your format... Do people really want to write XML by hand? I tried it once (GAP docs can be prepared using XML) and was not amused. Just wondering, Dima Dear Dima, As you know XML is a very uncomplicated syntax. Five special characters: , , , ', . And the quotes are rarely an issue (the ampersand is another story). Processing XML with a functional language (XSLT) has a steep learning curve, but that is not an author's concern. And I have yet to find a problem in text-processing with XSLT that I had to hack my way through. It is all very natural. The right tool for the job. As David notes, I am designing a collection of tags and attributes that will increase an author's productivity, cleanly separate content from presentation, and allow a variety of powerful output formats that do not require an author to know LaTeX tips and tricks, HTML, CSS, MathJax, Sage Cell server, etc. With a semi-reasonable editor that understands tag-completion and matching (I use Sublime Text; XML Copy Editor is free and more powerful) you can become quite proficient quickly. I used LaTeX for thirty years. In this project, I've seen even more clearly all the places it is lacking. The XML? Yuck! factor probably delayed me from starting this project by three years. So it was not a rash decision. I am scratching my own itch, and it is going quite nicely. I write for hours and make almost no syntax errors. And for anyone who wants to try - you can always create the (clean) LaTeX output and go back to using that, so your writing is not locked into this system. A conversion to Pandoc would be a nice feature. However, with some of these simpler markup languages, you discover they are not expressive enough to create something like a heavily cross-referenced textbook. Would you like to contribute a conversion to Pandoc? You'd have fun. In the end, I am trying to increase the supply of open textbooks (all subjects!) by providing an open source tool that is both powerful and reasonably easy to use. And with a soft place in my heart for Sage that has been a primary initial emphasis. Projects like Tom's convince me of the utility. It is an uphill slog, but I'm in it for the long haul. Thanks for your comments. Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
Re: [sage-devel] Sage-enabled textbook for Abstract Algebra
Dear Johan, Thanks for taking the time to write. The encouragement helps! ;-) Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: Sage-enabled textbook for Abstract Algebra
On Thursday, July 30, 2015 at 12:59:54 PM UTC-7, parisse wrote: I had a quick look, but I'm still a little bit confused how the source are written. Do you write your source files in xml or have you some kind of converter from a latex source file? MathBook XML is the XML application I am designing. It is a collection of XML tags meant to be usable for an author: chapter, section, theorem, example, exercise, etc. I have written converters to LaTeX (for PDF, print) and to HTML. Other conversions are possible and planned. It's main purpose is for authors creating new content. Tom's book was authored in the late 1980's in LaTeX and published around 1992 by PWS-Kent. Last May, we spent a week using sed and other tools/tricks to convert his well-formed LaTeX to MathBook XML. Hand-editing has fine-tuned that conversion and also driven the development of MathBook XML. The resulting sed script is in the git repo for the book (on GitHub, see website) as is the original LaTeX if you go back in the history. But the conversion is not generally useful, it was one-off quick-and-dirty. David Farmer, of the American Institute of Mathematics, has made a lot of progress converting LaTeX to the same HTML as seen here, and that work should expand to include MathBook XML as an output. I hope this helps - the jumble of acronyms gets to be a mess sometimes. Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: Sage-enabled textbook for Abstract Algebra
Thanks, Anne, for your interest. I've never taught out of Artin, and my copy is not here at home. But I'll say that Tom's book is very much like Gallian's, which I used for many years. Tom has also used it for a graduate course. And there are a few Sage examples with a distinctly combinatorial flavor to them, such as posets, coding theory and a great chapter on group actions. Rob On Thursday, July 30, 2015 at 2:28:59 PM UTC-7, Anne Schilling wrote: Dear Rob, This looks like a great book! I will be teaching Abstract Algebra at UC Davis in the fall and will try to use it (along with Artin's book). How does it compare to Artin Algebra, besides offering many Sage examples? Best wishes, Anne On Wednesday, July 29, 2015 at 6:32:36 PM UTC-7, Rob Beezer wrote: I have had it in my head for many years to integrate Sage tightly with textbook material. The first full result of this idea, produced through a general system, is now available. (Perhaps this excuses my near-total absence from core Sage development the past two or three years.) Tom Judson's Abstract Algebra: Theory and Applications is available as a collection of Sage-enabled web pages, in addition to a traditional PDF with static Sage examples - all with an open license, and both versions are produced from the same source files with no intermediate editing. Stable URL: http://abstract.pugetsound.edu/aata/ Features: * 710 Sage Cell examples, doctested every six months * 121 classroom-tested Sage exercises, ranging from very computational to open-ended guided explorations * 23 chapters, 672 traditional exercises, enough for a year-long course or less * knowls (implemented by Harald Schilly and David Farmer) for proofs and cross-referenced content * CSS, MathJax, and SVG images from tikz source, together make pages scale uniformly * web interface reacts to small screens (responsive design) We are running a Public Beta for the few weeks prior to North American courses beginning in September. We expect Lon Mitchell to publish a hardcopy version (without Sage material, with new numbering) to be available (US only?, I'm not sure) for US$ 25 or so in the next few weeks. See website for details. Short-Lived URL: http://abstract.pugetsound.edu/beta.html Faithful PDF (beta): http://abstract.pugetsound.edu/beta/aata-20150729.pdf Next: * I have limited conversions to Sage Notebook worksheets, SageMathCloud worksheets and Jupyter notebooks in various stages of disarray. I'll likely get the Sage exercises posted in at least one of these formats before my course begins in September. * EPUB is the next major output format we will target. * Convert my linear algebra book to the new system. If you teach modern algebra to advanced undergraduates and want to expose your students to computation, this book would be an excellent choice. If you want to author your own material like this, the system requires no more technical skill than writing in LaTeX. Making Sage-enabled lecture notes available to your students on the web is a great way to get started. This project relies on multiple open source projects built up by many people, but I will just single out Tom Judson for his willingness to open source his textbook, his patience as we converted the original LaTeX source over the past year, and allowing me to incorporate Sage material and exercises within his book. http://abstract.pugetsound.edu/contact.html -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Sage-enabled textbook for Abstract Algebra
I have had it in my head for many years to integrate Sage tightly with textbook material. The first full result of this idea, produced through a general system, is now available. (Perhaps this excuses my near-total absence from core Sage development the past two or three years.) Tom Judson's Abstract Algebra: Theory and Applications is available as a collection of Sage-enabled web pages, in addition to a traditional PDF with static Sage examples - all with an open license, and both versions are produced from the same source files with no intermediate editing. Stable URL: http://abstract.pugetsound.edu/aata/ Features: * 710 Sage Cell examples, doctested every six months * 121 classroom-tested Sage exercises, ranging from very computational to open-ended guided explorations * 23 chapters, 672 traditional exercises, enough for a year-long course or less * knowls (implemented by Harald Schilly and David Farmer) for proofs and cross-referenced content * CSS, MathJax, and SVG images from tikz source, together make pages scale uniformly * web interface reacts to small screens (responsive design) We are running a Public Beta for the few weeks prior to North American courses beginning in September. We expect Lon Mitchell to publish a hardcopy version (without Sage material, with new numbering) to be available (US only?, I'm not sure) for US$ 25 or so in the next few weeks. See website for details. Short-Lived URL: http://abstract.pugetsound.edu/beta.html Faithful PDF (beta): http://abstract.pugetsound.edu/beta/aata-20150729.pdf Next: * I have limited conversions to Sage Notebook worksheets, SageMathCloud worksheets and Jupyter notebooks in various stages of disarray. I'll likely get the Sage exercises posted in at least one of these formats before my course begins in September. * EPUB is the next major output format we will target. * Convert my linear algebra book to the new system. If you teach modern algebra to advanced undergraduates and want to expose your students to computation, this book would be an excellent choice. If you want to author your own material like this, the system requires no more technical skill than writing in LaTeX. Making Sage-enabled lecture notes available to your students on the web is a great way to get started. This project relies on multiple open source projects built up by many people, but I will just single out Tom Judson for his willingness to open source his textbook, his patience as we converted the original LaTeX source over the past year, and allowing me to incorporate Sage material and exercises within his book. http://abstract.pugetsound.edu/contact.html -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Next week's rides
Need leadership - feel free to volunteer on/off-list for Tuesday or Thursday. I can help with route and post-ride suggestions, and rebroadcast. Summer ride calendar is beginning to take form: Jun 9 Leadership? Jun 16 Jun 23 Solstice Ride, Port Orchard Aug 18 Gretchen and Hal Hodgins, Rosedale Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: Next week's rides
Sitting in the wrong Google Group. ;-) Sorry for the noise. Off course, any Sage developer who would like to go bicycle riding with us is always welcome! Rob On Wednesday, June 3, 2015 at 2:47:10 PM UTC-7, Rob Beezer wrote: Need leadership - feel free to volunteer on/off-list for Tuesday or Thursday. I can help with route and post-ride suggestions, and rebroadcast. Summer ride calendar is beginning to take form: Jun 9 Leadership? Jun 16 Jun 23 Solstice Ride, Port Orchard Aug 18 Gretchen and Hal Hodgins, Rosedale Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
Re: [sage-devel] Re: dpkg: error processing package sagemath-upstream-binary (--configure):
Not sure of this will help, but I did a fresh build of 6.8.beta2 on SageMathCloud, passed long tests, and changed the directory name. Usually this is OK and the paths all get adjusted but now I get: ~/sage-dev$ ./sage find: `/projects/53b77207-8614-4086-a032-432af4b4cdbd/sage-dev/local/var/lib/sage/installed': No such file or directo ry ┌┐ │ SageMath Version 6.8.beta2, Release Date: 2015-05-29 │ │ Type notebook() for the browser-based notebook interface.│ │ Type help() for help.│ └┘ ┏┓ ┃ Warning: this is a prerelease version, and it may be unstable. ┃ ┗┛ The Sage installation tree has moved from /projects/53b77207-8614-4086-a032-432af4b4cdbd/sage-dev-images/sage-6.8.beta2 to /projects/53b77207-8614-4086-a032-432af4b4cdbd/sage-dev Updating various hardcoded paths... (Please wait at most a few minutes.) DO NOT INTERRUPT THIS. Done updating paths. Traceback (most recent call last): File /projects/53b77207-8614-4086-a032-432af4b4cdbd/sage-dev/local/bin/sage-ipython, line 7, in module from sage.repl.interpreter import SageTerminalApp File /projects/53b77207-8614-4086-a032-432af4b4cdbd/sage-dev/local/lib/python2.7/site-packages/sage/__init__.py, line 3, in module from sage.repl.ipython_extension import load_ipython_extension ImportError: No module named repl.ipython_extension Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: European Horizon 2020 project OpenDreamKit accepted
Very good! -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Minimum distance of a Hamming code
The code below fails on 6.7 with a RuntimeError. r = 2 C = codes.HammingCode(r, GF(2)) C.minimum_distance() For r 5 it seems to hang interminably, while back in November/December I could do r = 7 in a few seconds, and do r = 10 without waiting too long. Does anybody have any information on this one? I didn't locate anything in Trac or here. I'll make a ticket if nothing interesting surfaces. Rob Traceback for r = 2: Traceback (most recent call last): snip File sage/misc/cachefunc.pyx, line 1896, in sage.misc.cachefunc. CachedMethodCaller.__call__ (build/cythonized/sage/misc/cachefunc.c:11488) File sage/misc/cachefunc.pyx, line 2552, in sage.misc.cachefunc. CachedMethod._instance_call (build/cythonized/sage/misc/cachefunc.c:14934) File /sage/sage-6.7/local/lib/python2.7/site-packages/sage/coding/linear_code.py , line 2234, in minimum_distance return min_wt_vec_gap(Gstr,n,k,F).hamming_weight() File /sage/sage-6.7/local/lib/python2.7/site-packages/sage/coding/linear_code.py , line 412, in min_wt_vec_gap raise RuntimeError(there is a bug here!) RuntimeError: there is a bug here! -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
Re: [sage-devel] hosting the sage cell server
The Sage Cell is a distinct project from Sage Math Cloud. It has been open source since from inception. Try the link in the message you quoted - it is a simple but powerful idea. On Thursday, May 21, 2015 at 8:15:49 PM UTC-7, Dr. David Kirkby (Kirkby Microwave Ltd) wrote: On 14 Apr 2015 22:50, William Stein wst...@gmail.com javascript: wrote: Hi Sage Developers, Is there anybody who would be willing to host the Sage cell server? http://sagecell.sagemath.org/ http://www.google.com/url?q=http%3A%2F%2Fsagecell.sagemath.org%2Fsa=Dsntz=1usg=AFQjCNEzD8lZmRDRMRPKgFLeXV4H459usQ I'm unable to do this, but I rather suspect that you would have zero or very few offers if the cloud software was closed source, as you originally wanted to keep it. I expect it is a lot easier for someone to get permission from their institution to host open source software than it would be if it was closed source. Dave. -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Conversions to IntegerComposition poset elements
The following does not do what you hope, but does raise a semi-informative error: CP = Posets.IntegerCompositions(5) C = LatticePoset(CP) C([1, 1, 1, 2]) Traceback (click to the left of this block for traceback) ... TypeError: unhashable type: 'list' The following accomplishes what you perhaps expected: CP = Posets.IntegerCompositions(5) C = LatticePoset(CP) P = C.an_element().parent() P([1, 1, 1, 2]) [1, 1, 1, 2] Am I missing something? Or is this worth a ticket? Thanks, Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: Generating matrix of GF with given determinant
This code was written by a summer student of mine (and reviewed by others). The point was to quickly make examples that would be useful for students to study from. I use these routines all the time when writing textbooks and examinations. So random was never meant to mean uniform. Maybe the documentation should say that. The efficiency does not scale very well. One of the design criteria was to produce matrices over QQ that actually have integer entries *and* to be able to bound the absolute value of the entries (the upper-bound parameter). This is the cause of the looping Dima has noted, and the long run times at n=40. Of course, this upper bound parameter is meaningless over finite fields. The code is general enough to allow for finite fields, but I never contemplated giving my introductory linear algebra students matrices to row-reduce over GF(125)! So the code has been useful for its purposes, but is far from perfect. I'd love to see improvements that preserve its utility at producing examples that make quality small random examples for students to work with. Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Sage script at command-line fails in a suspicious way
I have a short chunk of Sage code that I am running from the command line. It produces errors with newer versions of Sage, but works as intended with older versions (producing a graphics file). Of about 20 such chunks, 3 appear to be failing. Is this a known problem? Should I make a ticket? Any ideas or suggestions? (These are produced automatically, which is why some parts look bit odd, but it also means they are consistent in many ways.) Facts follow - I can provide more if needed. Invocation: /sage/sage-6.5.beta6/sage firstlook02-newton-cooling.sage svg Error: CRITICAL:root:unknown notebook: None Error, notebook must be one of default, ipython, sagenb but got None firstlook02-newton-cooling.sage: import sys suffix = sys.argv[1] f(x) = 28.6 * exp(-0.0725 * x) + 70 p = plot(f, (x, 0, 50), ymin = 55, ymax = 110, thickness=2, aspect_ratio=0.4 , axes_labels=['$t$','$T(t)$'], fontsize=18) plot_idp37915040 = p try: plot_idp37915040.save(firstlook02-newton-cooling.{}.format(suffix)) except ValueError: plot_idp37915040.save(firstlook02-newton-cooling.png) Fails: 6.4 (Linux), 6.5.beta6 (Linux), 6.4.1 (Mac) Succeeds: 6.0, 6.2, 6.3 (all Linux) Linux testing is on built-from-source (unsure about Mac binaries). The following very similar file succeeds with a similar invocation: firstlook01-exercise-slope-field-1.sage: import sys suffix = sys.argv[1] t = var('t') f(x) = 2*x*(1 - x) v = plot_slope_field(f, (t,-2,2), (x,-2,2), headaxislength=3, headlength=3, axes_labels=['$t$','$x$'], fontsize=18) plot_idp38572272 = v try: plot_idp38572272.save(firstlook01-exercise-slope-field-1.{}.format( suffix)) except ValueError: plot_idp38572272.save(firstlook01-exercise-slope-field-1.png) -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
Re: [sage-devel] Sage script at command-line fails in a suspicious way
Genius. All three failing scripts have -n in the filename, and the renaming to a.sage allows the file to succeed. And the rest that do succeed do not have a -n. I'll make a ticket soon unless I hear that this is known already. Thanks, William! Rob On Thursday, January 29, 2015 at 8:15:27 PM UTC-8, William wrote: On Thu, Jan 29, 2015 at 8:12 PM, Rob Beezer goo...@beezer.cotse.net javascript: wrote: I have a short chunk of Sage code that I am running from the command line. It produces errors with newer versions of Sage, but works as intended with older versions (producing a graphics file). Of about 20 such chunks, 3 appear to be failing. Is this a known problem? Should I make a ticket? Any ideas or suggestions? (These are produced automatically, which is why some parts look bit odd, but it also means they are consistent in many ways.) Facts follow - I can provide more if needed. Invocation: /sage/sage-6.5.beta6/sage firstlook02-newton-cooling.sage svg Error: CRITICAL:root:unknown notebook: None Error, notebook must be one of default, ipython, sagenb but got None Does your code have absolutely nothing whatever to do with the Sage or IPython notebookes? This makes me wonder -- what happens if you rename firstlook02-newton-cooling.sage to a.sage and try again. I am suspicious that the -n inside the filename is causing a problem. firstlook02-newton-cooling.sage: import sys suffix = sys.argv[1] f(x) = 28.6 * exp(-0.0725 * x) + 70 p = plot(f, (x, 0, 50), ymin = 55, ymax = 110, thickness=2, aspect_ratio=0.4, axes_labels=['$t$','$T(t)$'], fontsize=18) plot_idp37915040 = p try: plot_idp37915040.save(firstlook02-newton-cooling.{}.format(suffix)) except ValueError: plot_idp37915040.save(firstlook02-newton-cooling.png) Fails: 6.4 (Linux), 6.5.beta6 (Linux), 6.4.1 (Mac) Succeeds: 6.0, 6.2, 6.3 (all Linux) Linux testing is on built-from-source (unsure about Mac binaries). The following very similar file succeeds with a similar invocation: firstlook01-exercise-slope-field-1.sage: import sys suffix = sys.argv[1] t = var('t') f(x) = 2*x*(1 - x) v = plot_slope_field(f, (t,-2,2), (x,-2,2), headaxislength=3, headlength=3, axes_labels=['$t$','$x$'], fontsize=18) plot_idp38572272 = v try: plot_idp38572272.save(firstlook01-exercise-slope-field-1.{}.format(suffix)) except ValueError: plot_idp38572272.save(firstlook01-exercise-slope-field-1.png) -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+...@googlegroups.com javascript:. To post to this group, send email to sage-...@googlegroups.com javascript:. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout. -- William Stein Professor of Mathematics University of Washington http://wstein.org -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: Who won the Spies Prize?
Dear Volker, Read my lips,... ;-) Congratulations, richly deserved. Rob On Monday, June 16, 2014 1:43:53 PM UTC-7, Volker Braun wrote: Congratulations, Rob... hmm what? I don't have my earphones at hand so I watched the video on mute. The one time that I can't fit a Sage Days on my travel schedule ;-) On Monday, June 16, 2014 8:35:51 PM UTC+1, William wrote: http://youtu.be/I9Myt5NTeCc -- William Stein Professor of Mathematics University of Washington http://wstein.org -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: Sage Edu Days 6
There is still some travel funding available, should you wish to attend Edu Days 6 in Seattle in June. Contact me off-list as described in the original announcement. If you are already planning to attend, note that the special rate at Hotel Deca expires on May 16, so you should reserve soon. Also, please add your name to the wiki page, or ask me to do so for you. Thanks, Rob On Wednesday, April 9, 2014 9:21:52 PM UTC-7, Rob Beezer wrote: Sage Edu Days 6 will take place June 16-18 on the University of Washington campus in Seattle, Washington. Target audience is faculty teaching undergraduate mathematics, as this is the concentration of the NSF UTMOST grant which provides funding for these events. There is a skeleton wiki page, which should expand rapidly, as various arrangements are close to being finalized (ie lodging). Please add yourself as a participant if you plan to attend. http://wiki.sagemath.org/education6 Note that William Stein is organizing a developer conference for the entire week, centered on the SageMathCloud and Sage on the Web. Following that there will be about a 10-day period for concentrated development work as a Bug Days event. See the Sage wiki for more. The Inquiry-Based Learning conference is in Denver, June 19-21, which explains our switch to the first part of the week. Consider combining trips out west, and flying on directly to Denver late Wednesday evening. http://legacyrlmoore.org/events.html There is some travel funding left on our grant, which expires in a few months. If you are undergraduate faculty, and have an education project that could benefit from attendance, contact me off-list about funding, with specifics. Those with more development-oriented projects should contact William Stein about funding available for one of the other two events. Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: a bug in NumberField().galois_group?
The groups are isomorphic: sage: K.a = NumberField(x^4 - 2) sage: G1 = K.galois_group(names='bbb') sage: G2 = K.galois_group(type=gap,names='bbb').group() sage: G1.is_isomorphic(G2) True but sage: K.galois_closure(names=ccc) Number Field in ccc with defining polynomial x^8 + 28*x^4 + 2500 So bug sounds overly harsh to me. Is GAP cleaning up it's version, by replacing it with an isomorphic version? Pedagogically, I prefer G1, which uses 8 points, rather than the 4 used by G2. Rob On Sunday, April 27, 2014 3:32:46 PM UTC-7, Dima Pasechnik wrote: Is this a bug? I ran into this while working on #16243. -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: Characteristic polynomials with bad degrees
On Friday, April 11, 2014 12:21:18 AM UTC-7, Francis Clarke wrote: Looks like a linbox problem: Thanks very much, Francis - hadn't thought to check that. I'll see if I can pursue this upstream. It appears we do have the latest version of linbox (1.3.2). Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Characteristic polynomials with bad degrees
I stumbled on some odd behavior today which I think I have isolated to characteristic polynomials. I've not been following linear algebra development very closely for a few months, so maybe this is known, or maybe I'm confused about something. But if it this is a bug, it seems like it could be serious. On 6.2.beta7. n=31 J = jordan_block(0, n).change_ring(QQ) [(J^m).characteristic_polynomial() for m in range(1, n+1)] [x^31, x^16, x^21, x^23, x^25, x^26, x^26, x^27, x^27, x^28, x^28, x^28, x^28, x^28, x^29, x^29, x^29, x^29, x^29, x^29, x^29, x^29, x^29, x^29, x^29, x^29, x^29, x^29, x^29, x^31, x^31] It gets a bit weirder. For n=59, output is [x^59, x^59, x^59, x^59, x^51, x^59, x^59, x^59, x^53, x^53, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59, x^59] n = 31 is the smallest value where I see trouble. I think the 0 diagonal is necessary. The n=31 output is typical, as the second power seems to have about half the expected degree, and eventually higher powers get the degree right. The matrices themselves look to be OK. I can make a ticket if that seems warranted. Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Sage Edu Days 6
Sage Edu Days 6 will take place June 16-18 on the University of Washington campus in Seattle, Washington. Target audience is faculty teaching undergraduate mathematics, as this is the concentration of the NSF UTMOST grant which provides funding for these events. There is a skeleton wiki page, which should expand rapidly, as various arrangements are close to being finalized (ie lodging). Please add yourself as a participant if you plan to attend. http://wiki.sagemath.org/education6 Note that William Stein is organizing a developer conference for the entire week, centered on the SageMathCloud and Sage on the Web. Following that there will be about a 10-day period for concentrated development work as a Bug Days event. See the Sage wiki for more. The Inquiry-Based Learning conference is in Denver, June 19-21, which explains our switch to the first part of the week. Consider combining trips out west, and flying on directly to Denver late Wednesday evening. http://legacyrlmoore.org/events.html There is some travel funding left on our grant, which expires in a few months. If you are undergraduate faculty, and have an education project that could benefit from attendance, contact me off-list about funding, with specifics. Those with more development-oriented projects should contact William Stein about funding available for one of the other two events. Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.
[sage-devel] Re: Eigenvector result changed from 5.11 to 5.12
Dear Evans, John has given a good answer, but I thought I'd remark that I have seen this behaviour when creating doctests for numerical routines for matrices over RDF/CDF. It sometimes seems like this unpredictable sign change depends on the hardware in use (perhaps because different versions of underlying linear algebra libraries are in use). So not a bug, but an annoying fact-of-life. There is only so much mileage you can get from standardizing eigenvectors to norm 1. Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/groups/opt_out.
[sage-devel] Re: Creating the (Z/5Z)^2 group in Sage : Hell among groups, parent/elements, Cartesian Products ...
On Wednesday, November 6, 2013 9:41:28 AM UTC-8, Nathann Cohen wrote: I screamed for help, Aladin offered his, we tried a few things and Hell followed. Dear Nathann, et al, I've been to hell and back. The situation is as bad as it sounds. #9773 builds on William's finitely-generated free-module-over-PID code to implement additive and multiplicative finitely generated groups in a unified and extendable way. Mostly just a pretty face on top of free modules over ZZ. The code should be solid. Patch applies, with one obsolete hunk failing (just ignore it). Passes the tests that are there. It needs a big effort to be fully documented and then we'd want to decide if it is a useful replacement for what currently exists. Mea culpa for not finishing the job. KDC's group of multiplicative units mod n is a good demonstration of how to extend the abstract classes. There is a cyclic group (maybe one fairly concrete and one more presentational). Take it for a spin and see if it solves your original complaint. Poke around in the (new) fg_abelian directory. Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/groups/opt_out.
Re: [sage-combinat-devel] Re: [sage-devel] SetPartitions output as sets?
(I thought I posted this last night, but don't see it now. Apologies if it is a duplicate.) Thanks everyone for the discussion, and to Mike for the Set(list()) incantation. It looks like that will preserve the ordering on the output and I will not need to edit a long string of subsequent doctests. On Tuesday, October 29, 2013 3:36:30 AM UTC-7, vdelecroix wrote: Why is a set partition not a set of sets ? My sentiment exactly. A newbie must first get over being returned an iterator (which is a good feature of the combinatorics routines). But then I'd hope that a request for objects that are sets would fully behave as sets, without further conversions. Rob -- You received this message because you are subscribed to the Google Groups sage-combinat-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-combinat-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-combinat-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-combinat-devel. For more options, visit https://groups.google.com/groups/opt_out.
[sage-devel] SetPartitions output as sets?
SetPartitions() used to create sets of sets (as of, say January 2013). That seems to be broken as most common methods on sets will fail (but not all). Any ideas on a simple fix or a good workaround (or an indication of what I am doing wrong)? I can use the standard_form() method to get a list of lists, which I can convert back to sets of sets, but that is very unnatural (and the reordering will mean lots of needless editing of a very long string of doctests). Thanks in advance for any ideas. I can make a trac ticket if that is called for. Rob sage: S = SetPartitions([1,2,3,4], [2,2]).list() sage: S [{{1, 2}, {3, 4}}, {{1, 3}, {2, 4}}, {{1, 4}, {2, 3}}] sage: S[0].cardinality() 2 sage: S[0].intersection(S[1]) AttributeError: 'SetPartitions_setparts_with_category.element_class' object has no attribute 'intersection' sage: Set(S[0]) TypeError: Element has no defined underlying set -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/groups/opt_out.
[sage-devel] Re: Short introductory note on Sage
I hope I'm not too late. That's a lot packed into two pages! Three nits follow. Rob v=vector(QQ, [1,2,3]) How about using spaces around the equals? Is this PEP-8? ;-) SageTeX package vs. sagetex package Maybe put the latter into a fixed-width font to suggest this is the package name when you use it pdf vs. PDF (=Portable Document Format) -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/groups/opt_out.
[sage-devel] Re: Reviewer apply_map to sparse vectors
Done. On Sunday, August 11, 2013 6:00:54 AM UTC-7, Thomas Feulner wrote: Hi, I fixed a bug in the apply_map method for sparse vectors, see #14558. The patch does only contain a few lines. Maybe someone is able to review it? Thanks Thomas -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/groups/opt_out.
Re: [sage-devel] Re: New Trac Server
Working well for me and looks great! Thanks, Andrew. When I get an email notification, there is a link to the whole ticket. A few hours ago, when I follow that link, Trac gave an error about not having a handler. New notifications seem to have links that work, so maybe the problem has been fixed. Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/groups/opt_out.
[sage-devel] Re: Products of permutations use nonstandard order of operation
On Saturday, July 13, 2013 2:22:41 AM UTC-7, Darij Grinberg wrote: But if Judson's book uses right-to-left and Sage uses left-to-right, shouldn't your materials actually become easier to use once the dust has settled? Yes, of course. It is me who will have trouble adjusting to the new convention. And I don't like dusting. ;-) Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/groups/opt_out.
[sage-devel] Re: Products of permutations use nonstandard order of operation
On Friday, July 12, 2013 4:43:09 PM UTC-7, darijgrinberg wrote: Is this too barbarous a solution? Is the problem not much of a problem? Thanks for bringing this off Trac and to the wider audience. Some thoughts. While less than ideal, I would not go so far as to call it a bug. But then I studied out of an older version of Herstein. ;-) I *always* check which ordering is employed when I pick up a new text or software system. I have had little trouble telling my students that their text (Judson) and Sage use different conventions. We follow Sage in all their work. Breaking doctests is one thing, breaking user code is another. I've written some rather extensive materials to incorporate in Judson's book, on Sage and elementary group theory (using permutation groups), following the Sage convention. All of the low-level elementwise stuff there would break with a change. I am not arguing against a change, we should just be aware that the pain goes beyond fixing up doctests. It is unfortunate that historical accidents like this (I assume Sage was following GAP's lead) are so hard to correct. I've had my own personal crusade on the row-vector and column-vector dichotomy, so I sympathize. I agree that setting the convention with a global variable is evil, and your example with Dyck words could be a good lesson on why. I hope somebody here can see a graceful way to improve the situation without too much pain or splattering. Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/groups/opt_out.
[sage-devel] Zero as a symbol for a permutation group
All, A power user sent me something akin to: sage: PermutationGroup([(1,2)]) Permutation Group with generators [(1,2)] sage: PermutationGroup([('a','b')]) Permutation Group with generators [('a','b')] sage: PermutationGroup([(0,1)]) --- ValueErrorTraceback (most recent call last) snip ValueError: Invalid permutation vector: [(0, 1)] We expanded the possibilities for symbol sets, and it would be nice if this 0-index case was picked up properly. I could not find a ticket anywhere, and will make one unless I hear otherwise that this is known (or needs review!). For the record, here's a reasonable workaround: sage: S = SymmetricGroup([0,1]) sage: S.subgroup([(0,1)]) Subgroup of (Symmetric group of order 2! as a permutation group) generated by [(0,1)] Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/groups/opt_out.
[sage-devel] Re: The 2013 Spies Prize winner is...
Congratulations, Jeroen! Well deserved. Thanks for all your excellent work with the releases! Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/groups/opt_out.
Re: [sage-devel] Re: use Sage!
On Monday, June 3, 2013 6:26:22 PM UTC-7, kcrisman wrote: That is true in this context, you are right - though I wonder if someone completely new to the community wanted to contribute something. I still think the real editorial board makes sense. Yes, I think an editorial board is an important feature of William's proposal. And a real one would be even better. ;-) Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
[sage-combinat-devel] Re: [sage-devel] Re: use Sage!
On Monday, June 3, 2013 9:41:19 AM UTC-7, William wrote: What do people think? Do you think we can create our own series, of just as high of quality as Springer, but more inexpensive for readers, and with a creative commons license? Yes. +1. Would somebody like Minh Nguyen be willing to do technical copyediting in exchange for a percentage of sales? Minh is too tough a copy editor. ;-) (Seriously, he would ensure the quality is very high.) Rob -- You received this message because you are subscribed to the Google Groups sage-combinat-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-combinat-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-combinat-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-combinat-devel?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
Re: [sage-devel] Re: use Sage!
On Monday, June 3, 2013 9:41:19 AM UTC-7, William wrote: What do people think? Do you think we can create our own series, of just as high of quality as Springer, but more inexpensive for readers, and with a creative commons license? Yes. +1. Would somebody like Minh Nguyen be willing to do technical copyediting in exchange for a percentage of sales? Minh is too tough a copy editor. ;-) (Seriously, he would ensure the quality is very high.) Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
Re: [sage-devel] Re: use Sage!
On Monday, June 3, 2013 11:16:54 AM UTC-7, kcrisman wrote: Intriguing idea. I think that you'd definitely need a real editorial board, with at least blind review (probably double-blind is unrealistic?). As a referee of articles for a popular journal published by a large mathematical society, I was polled by an editor about how I felt about their process moving to blind reviews. I emphatically stated that part of the appeal of contributing to Sage (rather than say writing research articles) included that reviews were *not* blind, and the positive-review/needs-work dichotomy of feedback. For a Sage book series, I'd expect some sort of prospectus or sample chapter process might be a better way to shepherd a project as demanding as writing a book (even a small one). Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
[sage-devel] Re: Sage Days 48 (Notebook), Sage Edu Days 5
If you are considering attending these two workshops in Seattle in June, there may still be funding available for you. Contact Rob Beezer if you are faculty and have an education-related project. Contact William Stein if you are a developer and have a notebook-related project. Rob On Tuesday, March 26, 2013 2:50:16 PM UTC-7, Rob Beezer wrote: A Sage Days devoted to the Sage Notebook development will be held at the University of Washington, June 17-21. This is sponsored by William Stein and John Palmieri's National Science Foundation COMPMATH grant [1]. At the end of the week, Sage Edu Days 5 will happen at the same venue, June 19-21. This is sponsored by the UTMOST education grant [2] from the National Science Foundation. Wiki pages are available with all the details (though housing arrangements are still being made). Links are available off the main Workshops page or at [3], [4]. Rob [1] http://modular.math.washington.edu/grants/compmath09/ [2] http://utmost.aimath.org/ [3] http://wiki.sagemath.org/days48 [4] http://wiki.sagemath.org/education5 -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
[sage-devel] Re: docbuild and lazy import
This seems to be fixed, without making any changes to lazy_import, see the ticket for details. For the record, my own problems building the documentation, when a new top-level directory is added by a patch, were solved by using sage --docbuild reference/matroids inventory sage --docbuild reference/matroids html or more easily, sage -docbuild all html Thanks to John Palmieri for getting me straightened out on this one. -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
Re: [sage-devel] Re: test changes on sage.tests.book_stein_ent
I have given this a lot of thought the past few years (perhaps this is obvious). I prepared extensive material about Sage for Tom Judson's Abstract Algebra book and have an automated procedure to produce doctests of the code examples. While I use sagetex for some aspects of this, the philosophy is the reverse. I provide expected output in the source, rather than just blindly letting Sage produce the output. In a few places I illustrate bugs, in hope of catching their corrections later. About twice a year, I update the source in response to failures in these doctests. Largely, these are just formatting or sorting changes. But it is obvious that over time significant bitrot can set in. So I think this is an extremely important part of writing about Sage - put in the infrastructure for testing, and revisit it regularly. I hope to make some progress this summer making such an infrastructure more usable than what I have done already. Relative to this thread, I have *never* felt that the Sage library should react to trivially-failing doctests associated with books. It should be the author's responsibility to keep the book current with the (changing) state of Sage. However, I do hope doctests from books, included in the Sage distribution, extend the protection against bugs, and further help developers as they produce code. So I very much agree with David's proposal below that such doctest files are clearly labeled with a maintainer. Further, I would suggest that we do not let the tail wag the dog by requiring patches to pass these tests. I would prefer not to see these files edited, so that they continue to reflect the source they come from. Of course, this leads to the situation where a doctest file might consistently produce many errors - an undesirable situation, especially if the maintainer is not very responsive. One solution might be to have entire books in the Sage distribution (in a source format that is not too large) and under revision control. Anyone could edit the code examples in response to patches, and the changes could be used by the author to update their canonical version. Perhaps this could all be accomplished in the spkg format, similar to making changes for upstream maintainers (along with scripts for generating books from source into different formats, such as web pages or PDF). I am not familiar enough with the technical mechanics of an spkg to be sure if this would be workable. Any informed opinions? Rob On Monday, May 20, 2013 1:34:27 AM UTC-7, David Loeffler wrote: We should have a clear policy on this, because it's been a contentious issue in the past. I remember this came up once with regard to a patch I had refereed, which changed an error message in finite fields and thus broke the doctests in sage/tests/french_book/. The original fix was just to change the doctests, but the authors of the French book were very highly displeased by this and insisted that the code be changed back to match the book. (See tickets #8334 and #12084.) It seems sensible to me that any file in the tests directory can have a nominated maintainer -- who should be clearly identified in the file header -- and the file should not be changed without consulting them. What do others think? If so, we should probably clarify this policy with a README file in sage/tests/. David -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
Re: [sage-devel] Huge patch on Trac 7477: Matroid theory
Dear sage-devel, Late to the party, as usual. I've been following the sage-matroid list since its inception, helping out where I can. Stefan, Rudi and others, have been *very* responsive to bug reports on their work-in-progress. The current users are a very knowledgeable bunch (both in mathematics and combinatorial computing), so the discussions about design decisions have been very thoughtful. I have a lot of confidence in the quality of this contribution. While I had hoped this did not become a patch bomb, I do agree with much of what Nathann has said. (1) The code is being used currently for research problems, so subtle bugs are being actively ferreted out. These are being fixed rapidly. (2) The (computational) matroid community will be a good addition to Sage's stable. (3) Development will be much faster and broader when this work is integrated into Sage proper. Much of the traffic on sage-matroid involves pecularities of implementing/running this as an add-on. (4) Stressing other parts of Sage (eg matrix code) should lead to improvements there. So I would be in favor of accepting this en masse if it had a knowledgeable review for fitting into Sage, as Nathann and Volcker propose. I also hope that the matroid community can commit to working with other developers in improving the matrix code (and perhaps other areas) to the point where they do not need to reimplement existing functionality. We are already seeing some of this at http://trac.sagemath.org/14627, so hopefully that can continue. Finally, thanks to the sage-matroid group for all their hard work on this. It is going to be another jewel in Sage's crown. Rob On Friday, May 3, 2013 8:17:44 AM UTC-7, Nathann Cohen wrote: I would vote for 1 among all alternatives... and trust the authors. As simple as that. I also do believe that considering the code they produced, they would be the first to fix bugs when they will be reported, be it a small problem or a larger one. It seems to be a work of care and good will :-) Nathann -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
[sage-devel] Re: QQ random_matrix()
Generally, it would be best to review the code for intent and test the output to see if the intent is realized. The documentation should then reflect this. Changing behavior would require a stronger rationale, such as bug you might discover when reviewing code and output. Feel free to cc me if you write a patch. Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
[sage-devel] Re: QQ random_matrix()
The zeros problem is known: http://trac.sagemath.org/sage_trac/ticket/11968 I could be responsible for some of this - but not all, as the documentation was in even worse shape before I attacked it. I might be able to revist some of this soon, but not immediately. Rob On Thursday, May 9, 2013 8:17:30 PM UTC-7, Kenneth Lin wrote: Hey everyone, So I'm not sure if I discovered two bugs in random_matrix or if I'm reading the documentation wrong. Firstly, in the documentation, it says: Random integer matrices. With no arguments, the majority of the entries are -1 and 1, never zero, and rarely large. sage: random_matrix(ZZ, 5, 5) [ -8 2 0 0 1] [ -1 2 1 -95 -1] [ -2 -12 0 0 1] [ -1 1 -1 -2 -1] [ 4 -4 -6 5 0] Now, it appears that there are 0's in the matrix produced. This also happens when I run the exact function above. Is this a bug in the documentation or the function? Secondly, the documentation says this about random matrices in rational fields: Random rational matrices. Now num_bound and den_bound control the generation of random elements, by specifying limits on the absolute value of numerators and denominators (respectively). Entries will be positive and negative (map the absolute value function through the entries to get all positive values), and zeros are avoided unless the density is set. If either the numerator or denominator bound (or both) is not used, then the values default to the distribution for ZZ described above that is most frequently positive or negative one. However, when I run coderandom_matrix(QQ, 10, 10)/code, it appears all the numbers are either 0, 1, 2, -1, -2, 1/2, and -1/2. This doesn't seem to be the most frequently positive or negative one distribution, but instead the uniform one for integers. I could imagine it being such that two numbers every time with the uniform distribution as the numerator and denominator and the two are divided. Could anyone else verify this behavior? Thanks -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
[sage-devel] Re: Sage Days 48 (Notebook), Sage Edu Days 5
Dear Greg, We'd love to have you and can provide funding. Airfare and lodging, but you are on your own for food. Hotel Deca should be organized soon, you'll need to make your own reservation then. Sharing a room is encouraged. Please let Tom Judson (cc'ed on this) know your travel dates and cost of your plane ticket. He's keeping track of the budget. US carriers only - you know the drill. Please add yuorself to the wiki page, or let me know and I can do it. Karl-Dieter has a book project (number theory and Sage) and I'm big into books, so maybe your Sage Guide project will be of common interest. I do not know of any such screencasts, so that would be a good project also, I think. Put that on the wiki too. ;-) Gotta run, see you in Seattle in June! Rob On 03/27/2013 07:44 AM, Gregory Bard wrote: Hi there. I'd be up for this. It has been a while since I've had time to really work together with SAGE people. On a note that is intermediately related, I had been thinking of a five video series, each 5-10 minutes, that would be screen-casts of my explaining the basics of SAGE. There would be a basic one, a graphing one, a calculus one, a matrices one, and maybe a number theory one. I'm thinking of a calculus one and below level audience. Of course, the vids would be perfectly useable by higher-level students too. Has this been done before? While it wouldn't take too much time, I don't want to invest my time in something redundant! I have a stockpile of humorous examples, like the nervous-breakdown function: f(x) = sin( exp( 1/(2-x) ) ) which is fun to graph from 0 to 3. Thoughts? ---Greg p.s. I'd love to work further on my SAGE guide, including SAGE projects for the precalc, calc 1, calc 2 levels. Often I find that conversations with TAs can be productive sources of ideas. On Tuesday, March 26, 2013 4:50:16 PM UTC-5, Rob Beezer wrote: A Sage Days devoted to the Sage Notebook development will be held at the University of Washington, June 17-21. This is sponsored by William Stein and John Palmieri's National Science Foundation COMPMATH grant [1]. At the end of the week, Sage Edu Days 5 will happen at the same venue, June 19-21. This is sponsored by the UTMOST education grant [2] from the National Science Foundation. Wiki pages are available with all the details (though housing arrangements are still being made). Links are available off the main Workshops page or at [3], [4]. Rob [1] http://modular.math.washington.edu/grants/compmath09/ http://modular.math.washington.edu/grants/compmath09/ [2] http://utmost.aimath.org/ [3] http://wiki.sagemath.org/days48 http://wiki.sagemath.org/days48 [4] http://wiki.sagemath.org/education5 http://wiki.sagemath.org/education5 -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
[sage-devel] Sage Days 48 (Notebook), Sage Edu Days 5
A Sage Days devoted to the Sage Notebook development will be held at the University of Washington, June 17-21. This is sponsored by William Stein and John Palmieri's National Science Foundation COMPMATH grant [1]. At the end of the week, Sage Edu Days 5 will happen at the same venue, June 19-21. This is sponsored by the UTMOST education grant [2] from the National Science Foundation. Wiki pages are available with all the details (though housing arrangements are still being made). Links are available off the main Workshops page or at [3], [4]. Rob [1] http://modular.math.washington.edu/grants/compmath09/ [2] http://utmost.aimath.org/ [3] http://wiki.sagemath.org/days48 [4] http://wiki.sagemath.org/education5 -- You received this message because you are subscribed to the Google Groups sage-devel group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
Re: [sage-devel] JMM 2013 Sage Booth
On Monday, December 3, 2012 1:57:20 PM UTC-8, Dan Drake wrote: I can bring stickers, since Rob Beezer's office is just down the hall. :) I have about 450 stickers left from the last purchase. Plan A was to mail them to William's brother in SD, but I'll just walk them the 50 feet to Dan's office instead. ;-) Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To post to this group, send email to sage-devel@googlegroups.com. To unsubscribe from this group, send email to sage-devel+unsubscr...@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en.
[sage-devel] Re: Extra loop created in a graph
Thanks, Tom and Nathann, for the replies. I'll have a look at the patch later today. Yes, I agree, all graphs should be simple graphs. ;-) Rob On Thursday, November 29, 2012 5:24:26 AM UTC-8, Nathann Cohen wrote: This is now ticket #13775, which is waiting to be reviewed. Sorry for that, that's my mistake But I do really hate loops and multiple edges :-/ Nathann On Thursday, November 29, 2012 2:14:22 PM UTC+1, Nathann Cohen wrote: Anybody recognise this bug? I don't see anything in Trac. Yes. It is a bug that occurs when your graphs have loops. Having loops is always a bad idea. Loops should be forbidden. Multiedges too. Labels too. I'll give it a look. God I hate loops. Nathann -- You received this message because you are subscribed to the Google Groups sage-devel group. To post to this group, send email to sage-devel@googlegroups.com. To unsubscribe from this group, send email to sage-devel+unsubscr...@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en.
[sage-devel] Extra loop created in a graph
Anybody recognise this bug? I don't see anything in Trac. T=[(0, 2, '0'), (3, 3, '2'), (0, 2, '1')] Gt = Graph(T) Gt.loops() [(3, 3, '2')] versus S=[(0, 2, '0'), (0, 2, '1'), (3, 3, '2')] Gs = Graph(S) Gs.loops() [(3, 3, '2'), (3, 3, '2')] Thanks, Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To post to this group, send email to sage-devel@googlegroups.com. To unsubscribe from this group, send email to sage-devel+unsubscr...@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en.
[sage-devel] Re: coercion and subclasses
On Saturday, November 3, 2012 8:44:19 AM UTC-7, jason wrote: Rob Beezer, what do you think? Well, my first thought is that I am glad you and Volker are getting to the bottom of this. I knew scalars were only working on the wrong side, but I'd been under the (mistaken) impression this was the case in the superclass as well. Like Volker, I'd like to keep the matrix dimension checks in the over eager error-checking. While building the class for vector space morphisms (aka linear transformations), I discovered several bogus doctests for free module morphisms which were passing because it was replicating mathematically incorrect computations. These were simply row/column, left/right, domain/codomain mixups, which would have been caught with some matrix-dimension checks. So I think these simple checks can prevent some fairly common, and easy-to-make, mess-ups. Please cc me on any ticket. Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To post to this group, send email to sage-devel@googlegroups.com. To unsubscribe from this group, send email to sage-devel+unsubscr...@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en.
[sage-devel] Re: public worksheets
On Thursday, October 4, 2012 2:50:25 PM UTC-7, jason wrote: to demo.sagenb.org as a test. I've been regularly getting 503 Service Unavailable No server is available to handle this request. back from demo.sagenb.org the past couple of days. Has anybody else been successful testing these changes? Thanks, Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To post to this group, send email to sage-devel@googlegroups.com. To unsubscribe from this group, send email to sage-devel+unsubscr...@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en.
Re: [sage-devel] Re: public worksheets
Thanks, Andrea. I want to run some of textbook-worksheets through this, especially since they have been mangled by the lxml module once already. ;-) Rob On Saturday, October 6, 2012 1:29:01 PM UTC-7, Andrea Lazzarotto wrote: 2012/10/6 Rob Beezer goo...@beezer.cotse.net javascript: Has anybody else been successful testing these changes? No. Partially because I got those errors too and partially because I'm waiting to be authorized by Jason to intentionally try to inject some proof of concept XSS in the public worksheets. -- *Andrea Lazzarotto* - http://andrealazzarotto.com* * -- You received this message because you are subscribed to the Google Groups sage-devel group. To post to this group, send email to sage-devel@googlegroups.com. To unsubscribe from this group, send email to sage-devel+unsubscr...@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en.
[sage-devel] Re: Pari stack growning out of bounds
To summarize some of this discussion more carefully: Eigenvalues of a symmetric rational matrix should already land in the algebraic field (AA), so there is no need to convert them. Error messages appear to come from QQbar, since much of the functionality of AA is contained in the same module as QQbar. sage: G = graphs.GridGraph([2,3]) sage: spec = G.spectrum(); spec [2.414213562373095?, 1, 0.4142135623730951?, -0.4142135623730951?, -1, -2.414213562373095?] sage: spec[0].parent() Algebraic Field Eigenvalues of rational matrices come from roots of the characteristic polynomial - for graphs this is the adjacency matrix. If you want more control, you can get the adjacency matrix (am) and then the factored characteristic polynomial (fcp) and deal with that. sage: G.am().fcp() (x - 1) * (x + 1) * (x^2 - 2*x - 1) * (x^2 + 2*x - 1) If numerical results are good enough you can convert the adjacency matrix to floating-point entries and get numerical eigenvalues. sage: A = G.am().change_ring(RDF) sage: A.eigenvalues() [-2.41421356237, 2.41421356237, -1.0, -0.414213562373, 1.0, 0.414213562373] But for large graphs, the above will sometimes produce (seemingly) complex roots with near-zero imaginary parts. The 'symmetric' (or 'hermitian') keyword will use more specialized SciPy routines that yield real eigenvalues, and also find them faster. sage: A.eigenvalues(algorithm=symmetric) [-2.41421356237, -1.0, -0.414213562373, 0.414213562373, 1.0, 2.41421356237] Since computing eigenvalues is equivalent to finding roots of polynomials, you can pick your poison here. (Maybe some documentation in the graph-spectrum method about the (new) symmetric numerical algorithms is warranted?) Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To post to this group, send email to sage-devel@googlegroups.com. To unsubscribe from this group, send email to sage-devel+unsubscr...@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en.
[sage-devel] Re: Pari stack growning out of bounds
Thanks, Dima. On Tuesday, September 25, 2012 10:08:13 AM UTC-7, Dima Pasechnik wrote: So this is a bug... Maybe more like: my mistake. I had my print versions of the complex/real algebraic numbers mixed up. Here is the essence of how these (exact) eigenvalues are computed for rational matrices (not just adjacency matrices of graphs). It would be a definite improvement to recognize symmetric matrices (through a keyword or an optional check) and then create these roots in AA rather than QQbar. sage: G = graphs.GridGraph([3,2]) sage: p = G.am().fcp(); p (x - 1) * (x + 1) * (x^2 - 2*x - 1) * (x^2 + 2*x - 1) sage: f = p[2][0]; f x^2 - 2*x - 1 sage: evs = f.root_field('t').gen(0).galois_conjugates(QQbar); evs [-0.4142135623730951?, 2.414213562373095?] sage: evs[0].parent() Algebraic Field sage: evs = f.root_field('t').gen(0).galois_conjugates(AA) sage: evs[0].parent() Algebraic Real Field -- You received this message because you are subscribed to the Google Groups sage-devel group. To post to this group, send email to sage-devel@googlegroups.com. To unsubscribe from this group, send email to sage-devel+unsubscr...@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en.
[sage-devel] Re: Pari stack growning out of bounds
Some of your eigenvales (many?) are in QQbar, the field of algebraic numbers. Testing equality in this field is extremely expensive for some reason. Also, sum() is sufficiently generic, that I think it is not very efficient either. A recent patch implements eigenvalues of symmetric matrices with floating point entries. Which will be real for adjacency matrices of your graph. This might be good enough for you, and was the orginal motivation for the patch. Can't recall if this patch has been reviewed/merged, or not. Rob On Monday, September 24, 2012 1:18:03 PM UTC-7, Jernej Azarija wrote: Consider the following program that computes the spectrum and chromatic number of a graph: for g in graphs.nauty_geng(str(7)): s = g.spectrum() g.chromatic_number() This works quickly and like a charm. Now consider the following program that computes something related to the spectrum and chromatic number: for g in graphs.nauty_geng(str(7)): s = g.spectrum() sp = sum([el**2 for el in s if el 0]) sm = sum([el**2 for el in s if el 0]) if sm != 0 and not (sp/sm+1 = g.chromatic_number()): print g.graph6_string() The program gets stuck in computing something for a long time and in the end it dies trying to allocate a ~7GB pari stack: File minw.py, line 9, in module if sm != _sage_const_0 and not (sp/sm+_sage_const_1 = g.chromatic_number()): File element.pyx, line 902, in sage.structure.element.Element.__richcmp__ (sage/structure/element.c:8480) File element.pyx, line 847, in sage.structure.element.Element._richcmp (sage/structure/element.c:7930) File element.pyx, line 829, in sage.structure.element.Element._richcmp_ (sage/structure/element.c:7659) File element.pyx, line 874, in sage.structure.element.Element._richcmp (sage/structure/element.c:8342) File /home/azi/sage-5.3.rc1/local/lib/python2.7/site-packages/sage/rings/qqbar.py, line 3755, in __cmp__ rcmp = cmp(self.real(), other.real()) File /home/azi/sage-5.3.rc1/local/lib/python2.7/site-packages/sage/rings/qqbar.py, line 4395, in __cmp__ return self._sub_(other).sign() File /home/azi/sage-5.3.rc1/local/lib/python2.7/site-packages/sage/rings/qqbar.py, line 4611, in sign return self.sign() File /home/azi/sage-5.3.rc1/local/lib/python2.7/site-packages/sage/rings/qqbar.py, line 4614, in sign self.exactify() File /home/azi/sage-5.3.rc1/local/lib/python2.7/site-packages/sage/rings/qqbar.py, line 3466, in exactify self._set_descr(self._descr.exactify()) File /home/azi/sage-5.3.rc1/local/lib/python2.7/site-packages/sage/rings/qqbar.py, line 7591, in exactify left.exactify() File /home/azi/sage-5.3.rc1/local/lib/python2.7/site-packages/sage/rings/qqbar.py, line 3466, in exactify self._set_descr(self._descr.exactify()) File /home/azi/sage-5.3.rc1/local/lib/python2.7/site-packages/sage/rings/qqbar.py, line 7334, in exactify arg.exactify() File /home/azi/sage-5.3.rc1/local/lib/python2.7/site-packages/sage/rings/qqbar.py, line 3466, in exactify self._set_descr(self._descr.exactify()) File /home/azi/sage-5.3.rc1/local/lib/python2.7/site-packages/sage/rings/qqbar.py, line 7591, in exactify left.exactify() File /home/azi/sage-5.3.rc1/local/lib/python2.7/site-packages/sage/rings/qqbar.py, line 3466, in exactify self._set_descr(self._descr.exactify()) File /home/azi/sage-5.3.rc1/local/lib/python2.7/site-packages/sage/rings/qqbar.py, line 7591, in exactify left.exactify() File /home/azi/sage-5.3.rc1/local/lib/python2.7/site-packages/sage/rings/qqbar.py, line 3466, in exactify self._set_descr(self._descr.exactify()) File /home/azi/sage-5.3.rc1/local/lib/python2.7/site-packages/sage/rings/qqbar.py, line 7593, in exactify gen = left._exact_field().union(right._exact_field()) File /home/azi/sage-5.3.rc1/local/lib/python2.7/site-packages/sage/rings/qqbar.py, line 2276, in union newpol, self_pol, k = pari_nf.rnfequation(my_factor, 1) File gen.pyx, line 10412, in sage.libs.pari.gen._pari_trap (sage/libs/pari/gen.c:54794) File gen.pyx, line 9718, in sage.libs.pari.gen.PariInstance.allocatemem (sage/libs/pari/gen.c:50859) File gen.pyx, line 10233, in sage.libs.pari.gen.init_stack (sage/libs/pari/gen.c:53888) MemoryError: Unable to allocate 6553600 bytes memory for PARI. What exactly is going on? From what I've checked into the sources I do not see what is causing this issue? Am I doing something stupid in the second sage program or is this some kind of Sage-Pari bug? Best, Jernej -- You received this message because you are subscribed to the Google Groups sage-devel group. To post to this group, send email to sage-devel@googlegroups.com. To unsubscribe from this group, send email to sage-devel+unsubscr...@googlegroups.com. Visit this group at
Re: [sage-devel] Pari stack growning out of bounds
On Monday, September 24, 2012 1:29:24 PM UTC-7, John Cremona wrote: Does anyone know why QQbar is being used here? For simple graphs, the adjaceny matrix will be symmetric, so the eigenvalues could go into AA instead of QQbar, but I would guess the problem (comparison with zero) might persist? Where would you suggest they go? Right now, I think these are just eigenvalues of a matrix over QQ with those outside of QQ going into QQbar (iirc). Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To post to this group, send email to sage-devel@googlegroups.com. To unsubscribe from this group, send email to sage-devel+unsubscr...@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en.
[sage-devel] Re: LibGAP spkg vote!
On Sunday, September 23, 2012 6:40:40 AM UTC-7, Volker Braun wrote: Per the usual rules, new spkgs need a vote so now is your chance to be heard ;-) Anything that improves the reliability and speed of code built on GAP is a +1 from me. Thanks, Volker, for this, and your recent work (along with others) on the upgrade to the latest GAP version! Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To post to this group, send email to sage-devel@googlegroups.com. To unsubscribe from this group, send email to sage-devel+unsubscr...@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en.
Re: [sage-devel] Re: Normalization of a vector
On Wednesday, September 19, 2012 1:52:24 PM UTC-7, Robert Bradshaw wrote: There is the issue that norm(v) does not always (often?) live in v for exact v. Dropping to SR can be really slow, as can dropping to QQ[sqrt(norm(v))], especially if several vectors are normalized then used together (though I'm sure we could find/write a fairly efficient multi-quadratic extension implantation that could be more generally useful). Exactly. I'd feel a lot better about the proposed change if there was no way to ever end up in the symbolic ring (unless, of course, your vector began there). Having square roots of integers be symbolic (an inexact ring) causes no end of trouble when trying to do things like matrix decompositions over exact rings (such as starting over QQ). At least we have QQbar for square roots of rationals and integers. This was pointed out to me by someone who teaches undergrads and found it frustrating that Sage was not doing the standard normalization. Making things more predictable for undergrads is always a good idea. Why don't we go all the way? Have normalization() return a vector over RDF/CDF. I think this is what most people would think it should do. Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To post to this group, send email to sage-devel@googlegroups.com. To unsubscribe from this group, send email to sage-devel+unsubscr...@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en.
[sage-devel] Re: inner product of complex vectors
On Wednesday, September 12, 2012 10:04:54 AM UTC-7, jason wrote: I'm curious: is there a good reason why the product of two complex vectors does not conjugate the first vector (which would yield the standard inner product for complex vectors). I think because I lost the argument that William advances. But I did implement: sage: v=vector(CDF,[2+I,5]) sage: v.hermitian_inner_product(v) 30.0 Docstring for .inner_product() says: Note: If your vectors have complex entries, the hermitian_inner_product() may be more appropriate for your purposes. Inner products in Sage also have an inner product matrix to do a weighting or a quadratic form or some such thing, but I don't think they are fully implemented/realized across all the possible occasions where they would make sense. But this is just a hazy memory. Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To post to this group, send email to sage-devel@googlegroups.com. To unsubscribe from this group, send email to sage-devel+unsubscr...@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en.
[sage-devel] Re: This year's bug days
On Wednesday, September 5, 2012 5:12:14 PM UTC-7, William wrote: This could range from places to have them Good news! This place http://www.talarisconferencecenter.com/ is very close to UW, but has lots of open space (for being so close to the center of the city). It would make it more convenient for out-of-towners to travel from the airport and more convenient for locals to participate partially (some days or some hours). But it would also make it more tempting for locals to go home at night instead of coding until 2 AM (or later). With some sort of in-house group food service or catering it might have a similar feel as Wallace Falls. But I've never been there myself, so it might require a visit to see if it is suitable. John Travis and Jason Aubrey stayed here for the most recent Edu Days when I asked them about it, I think they thought it might work well for a Bug Days. Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To post to this group, send email to sage-devel@googlegroups.com. To unsubscribe from this group, send email to sage-devel+unsubscr...@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en.
[sage-devel] Re: sign of permutations
On Tuesday, September 4, 2012 6:21:11 AM UTC-7, John Cremona wrote: If pi is a permutation, e.g. defined by pi=permutations(4)[3], then pi.signature() returns what I have always called the sign of pi, and none of pi.sign(), pi.sgn(), sign(pi), sgn(pi) work. But: sage: G = SymmetricGroup(2) sage: a = G((1,2)) sage: a.sign() -1 So I'd say +1 to greater coordination between group element permutations and purely combinatorial permutations overall, and in particular having .sign() as John suggests for the other permutations. Rob -- You received this message because you are subscribed to the Google Groups sage-devel group. To post to this group, send email to sage-devel@googlegroups.com. To unsubscribe from this group, send email to sage-devel+unsubscr...@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en.
[sage-devel] Families and constructions of permutation groups
Kevin Halasz is an undergraduate student who has been working to add collections of permutation groups to Sage's collection as a funded summer research project. He has several patches now ready, one is from several weeks ago. I thought I would advertise them here, since classes start back up for Kevin on August 27 (and me too!). I have worked closely to help him organize these patches properly, and will work closely with him to answer any comments from reviewers. So potential reviewers should not fear having to provide extensive guidance on coding style or docstrings to a new contributor - I'll be doing that. Kevin also already has a (merged) one-character, but non-trivial, documentation patch to his credit. The goal of Kevin's project has been to make the creation of any group of order 31 or less available as a permutation group with a simple, but natural, Sage command. I think this collection of patches will do that, but he may still need to go back and carefully check. Kevin would like to study group theory in graduate school, so it would be great to encourage him with some reviews of his work, if you are familiar with the permgroups code. Thanks, Rob ~~~ General Dihedral Groups A construction of the semidirect product of C2 with any abelian group http://trac.sagemath.org/sage_trac/ticket/13251 Semidirect Product Totally general construction, wrapping GAP's command http://trac.sagemath.org/sage_trac/ticket/13365 Semidihedral Groups and Split Metacyclic Groups Families of 2-groups and p-groups http://trac.sagemath.org/sage_trac/ticket/13366 Holomorph of a Group The semidirect product of a group with its automorphism group (This is in-progress, but should be ready very soon.) http://trac.sagemath.org/sage_trac/ticket/13367 -- -- 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: groupsdot
This patch is now ready for review. I've taken inspiration from the recent discussion about factory functions for Fano polytopes [1], and achieved the groups.tab effect with a sequence of import foo as bar commands as a new view of on top of the existing organization of the code for groups. It goes two-deep, so for example, you will go groups.matrix.tab to see all the matrix groups. In light of all the discussion about startup time and importing modules [2], I'm wondering if this is an improvement on the current situation of importing various groups individually into the global namespace. Certainly it is worse now, since I have just added on and not removed anything. But if starting from scratch, or deprecating old imports, is the approach I've taken better? If so, it could be a model for changes elsewhere (posets, designs, graphs). If somebody knowledgeable wanted to comment on the question of import efficiency, that would be very helpful long-term. (Which is not necessarily a request for a full review of the whole ticket.) Thanks, Rob [1] https://groups.google.com/d/topic/sage-devel/B28yuvAlo3A/discussion {2] https://groups.google.com/d/topic/sage-devel/pqpDrJw1AnA/discussion -- -- 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] Units in Orders
On Saturday, August 11, 2012 1:22:05 PM UTC-7, Marco Streng wrote: These outputs look fine to me. See also http://trac.sagemath.org/sage_trac/ticket/11673 Dear Marco, Thanks for the pointer to that ticket, which explains the change in the the is_unit() behavior. Why should the inverse of four succeed when the result is not in K? sage: four^-1 in K False On #12242 (a follow-on to the ticket above), David Loeffler argues that the following is the wrong behavior, and that the last command should raise an error. sage: K.a = NumberField(x^2 - x - 1); OK = K.ring_of_integers() sage: OK(12).divides(OK(13)) True sage: OK(12) // OK(13) 12/13 Thanks, Rob -- -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org
[sage-devel] Units in Orders
Is this a bug? First example is from Judson's abstract algebra text. Note that .is_unit() returned True in sage 4.8. sage: sage: K.x,y = ZZ[sqrt(-3)]; K Order in Number Field in a with defining polynomial x^2 + 3 sage: four = K(4) sage: four.is_unit() False sage: four^-1 1/4 Second example: all but the last input is basically from the documentation of .is_unit(). sage: K.a = NumberField(x^2 - x - 1) sage: OK = K.ring_of_integers() sage: u = OK(13) sage: u.is_unit() False sage: u^-1 1/13 Thanks, Rob -- -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org
[sage-devel] Elements of lattice of integer decompositions
Another failing doctest from Judson's abstract algebra text. How does one now make elements of the lattice of integer decompositions? sage: CP = Posets.IntegerCompositions(5) sage: C = LatticePoset(CP) sage: elts = list(C); elts [[5], [1, 4], [4, 1], [1, 3, 1], [3, 2], [1, 2, 2], [3, 1, 1], [1, 2, 1, 1], [2, 3], [2, 1, 2], [2, 2, 1], [2, 1, 1, 1], [1, 1, 3], [1, 1, 1, 2], [1, 1, 2, 1], [1, 1, 1, 1, 1]] sage: C([1,4]) ... TypeError: unhashable type: 'list' sage: C((1,4)) ... ValueError: type 'tuple' is not an element of this poset This worked in 4.8: sage: C.meet([1,1,1,2], [2,1,1,1]) [2, 1, 2] And still works if you grab the elements from the list: sage: a = elts[13]; b = elts[11] sage: C.meet(a, b) [2, 1, 2] Thanks, Rob -- -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org
[sage-devel] Re: Workshop in Edinburgh: Online databases: from L-functions to combinatorics
On Wednesday, August 8, 2012 8:28:03 AM UTC-5, Volker Braun wrote: So it would be nice to have a online service to hook into if you just want to look up something. See http://www.lmfdb.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: should we check for openssl in prereq?
As one who was bit by this, +1. On Thursday, August 2, 2012 8:46:47 PM UTC-5, John H Palmieri wrote: Given the number of people who have problems installing Sage because their system is missing openssl, should we check for that in the prereq script, so that the error is caught as soon as possible, and so that we can write a good error message? (Note that I'm not volunteering to do this, because I don't really know how...) -- 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
[sage-devel] Re: Documenting Factory Functions (RE trac #13282)
Dear Samuel, See if the following might work. 1. Add a module-level docstring in polytopes_grdb.py. The should appear when one does polytopes_grdb? and it should appear in the documentation when included properly. 2. In the docstring, make an organized table of contents for each of the methods you are importing from polytopes_grdb_backend.py with a ReST-formatted link to each (syntax like :func:`~sage.foo.bar`), and explain the purpose of this object/module. 3. Document the individual functions like normal, but maybe include a note :: saying You can get bar() easily with polytopes_grdb.bar() Include a test in each function that creates the object via the polytope_grdb module. I have not tried out all of this, but I have used the module level docstring for a table of contents to the object for groups that I was building (but will refactor into a module), so I have some confidence in that part. Others may have better ideas (or corrections). One big advantage is you can organize the module docstring however you like with the links to the individual functions. This is in contrast to the HTML/PDF documentation for polytopes_grdb_backend.py which will list the functions in alphabetical order. Rob On Tuesday, July 31, 2012 9:49:53 AM UTC-7, samgonshaw wrote: Well, I've gone for this attempt and have ended up with two files, polytopes_grdb_backend.py that contains all my functions, and polytopes_grdb.py that just imports the functions we want to appear to the user, and then all.py imports polytopes_grdb. The problem here is that even if I write the documentation in polytopes_grdb_backend as though they were functions in polytopes_grdb this is fine for in-sage documentation, what about for the reference documentation? If I tell Sphinx to add polytopes_grdb to the documentation, nothing will appear, as the documentation is in polytopes_grdb_backend; but if I tell it to bring up polytopes_grdb_backend then the functions are shown to the user as living there and not in polytopes_grdb as we want them to believe. Thoughts? Sam. -- -- 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: Documenting Factory Functions (RE trac #13282)
On Monday, July 30, 2012 10:31:49 AM UTC-7, Nils Bruin wrote: In python there is the concept of a module as well as a class. Modules can do that much better. The pattern Samuel suggests shows up several places in Sage, such as for examples of graphs and posets. I'm doing something similar for groups at http://trac.sagemath.org/sage_trac/ticket/13115 which I should probably rethink and retool slightly in light of Nils' comments (thanks, Nils). Then the thing to do would be to write my_functions = full/relative name of the module with the functions A small amount of experimenting suggests this approach is very compatible with tab-completion, which is one of the main features of building such a collection. However, tab-completion exposes some irrelevant module-level cruft, like anything that gets imported at the top of the module (eg ZZ, say). So the module would need to be fairly clean I'd think, with *just* the desired functions, though a module-level docstring is a nice thing to employ. Where should the statement defining my_functions go? Someplace at a level above the module itself? In the all.py at that level? Rob -- -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org
[sage-devel] Re: Documenting Factory Functions (RE trac #13282)
On Monday, July 30, 2012 1:31:53 PM UTC-7, Nils Bruin wrote: While I agree that tab completion is very useful as a low-cost documentation tool, I find it a little worrisome if our design decisions come to be dominated by having tab completion generate appropriate indices. In lots of cases it will go hand in hand with writing clean code to begin with (messy namespaces are often a sign of messy code), but if it forces us to go through strange contortions (like a separate index namespace module as above) perhaps we have to rethink our use of tab completion. Thanks, Nils, for the explication - that is very helpful. And thanks, Mike, for the IPython pointer. I agree that we shouldn't be making messes to drive tab-completion. But as always, we have design decisions from the past, which we might want to change with hindsight. In this case, most groups are now available via imports into the global namespace. They are easy to find, if you already know they are there and what their names are. ;-) As usual, I'm trying to help the beginner get started quickly and easily with a large collection of examples. The current approach I've been taking (and perhaps the one originally proposed in this thread) means a lot of (unnecessary) duplication. And I have written new/additional/consistent/modern documentation that would be better added to improve the original classes. While perhaps galling, it sounds to me like layering a separate index namespace module on top of the current disorganization will be a small price to pay for a big improvement in usability and will be much more maintainable down the road. Thanks again, Rob -- -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org
Re: [sage-devel] Re: groupsdot
Thanks, William, for the interest. Course looks like fun. Patch is in good enough shape that you could show it to the students as an example of Sage's evolution. Or an example of having your wishes granted. ;-) Rob On Thursday, July 26, 2012 8:36:42 PM UTC-7, William wrote: I'm really glad you're doing this. During my course for high school kids today [1], they asked what can Sage do with groups, and I was disappointed with groups.[tab] in sage-5.2. I'm really happy you're improving this. [1] https://github.com/williamstein/simuw12 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: groupsdot
On Monday, June 11, 2012 2:51:37 PM UTC-7, Rob Beezer wrote: We have objects which conveniently organise examples of certain (named) mathematical objects, such as graphsdot, digraphsdot and posetsdot (and others?). These also help keep the global namespace a little cleaner. I'd like to do the same thing with groups. A patch with substantial progress is at: http://trac.sagemath.org/sage_trac/ticket/13115 along with some guidance on my thinking along the way. This is not quite ready for review, but has passing doctests, good documentation, etc. If you want to shape the final product, now would be a good time to comment before I do some more (repetitive) work in the same mold. Thanks, Rob -- -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org
Re: [sage-devel] Re: Matrix groups from GAP
Thanks everyone for your helpful posts, which came in overnight. We have the classical groups (GL, SL,...) from GAP as groups of matrices (in a natural way) and we have the projective versions (PGL, PSL,...) from GAP as permutation groups. Testing indicates you cannot switch it around (projective versions as matrices, plain versions as groups of matrices, from GAP). Maybe GAP has an efficient conversion between the two implementations, but I'm not seeing it. We have an interesting, but incomplete, collection of permutation groups. So it seems that we have implementations tied tightly to the groups themselves right now. I was suggesting loosening this up some (though that was not the point of my question). Simon - I was not aware of parents with multiple realisations, so I will pursue that. Thanks, Little Nicolas, for the introduction. It will be helpful as I am still at level 0.5 with categories. (And I'm glad to see that *somebody* in France is working during the holiday season!) Finally, Javier, I have not kept up with the group presentations ticket, which will be a great addition, so I'm glad to see that progressing. Rob -- -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org
Re: [sage-devel] Re: Matrix groups from GAP
On Thursday, July 19, 2012 8:47:20 AM UTC-7, Nathann Cohen wrote: If nobody needs it before I will probably write the patch when I am back from traveling, something around mid september. Cool, Cool, Cool ! :-) Dear Nathan, It'd sure be great to have automorphism groups of graphs start their symbol sets back at 0! And perhaps optionally use vertex labels. sage: G = SymmetricGroup([0, 1, 2]); G Symmetric group of order 3! as a permutation group sage: G.domain() {0, 1, 2} sage: G = SymmetricGroup(['dog', 'cat', 'fish']); G Symmetric group of order 3! as a permutation group sage: G.domain() {'dog', 'cat', 'fish'} I have not investigated the following yet. I thought tuples being hashable was sufficient. sage: G = SymmetricGroup([(1,0), (0,1)]) ... TypeError: not all arguments converted during string formatting Rob -- -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org
[sage-devel] Matrix groups from GAP
I'm working (along with a summer research student) to expand the collection of small groups (and their representations) in Sage. A question about matrix groups, as built by GAP for Sage. For small, not-very-sophisticated groups, such as a Dihedral group, is it preferable to concoct generators in Sage and use the generic MatrixGroup() constructor or use a GAP routine to build the group? A simple example: GAP: Wrap - CyclicGroup( IsMatrixGroup, GF(2), 12 ) will build a matrix group of order 12 with matrices of size 12, over a few different types of fields. This is about as much freedom as GAP allows. Python: Mythical - CyclicMatrixGroup(n, R, dimension=None) to build a cyclic group of order n over R, but where dimension could default to n, or be sum of invariants, or sum of prime powers, or 1 over the cyclotomic field. Then an appropriate matrix could be created and sent to the MatrixGroup() (ideally as part of a class providing a sensible repr, etc.) The second approach allows for a lot more flexibility in providing representations of different dimensions. My question: is much lost by building the generators and computing the GAP group from those, versus using the built-in GAP named constructions? Again, I'm just interested right now about simpler matrix groups, not the classical groups like GL(), PSL(), etc. Thanks, Rob -- -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org
[sage-devel] Abelian groups: will write doctests for design advice
I've been working off-and-on the past two years to implement finitely-generated abelian groups in a unified way that makes it easy to create and maintain specialized versions of these groups (in large part for instructional purposes). We have the multiplicative AbelianGroup() which seems hard-coded to use powers of symbols as its elements. We also have AdditiveAbelianGroup() which works well, but does not allow for subgroups. Loeffler, Cremona, Stankewicz, Palmieri and Bradshaw built AdditiveAbelianGroup on top of Stein's code for finitely-generated modules over PIDs, which is an excellent approach, and the one I'd like to extend, but in a more general fashion. I'd like to eventually propose a working alternative that we could transition to gradually and smoothly. The code for categories, parents and elements, along with Simon King's excellent tutorials make this much easier than it was a couple years ago. However, I've reached the head-banging stage on a couple sticky points, primarily the element constructor and trying to override the additive operations in the modules to create multiplicative groups that pass the TestSuite(). So I'm trolling for some knowledgeable help with getting over a couple humps on this one. Suppose you know the parent/element, category, coercion/conversion, and morphism concepts well but hate writing doctests. Here's the deal: advise me and I'll happily do the dirty work. More details on the ticket, plus a heavily documented patch containing many functional doctests. http://trac.sagemath.org/sage_trac/ticket/9773 Thanks, Rob -- -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org
Re: [sage-devel] Re: Is left_kernel_matrix missing intentionally?
So William knows my memory is faulty, and I finally overcame my own laziness and looked at the code (and the ticket where this originated, http://trac.sagemath.org/sage_trac/ticket/10746). IML, PARI, Sage generic code produce right kernels. These come in different formats, so one option for the right_kernel_matrix() function is to do no extra processing of the result by asking for a computed basis. ('padic' uses IML.) sage: A = matrix(ZZ, [[-1, 0, -2, 2, -3], [1, -1, 4, 0, 0], [2, -2, 8, 0, 0], [0, -2, 4, 4, -6]]) sage: A.right_kernel_matrix(algorithm='padic', basis='computed') [ 2 -2 -1 0 0] [-2 -2 0 -1 0] [ 3 3 0 0 -1] sage: A.right_kernel_matrix(algorithm='pari', basis='computed') [-1 -1 0 1 1] [ 1 1 0 2 1] [-2 2 1 0 0] Over fields, the results of a basis matrix of a kernel are a list of vectors as rows, echelonized, whereas the computed basis of the Sage generic code comes naturally (and simply) from the echelon form. sage: A.change_ring(QQ).right_kernel_matrix(algorithm='generic', basis='computed') [-2 2 1 0 0] [ 2 2 0 1 0] [-3 -3 0 0 1] sage: A.change_ring(QQ).right_kernel().basis_matrix() [ 10 -1/40 -1/6] [ 01 1/40 -1/6] [ 0001 2/3] The existing code before the ticket had a _right_kernel_matrix() over the integers, which was called one place (sage/algebras/quatalg/quaternion_algebra.py) and this was the model for the new non-underscore method which replaced it (available for almost any ring). Previously Sage had a preference for left kernels, so a matrix would be transposed *before* the call to a specialized procedure that was designed to compute right kernels. For a right kernel, the matrix would be transposed to compute a left kernel, then transposed again to be correct input for the routine. I think this inefficiency is now gone. I would be in favor of a right kernel matrix having its vectors as columns. It looks like this would save some transposes on the exit from the actual routines doing the computations. In refactoring, I was concentrating on the organization of the code and packaging of the results, so left a lot of things alone. It looks to me now like some of this old code could be made more efficient in terms of packaging the results. However, changing the format of an output of a function like this, especially for square matrices, would probably be unwise. Anyway, short answer is that there looks to be some room for further (minor) improvements. But you'd have to look at the code. Rob -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org