This site is aimed at math and physics majors who may have little programming experience, but who want to learn techniques in computational physics. It contains examples pulled from a variety of fields in math, physics and astronomy. The examples are meant to supplement existing tutorials such as the excellent one put together by Spencer and Ware at BYU. It may be downloaded in pdf form from their website here.
Programming Basics
First Steps
Loops and If Statements
Reading Data Files
Example  Description  Commands 
A11  Read in data from an ASCII file  load(), textread() 
Download all Programing Basics Examples A00.m–A11.m here.
Plotting
2D Plots
Download all 2D Plot Examples plot01.m–plot10.m here.
Plotting
 Super Simple Plot – Simple plot of y=x^2. Examples of marker and line types.
 Playing With Axes – Controling the appearance and scaling of axes. Also log and semilog plots.
 Plotting a Circle
Solving Ordinary Differential Equations (ODEs)

1D FirstOrder ODEs

1D SecondOrder ODEs

2D SecondOrder ODEs
Celestial Mechanics

TwoBody Problem

Circular, Restricted ThreeBody Problem
 Code Download
 PseudoPotential & Lagrange Points
 Simulations & Chaos

NBody Problem