Search
PHYS 5041/6041 Introduction

PHYS 5041/6041: Computational Physics

Henry Schreiner

Objectives:

  • Go over the syllabus
  • Log in to OSC and/or install Anaconda locally
  • Introduction to Jupyter Notebooks (new notebook)

Syllabus

Available at https://homepages.uc.edu/~schreihf/uchenry/post/computational-physics/

Computing

We will be using Python 3.6 and common scientific packages. Two install choices:

OSC OnDemand

  • Go to https://ondemand.osc.edu
  • Log in (instructions posted on Blackboard)
  • At the top, click Interactive Apps -> Jupyter Notebook
  • The default (minimal) settings are perfect
    • Our project is PES0765
  • Click Launch

The browser based notebook should start in 1-3 minutes.

Local install

  1. Download Anaconda from https://anaconda.com
  2. Install the latest Python 3 version (3.6 at time of writing, 3.7 is still being worked on in Anaconda)
    • Either say 'yes' to the question about adding to your path, or add it manually
  3. Launch a Jupyter notebook from the Anaconda Navigator

Note

Why not use official Python from python.org or my package manager?

The official builds are great, but you'll have to install all the packages yourself. Also, if it is a Python that is built into your system, you could break things by changing your packages. For now, using the Anaconda build provides you with everything you need, is safe for your system, and some packages are easier to install. There are special cases outside of this class where you might not want Anaconda Python, so talk to me if you think that might be the case.

Topics for later

Most courses spend a little (too little) time on these topics just to get started using Python. We are going to skip them for now, then return to them later in the course when we can focus our attention properly on them:

  • Using the shell (Bash)
  • Manipulating your path
  • Installing Python packages
  • Using git