Ask Your Question

Revision history [back]

I am assuming you are working with the Sage notebook.

Description of the Sage notebook

You can use the Sage notebook on a computer you are logged in to, by typing, in a terminal, sage -notebook or sage -n or just sage and then notebook(). You can also use it on some online Sage Notebook server.

In the Sage notebook, each worskheet has at the very top a header with, on the left:

Sage | The Sage Notebook
Version <version_number>

and, on the right, your username and 8 links:

<username> | Toggle | Home | Published | Log | Settings | Help | Report a Problem | Sign out

A second header row has, on the left, this text:

<worksheet_title>
last edited <date_of_last_edit by <username_of_last_edit>

and, on the right, these three buttons:

[ Save ] [ Save & quit ] [ Discard & quit ]

A third header row has, on the left, four menus and a checkbox:

[ File... ]   [ Action... ]   [ Data... ]   [ sage ]     [ ] Typeset

and, on the right, 7 buttons:

Print | Worksheet | Edit | Text | Revisions | Share | Publish

How to evaluate all cells and print

The item Evaluate All in the Action... drop-down menu (second drop-down menu out of the five that are in the third header row) does precisely what you want, ie, evaluate all the cells in your worksheet one after the other!

To print, you can either use the Print button (first of the 7 buttons on the right in the third header row), or the Print item in the File... drop-down menu, or the print capabilities of your browser, or screen captures. Compare the results and decide what you like best.

I am assuming you are working with the Sage notebook.

Description of the Sage notebook

You can use the Sage notebook on a computer you are logged in to, by typing, in a terminal, sage -notebook or sage -n or just sage and then notebook(). You can also use it on some online Sage Notebook server.

In the Sage notebook, each worskheet has at the very top a header with, on the left:

Sage | The Sage Notebook
Version <version_number>

and, on the right, your username and 8 links:

<username> | Toggle | Home | Published | Log | Settings | Help | Report a Problem | Sign out

A second header row has, on the left, this text:

<worksheet_title>
last edited <date_of_last_edit by <username_of_last_edit>

and, on the right, these three buttons:

[ Save ] [ Save & quit ] [ Discard & quit ]

A third header row has, on the left, four menus and a checkbox:

[ File... ]   [ Action... ]   [ Data... ]   [ sage ]     [ ] Typeset

and, on the right, 7 buttons:

Print | Worksheet | Edit | Text | Revisions | Share | Publish

How to evaluate all cells and print

The item Evaluate All in the Action... drop-down menu (second drop-down menu out of the five that are in the third header row) does precisely what you want, ie, evaluate all the cells in your worksheet one after the other!

To print, you can either use the Print button (first of the 7 buttons on the right in the third header row), or the Print item in the File... drop-down menu, or the print capabilities of your browser, or screen captures. Compare the results and decide what you like best.

Could I instead work in a TeX document?

Yes! Use the SageTeX package for LaTeX. See the tutorial in the Sage documentation.

Ideal for producing documents with a mix of text, formulas, Sage code, and Sage output.