CSIS 200: Software Tools for Physicists. An introductory programming course for Physics and other Science majors.
Learn to program in any language (slides)
The required textbook for this class is Learn Python the Hard Way. There is a free, web-based version of the book, but you may benefit from having a hard copy for reference when you are working on homework and the projects.
Below is a list of topics that we will be covering in class. It is likely that we will not go through this list in chronological order! Neither should you assume that each topic will take a week to cover. Some topics may take a lecture...or 1/2 a lecture. Some weeks we may go through 3 topics...or spend 2 weeks on one of these topics.
The pace of the course will be dictated by how well the majority of the class is developing competency with the material. However, you should always feel free to plow ahead on your own! There are a ton of great resources out there and you can always learn a lot from self-guided study.
To download any of these starter lecture skeletons, you can do this:
- Click on the link.
- Click on the Raw button in the upper right.
- Ctrl-s to save the file to your laptop.
- Working with Python (the interpreter, command line, IDLE). Assignment (int, float, str). Printing.
- Editors (slides)
- Assignment (slides)
- Lecture notes.
- LPTHW chapters. Exercise 4,Exercise 5,Exercise 6,Exercise 7
- IPython/Jupyter notebooks
- Review Notebook, printing, general coding, etc.
- Functions
- Lists
- Lists (slides)
- Lecture notes
- LPTHW chapters. Exercise 32, Exercise 33,Exercise 34
- In-class lab
- Loops.
- Loops (slides)
- Lecture notes.
- LPTHW chapters Exercise 32,Exercise 33
- In-class lab
- Conditionals.
- Conditionals (slides)
- Lecture notes.
- LPTHW chapters Exercise 29,Exercise 30,Exercise 31
- In-class lab
-
Importing modules
- Modules (slides)
- Lecture notes.
- LPTHW chapters Exercise 40
-
Numpy and scipy
-
Plotting (matplotlib)
-
Reading from and writing to files
- Lecture notes.
- LPTHW chapters Exercise 15,Exercise 16,Exercise 17
- In-class lab
- Data files. You will need these files to run the Lecture and In-class lab notebooks. When you download the files, make sure that you copy them to the same directory that the notebooks are in.
-
More exercises
Given time...
- Timing and optimization
- Lecture notes
- Dictionaries
- LaTeX (slides)
- The Beauty of LaTeX
- Installation and checking installation
- Basics of LaTeX
- Linux (slides)
- Reading from Simple Wikipedia
- Operating system
- Unix
- Linux
- Kernel
- Linux kernel
- CPU (just read the introduction)
- Computer memory
- Hard disk
- Learn Python the Hard Way chapter on Linux/Unix Command Line Crash Course
- Exercise on navigation
- Assignment instructions for navigation, edit, and Python execution
- Exercise on command-line options to Python and shell scripts
- Version control/git/Github (slides)
- Version control and Git
- Lecture notes on Classroom site.
- Software carpetry on version control
- Git/Github
- Make sure you install git and sign up for an account on Github.
- Lecture on first exercise with Git/Github
- Collaboration exercise
- C
- Processing
- R
- MATLAB/Octave
- Presentation of data
- Lecture notes