Sage Math Cloud

Please take a look at this totally cool project by the Sage people; actually just create an account here and start playing around with it. If you already have, good for you.

To get your own version of the Stacks project in the cloud is quite easy: (perhaps skip reading the instructions and read below why this could be useful):

  1. login to your sage math cloud account you’ve just created
  2. start a new project, say XXX
  3. enter XXX by clicking on it
  4. create a terminal by clicking the + New button and choosing terminal
  5. click on the terminal file you’ve just created (extension term)
  6. now you have command line access on the Sage cloud (how this isn’t a HUGE security problem I’ve no idea, but we’ll trust the people behind it to have some barriers…)
  7. OK, now clone the stacks repository from github with
    git clone
  8. That’s all there is to it and moreover, now you have all the usual linux tools at your disposal as the Sage people have set it up for you. For example, you enter the new directory using
    cd stacks-project
    and make all the pdfs by running
    make pdfs
    etc, etc. After you have these pdfs you can download them and read them locally, or whatever.

Thanks to William Stein for explaining how to get the terminal window.

What’s the point? The point is that, contrary to what you may think, most people aren’t linux guru’s. Hence they do not know how to deal with large latex files, etc. Have you ever tried to open algebra.tex with a latex editor on a windows or mac? Often the result is a BSOD or at least overheating of components. Thus for most people it is great if we can tell them: click here and here and use this editor to start editing this file. Right now in the situation above you can run vim algebra.tex on the command line or use the online editor. Moreover, here are some additional bonus features of using the Sage cloud (thanks to William for pointing these out in an email):

  1. You can have multiple people work on the same file at once with chat
  2. The online editor in Sage cloud has syntax highlighting with many color schemes. This is useful for those working for long hours typing things. People can also set vim or emacs modes for the editor.
  3. If you click on the camera off to the right in the file viewer, you’ll find that cloud.sagemath takes snapshots about once a minute of the complete state of all your files whenever you’re working. This can be really useful, especially in a collaborative setting.

Anyway, seeing this I’m now more optimistic that in the near future we’ll have some kind of online latex editor for the Stacks project. Just maybe we’ll use the Sage math cloud to do this: it only just started and already you can do lots of things with it.

10 thoughts on “Sage Math Cloud

  1. “Have you ever tried to open algebra.tex with a latex editor on a windows or mac? ” Yes, just did it. No problem at all, and compiled quite quickly (Windows XP on 2005 vintage laptop). In fact, I typically work on single tex files that produce two or three hundred pages pdf files.

      • I use Boxer as a text editor, which can handle files up to 2GB, and I used pdflatex in MiKTeX, which also can handle files larger than anyone is likely to come across. Compiling the file took about 10 sec on my 2005 vintage laptop. Perhaps there are people who don’t know how to handle large files under Windows, but I would find that very surprising (and I don’t consider algebra.tex all that large).

        • OK, thanks! Boxer looks like an industrial strength editor many won’t have installed on their system. And 10 seconds is pretty good for compile time on a 2005 machine. I still think you’ll find many unable to successfully edit and compile a file as big as algebra.tex, but I could be wrong. Maybe what I should have said, because this is something I have actually tried, is that many so-called “latex editors” or IDE’s seem to be unable to handle it. Unfortunately, I can’t remember which ones I’ve tried. Here are some names of this type of application: Kile, Texmaker, Texworks, Texshop, TexnicCenter, WinEdt, LyX, etc. I just found an old email where somebody reports Texmaker being unable to handle algebra.tex. Anybody try another one?

  2. Boxer is not specifically designed for TeX editing, but it does have syntax highlighting in TeX. I also opened algebra.tex in TeXworks (an integrated system that comes with MiKTeX) and was able to edit and compile the file with no problem. I simply don’t think there is any problem with files of this size (or even much larger) in Windows. Incidentally, it’s been several years since I’ve had a BSOD with Windows XP — it’s very stable on the laptops I use.

    • Yeah, no, the BSOD thing was a joke! I’m happy to hear everything works fine for you! Just installed Texworks on my linux laptop and it works fine too… untill I turn on syntax highlighting when it hangs for about 2 minutes (so far). Did you try that?

      • Syntax highlighting was automatically turned on in my TeXworks and caused no problems. But I’ve never really used the program since I prefer
        Scientific WorkPlace/Boxer/SumatraPDF/MiKTeX.

        I should mention that I only downloaded algebra.tex and preamble.tex, not the 80 or so .aux files needed to get the pull in the external references. That might slow things down, and perhaps cause problems.

        • Tried it with just algebra.tex and no aux files and still no dice. I even tried editing syntax-patterns.txt but it only proves everything except for the most trivial highlighting is an issue. Victory for the windows version in this case! Thanks again, Johan.

  3. Pingback: The Sagemath Cloud | Stacks Project Blog

  4. Pingback: Sagemath Cloud | High School Math and Chess

Comments are closed.