Sharedlectures / 2018-01-08 / 2018-01-08.ipynbOpen in CoCalc

Math 157: Intro to Mathematical Software

UC San Diego, winter 2018

January 8, 2018: Introduction to CoCalc

Welcome to Math 157! This course is an introduction to the use of mathematical software. Although mathematics is still largely taught as a pencil-and-paper (and chalk) subject, this approach ignores the fundamental role played by computing technology in the subject. This course will introduce students to a broad but coherent collection of open-source software tools, and to diverse examples of their use in mathematical study and research.

This course will operate quite unlike any other math class you have taken. The goal of today’s lecture is to both explain in words, and demonstrate visually, how the course will operate. I’ll start with the explaining part, by going over the course syllabus.

What you need

CoCalc is a Web platform for using mathematical software in the cloud rather than installed locally. This means that you can access it, to the full extent required for this course, from any device with Internet access and a web browser. Other than the syllabus on my web site, and grades posted on TritonEd, all materials for this course will be distributed and collected using CoCalc.

Part of the course grade is based on using CoCalc during lectures (starting on Wednesday), so you will need to bring a suitable device to class. On one hand, it is pretty hard to use CoCalc on a phone, so I would advise against trying. On the other hand, you can see how big the chairs and desks are. I recommend using either a small laptop or a large (at least 8 inches diagonally) tablet with a physical keyboard. (You are of course free to use a different device outside of class!)

You will need to create an account to use CoCalc. This is easy (and free): go to and follow the instructions on the main page. If you use your official UCSD email address to create the account (recommended, and what happened if you answered the email invitation I issued from CoCalc), you will automatically be given access to the course materials. If you use another address (which might happen implicitly if you use a social media account to sign in), please email me to let me know what email address is associated to your account, so I can manually link you to the course.

If you are having trouble getting onto CoCalc, please take advantage of this week’s sections and office hours to get help.

Navigating CoCalc: projects

Once you have logged into CoCalc, you will probably start in the Projects view. You can always get to that screen by clicking on the CoCalc logo or the word “Projects” at the top left: CoCalc.

You should start with two projects: “Math 157 – Winter 2018 (your name)” (your individual project) and “Shared Project – Math 157” (the shared project). If you cannot see one or both of these, contact me or your TA at once. (For example, this might happen if you didn’t use your UCSD email address to create your account.)

It is possible to create additional projects, but at no point will this be necessary. (Also, such projects will not be “upgraded” in the same way as the individual and shared projects are.)

Each project has its own file directory, which you will see if you click on the project in the Projects view. From within a project, you can always get to the Files view by cilcking the folder icon below the CoCalc logo at top left: folder icon.

This is like a folder on your computer; in particular, it can have its own subfolders. Your individual project is yours alone; no one has access to it besides you, me, and the TAs. By contrast, the shared project is accessible to everyone in the course.

Chat rooms

In the shared project, you will find a file called “master-chat.sage-chat”. Open this to get to the master chat room for this course.

The master chat room will be used in various ways. I will occasionally make announcements here (e.g., updates about the homework). I and the TAs will conduct some “virtual office hours” here as well. At other times, feel free to ask (and answer) questions about the course.

It is possible to create additional chat rooms in the shared project. For instance, if you are collaborating in a small group on a homework assignment, it is probably better to use a separate chat room to avoid cluttering the master chat.

Workflow: lectures

When you arrive at each lecture, please perform the following steps.

  • Open your device, sign into CoCalc, and open your individual project.
  • From the Files view, navigate into the folders “lectures”, then the subfolder “2018-xx-xx” with that day’s date. For instance, if you were doing this today, you would open the subfolder “2018-01-08”.
  • Open the file “2018-xx-xx.ipynb” with that day’s date. For instance, if you were doing this today, you would find a copy of this file! (You should try this later to see that this works.)

Each lecture will consist of a file like this, called a Jupyter notebook, and possibly some auxiliary files. Next time, we’ll discuss in detail how Jupyter notebooks work; this will in particular explain how class participation is recorded for your course grade.

Workflow: homework (and the final project)

In order to work on a homework assignment, you will (in your individual project) navigate into the folder “assignments”, then the subfolder “2018-xx-xx” with the due date of the assignment. There you will again find a file “2018-xx-xx.ipynb” with the due date of the assignment.

The format of assignments will vary over the term, but in general you will complete an assignment by filling in the Jupyter notebook as instructed; this will be similar to class participation. Any exceptional instructions will be included in the notebook itself.

One potentially confusing feature of CoCalc is that there is no way to submit your assignment for grading. What actually happens is, at (or shortly after) the due time, I will collect your assignment by copying the whole 2018-xx-xx subfolder out of your project. The TAs will then evaluate your assignment, possibly adding some feedback in a separate file, and eventually return it to you by copying the subfolder back into your project.

The final project will be handled the same way. The only difference is how it figures into your course grade.

For more on CoCalc…

This is a new line that I added to the notebook.