PHY 410-505 Computational Physics 1 Fall 2012

Contents  | Syllabus  | Tools  | Topic1  | Topic2  | Topic3  | Topic4  | Topic5  | Topic6  | Topic7

This page:  Home

Current Assignment 12 Due 12/9

Note: Due to Thanksgiving Break Assignments 9-12 will be accepted up to one week late without penalty.
But please try to submit on time and avoid end-of-semester deadline pileup!

Final Exam: Wednesday, December 12, 2012, 7:15 pm - 10:15 pm in Knox 04.
Format: 16 questions on Topics 4, 5, 6 and 7, see syllabus.

Midterm Solutions     Quiz Solutions

Do you have the Current Toolkit Version?
cpt.zip updated Wed Dec 5 09:13:11 2012 README

Friday December 7

Lecture Notes

auto.cpp   auto.cpp.txt  

cluster.cpp   cluster.cpp.txt  

Wednesday December 5

Lecture Notes

ising.cpp   ising.cpp.txt  

Monday December 3

Lecture Notes

disks.cpp   disks.cpp.txt  

Friday November 30

Lecture Notes

quad_1d.cpp   quad_1d.cpp.txt  

metropolis.cpp   metropolis.cpp.txt  

Wednesday November 28

Lecture Notes

sawalk.cpp   sawalk.cpp.txt  

reptation.cpp   reptation.cpp.txt  

Monday November 26

Lecture Notes

wavetank.cpp   wavetank.cpp.txt  

random_test.cpp   random_test.cpp.txt  

rwalk.cpp   rwalk.cpp.txt  

Homework Assignment 11

Assignment 11 is due before 11:59 pm on Sunday December 2. Please submit one PDF on UBlearns.

Monday November 19

Lecture Notes

burgers.cpp   burgers.cpp.txt  

solitons.cpp   solitons.cpp.txt  

Homework Assignment 10

Assignment 10 is due before 11:59 pm on Sunday November 25. Please submit one PDF on UBlearns.

Friday November 16

Lecture Notes

advection.cpp   advection.cpp.txt  

Wednesday November 14

Lecture Notes

wavepacket_fft.cpp   wavepacket_fft.cpp.txt  

wavepacket.cpp   wavepacket.cpp.txt  

Monday November 12

Lecture Notes

poisson_mg.cpp   poisson_mg.cpp.txt  

Friday November 9

Lecture Notes

poisson.cpp   poisson.cpp.txt   poisson_fft.cpp   poisson_fft.cpp.txt  

Homework Assignment 9

Assignment 9 is due before 11:59 pm on Sunday November 18. Please submit one PDF on UBlearns.

Wednesday November 7

Lecture Notes

schroedinger.cpp   schroedinger.cpp.txt  

kronig-penney.cpp   kronig-penney.cpp.txt   bloch.cpp   bloch.cpp.txt  

Monday November 5

Lecture Notes

shoot.cpp   shoot.cpp.txt   relax.cpp   relax.cpp.txt   solve.cpp   solve.cpp.txt  

infwell.cpp   infwell.cpp.txt  

Friday November 2

Lecture Notes

planar3body.cpp   planar3body.cpp.txt  

rcp3body.cpp   rcp3body.cpp.txt  

Homework Assignment 8

Assignment 8 is due before 11:59 pm on Sunday November 11. Please submit one PDF on UBlearns.

Wednesday October 31

Lecture Notes

planar3body.cpp   planar3body.cpp.txt  

rcp3body.cpp   rcp3body.cpp.txt  

Monday October 29

Lecture Notes

planar3body.cpp   planar3body.cpp.txt  

rcp3body.cpp   rcp3body.cpp.txt  

Friday October 26

Lecture Notes

kepler.cpp   kepler.cpp.txt  

Homework Assignment 7

Assignment 7 is due before 11:59 pm on Sunday November 4. Please submit one PDF on UBlearns.

Wednesday October 24

Lecture Notes

kepler.cpp   kepler.cpp.txt  

Monday October 22

Lecture Notes

pendulum.cpp   pendulum.cpp.txt  

Homework Assignment 6 Extension

Assignment 6 is due before 11:59 pm on Tuesday October 23. Please submit one PDF on UBlearns.
Due to the cpt.zip file bug, submissions later in the week will be accepted without penalty.

Wednesday October 17

Lecture Notes

na2cl2.cpp   na2cl2.cpp.txt  

Monday October 15

Lecture Notes

nacl.cpp   nacl.cpp.txt  

nacl.hpp   nacl.hpp.txt  

Homework Assignment 6

Assignment 6 is due before 11:59 pm on Tuesday October 23. Please submit one PDF on UBlearns.

Friday October 12

Lecture Notes

minimize.cpp   minimize.cpp.txt  

Wednesday October 10

Lecture Notes

anharmonic.cpp   anharmonic.cpp.txt  

Monday October 8

Lecture Notes

triatomic.cpp   triatomic.cpp.txt  

Homework Assignment 5

Assignment 5 is due before 11:59 pm on Sunday October 14. Please submit one PDF on UBlearns.

Friday October 5

Lecture Notes

triatomic.cpp   triatomic.cpp.txt  

Wednesday October 3

Lecture Notes

wheatstone.cpp   wheatstone.cpp.txt  

linalg.hpp   linalg.hpp.txt  

matrix.hpp   matrix.hpp.txt  

Monday October 1

Lecture Notes

Homework Assignment 4

Assignment 4 is due before 11:59 pm on Sunday October 7. Please submit one PDF on UBlearns.

Friday September 28

Lecture Notes

fft_demo.cpp   fft_demo.cpp.txt  

Monday September 24

Lecture Notes

fft_demo.cpp   fft_demo.cpp.txt  

Friday September 21

Lecture Notes

fft_demo.cpp   fft_demo.cpp.txt  

Homework Assignment 3

Assignment 3 is due before 11:59 pm on Sunday September 30. Please submit one PDF on UBlearns.

Wednesday September 19

Lecture Notes

scattering.cpp   scattering.cpp.txt  

Friday September 14

Lecture Notes

basic.hpp   basic.hpp.txt  

simple_search.cpp   simple_search.cpp.txt  

search_algorithms.cpp   search_algorithms.cpp.txt  

Wednesday September 12

Lecture Notes

quadrature.cpp   quadrature.cpp.txt  

Monday September 10

Lecture Notes

co2.cpp   co2.cpp.txt  

topic1.hpp   topic1.hpp.txt  

Homework Assignment 2

Assignment 2 is due before 11:59 pm on Tuesday September 18. Please submit one PDF on UBlearns.

Friday September 7

Lecture Notes

quake.cpp   quake.cpp.txt  

Windows Software Installation

There were several questions about strange Windows/PowerShell errors, some of which affected me as well. It turns out that most of these are caused by Windows not being able to find an executable.

If you are continuing to experience this type of problem, make sure that your Path Environment Variable includes the current working directory and any executable needed by the C++ code or makefile.

Wednesday September 5

Lecture Notes

quake.cpp   quake.cpp.txt  

Windows Software Installation

If you are continuing to experience problems, these Installation Instructions may be helpful.

Friday August 31

Lecture Notes

supernova.cpp   supernova.cpp.txt  

Unofficial but easy to install TDM-GCC Bundle Installer

Homework Assignment 1

Assignment 1 is due before 11:59 pm on Sunday September 9. Please submit one PDF on UBlearns.

Wednesday August 29

Lecture Notes

hubble.cpp   hubble.cpp.txt   hubble_plot.cpp   hubble_plot.cpp.txt  

Check out Gnuplot Demo Scripts

C++ Reference Material

cppreference.com very handy quick reference to C++ Standard Library functions and objects

Wikipedia C++ has a link to the official ISO C++ Language Specification and other useful links

Bjarne Stroustrup's Lecture Slides and other links on his website.

Monday August 27

Course Syllabus

Lecture Notes

hello.cpp
#include <iostream>
using std::cout;
 
int main()
{
    cout << "Hello, world!\n";
}

hello.cpp   hello.cpp.txt  

hello.f
      print *,'Hello world!'
      end

hello.f   hello.f.txt  

C++ and Fortran compilers and tools

GNU GCC Compiler Collection

Windows Setup

Download from MinGW-w64 website

Macintosh Setup

Download Xcode 4

Download gfortran from http://gcc.gnu.org/wiki/GFortranBinaries#MacOS

Gnuplot for plotting

Gnuplot website

Vim code editor

Vim website

Shells

Windows PowerShell

Bash on Linux and Mac OS X

Bash and PowerShell Quick Reference

LaTeX for homework

TeX Live website

Information

UB Undergraduate Academic Schedule: Fall 2012

UB Graduate Academic Schedule: Fall 2012

PHY 410-505 Fall 2011 Website

PHY 411-506 Spring 2010 Website



© 2012   Richard J. Gonsalves

Department of Physics  |  University at Buffalo