Core Python Recipes
I use the term core python to mean the standard parts of the python ecosystem: the base python language and the "standard library" of modules that is typically installed along with it. For purposes of this course I'm also including the tool stack we'll use to work with python: GitHub and git, JupyterLab and its pieces, and a little of the Unix command-line.
I've divided that up in to the following chunks:
-
Workflow Recipes: Basic procedures for getting stuff done in this course (and hopefully beyond it).
-
Calculation Recipes: Procedures, tools, and tricks to help you do numeric calculations such as you might encounter in physics homework from other courses (or, perhaps some day, in a physics-ish job).
-
Function Recipes: Defining functions takes python from "oversized calculator" to "full-fledged programming language." These recipes address various aspects of writing your own functions in the service of doing physics.
-
Iteration Recipes: Humans hate doing the same thing over and over with only tiny variations. Computers excel at it. These recipes illustrate various ways of taking advantage of that.
-
Collection Recipes: Recipes for using python's various collection types: tuples, lists, sets, and dictionaries ("dicts").