5903 Intro Scientific Prog:
Conjugate Gradients: Specification
- The program should read in a matrix (A) and a RHS vector (b) from a file
- Use the redirect from standard-in.
- Use the redirect from standard-out
- The output should be the solution vector (x satisfying A x = b) printed to standard out.
- The code should use the conjugate gradients algorithm.
- The code should be able to be run as "MyProg < in > out". Where:
- in is a file containing MatrixFileName VectorFileName. You
can assume th file names are less than 80 characters long.
Remember no magic numbers!
- out will be a file containing the solution vector in the matrix format
- The matrix and vector storage and file formats should be as defined in class.
- The i/o functions should be in one file.
- The conjugate gradient algorithm functions should be in another.
- You need to use either implicit rules or automatic variables in your makefile.
- Main should be brief and well documented.
- We will be exchanging this code.
- As always ask in class if you do not understand what the specifications say.
- You do not need (but it is a good idea) to check that the matrix and vector conform.
- You can either write your own linear algebra or use a blas.