Computational Physics Laboratory PHZ4151C/PHZ5156C
Spring 2009
Class Meetings: HCB 0219, Tuesday and Thursday from 2:00 to 3:15 PM
Office Hours: Wednesday 4:00 - 5:00 PM or upon appointment
Course Text: David Yevick, A First Course in Computational Physics and Object-Oriented Programming with C++
Home
Course Materials and Schedule
Course Projects
Solutions to Problems
Resources/Tutorials
Debugging Programs with DDD
mysum.cc
A program which sums the powers of positive integers.
Example:
> ./mysum 2 3
Output:
1 8
The sum of [1...2] each raised to the power 3 is 9.
Source Code
sumppi.cc
Function definition, used in previous program
Source Code