Physics on the Computer (PHYS 202)

My information

  • Brian E. Granger
  • ellisonbg on Gmail, Twitter and GitHub
  • 805-903-2580
  • Office Hours (Tuesday 4-5, Thursday 4-5, Friday 4-5)

Course information

  • Spring 2015
  • Tuesday+Thursday 12-2 (PHYS202-02) and 2-4 (PHYS202-03)
  • Baker 180-272

Catalog Description

Introduction to using computers for solving problems in physics: differential equations, matrix manipulations, simulations and numerical techniques, nonlinear dynamics.

Course Objectives

Upon completion of the course you should be able to:

  • Use basic coding concepts such as loops, control statements, variable types, arrays, array operations, and boolean logic. (LO1)

  • Write, run and debug programs in a high level language. (LO2)

  • Carry out basic operations (e.g. cd, ls, dir, mkdir, ssh) at the command line. (LO3)

  • Maintain a version controlled repository of your files and programs. (LO4)

  • Create publication/presentation quality graphics, equations. (LO5)

  • Visualize symbolic analytic expressions - plot functions and evaluate their behavior for varying parameters. (LO6)

  • Use numerical algorithms (e.g. ODE solvers, FFT, Monte Carlo) and be able to identify their limitations. (LO7)

  • Code numerical algorithms from scratch and compare with existing implementations. (LO8)

  • Read from and write to local or remote files. (LO9)

  • Analyze data using curve fitting and optimization. (LO10)

  • Create appropriate visualizations of data, e.g. multidimensional plots, animations, etc. (LO11)

Resources

The following are core, required resources for the course:

  • Jupyter/IPython: (http://jupyter.orghttp://ipython.org) An interactive computing environment for Python and other languages.
  • Git and github: (http://github.com) A version control system and public web-based repository for writing code collaboratively.
  • Codecademy: (http://www.codecademy.com) A free online series of interactive programming courses.
  • Project Euler: (http://projecteuler.net) A series of challenging mathematical/computer programming problems that will help you practice your new computing skills.
  • Gitter: (http://gitter.com) An online chat system that is integrated with GitHub.

The following are optional, but highly useful, resources you might find useful:

Grading

Your final grade in the course will be based on the following:

Assignments: 40%
Midterm Exam: 20%
Project: 40%

This class is about building skills. The only way to build your skills is to practice them. Therefore, in order to receive a passing grade (C- or better) in this class you must pass/complete a minimum of 50% of the material in each grading category. How well you do in each of the categories will be used to determine your final letter grade. Do not ignore any of the exercises or assignments.

Class time and assignments

Assignments will be distributed and turned in each week using GitHub. The distribution of problems will be gradual throughout the week, but they will all be due on a single day. More details will follow. You will work on the problems both in and out of class, so class attendance is mandatory. You must stay until the end of class unless you get specific, explicit permission to leave early.

We will be spending our class time learning to code and solve physics problems numerically by doing hands-on activities at the computer. Sometimes you will work alone. Other times you will participate in pair programming exercises where you are the driver and your partner is the navigator and vice versa. Studies show that this is a very effective way to learn programming.

As with any skill, the only way to become proficient is to practice. A LOT. Think about your experiences learning a musical instrument or playing a sport. A little bit of practice every day is crucial. You will probably be spending 8 to 12 hours per week outside of class writing and debugging code.

If you have trouble with the homework, come to my office hours or seek help from your peers in person or or Gitter. Don't wait until you are in trouble to take action.

Midterm exam

There will be one midterm exam on Wednesday, April 29 during the first hour of class. The exam will cover the material from the first 4 weeks of class.

Project

During week 6, you will be assigned an open-ended programming project provided by me. You will have until 11:59pm Friday of the tenth week of instruction to complete your project and submit the code to your PHYS 202 GitHub repository. We will spend some class time working on the projects but most of the work will be completed outside of class. Part of the project will be collaborative with other students assigned the same project, but you will be responsible for completing the coding, documentation and analysis assigned to you. Detailed instructions for completing the projects will be included in the project descriptions.

During the final exam period you will present a 5-10 minute demonstration of your project and its results to the rest of the class. The demonstration will be graded by me and your peers using an oral presentation rubric. These assessments will be part of your grade for the project.

  • Section 02: Wed, June 10, 10:10-13:00

  • Section 03: Monday, June 8, 13:10-16:00

Guidelines for Academic Honesty

The following guidelines are adapted from the Grand Valley State University and George Washington University computer science departments.

You are expected to:

  • Write you ownn code.
  • Understand your solutions.
  • Acknowledge the help of others in writing.
  • Explicitly cite the origin of other people's code that you have used with their permission.
  • Protect yourself from being suspected of misconduct by not allowing others to see your assignment before it is submitted.
  • Contact your instructor for clarification about assignment requirements.

You are encouraged to:

  • Discuss general approaches to a solution.
  • Share knowledge with other students about syntax errors, coding tricks, or other language-specific information that makes programming easier.
  • Provide and receive help with simple execution errors.
  • Provide and receive help with using the computing environment.
  • Engage, with other students, in a general discussion of the nature of an assignment, the requirements for an assignment, or general implementation strategies.
  • Engage, with other students, in discussion of course concepts or programming strategies in preparation for an assignment or examination.

You are guilty of academic misconduct if you:

  • Give your source code to anyone in hardcopy or electronic form.
  • Receive another student's solution in hardcopy or electronic form.
  • Submit as your own work the files, solutions, or documents prepared by others.
  • Use source code from the internet without proper attribution.
  • Submit assignments as your own without attribution if they were created in collaboration with someone.
  • Make modifications to someone else's solution in an effort to disguise misconduct.
  • Use unauthorized materials during an examination, or communicate during an examination in an unauthorized way with another person.
  • Knowingly permit another person to turn in your work as his or her own work.

You will be contacted by me if I suspect academic misconduct. Appropriate actions might include but are not limited to a failing grade on the assignment, a grade reduction in the course, or a failing grade in the course. See the Office of Student Rights and Responsibilities website for further information.

To help you remember to follow these guidelines, we will create a pledge file (called PLEDGE.md) in the main directory of your PHYS 202 GitHub repository. It is your signed contract stating that you have read and understand the rules regarding academic honesty and agree to abide by them.