next up previous
Next: The test function Up: tutorial3 Previous: tutorial3

Overview


We are going to write a MATLAB script (i.e. a file containing MATLAB commands) to solve problems of the form $f(x)=0$ using the fixed-point iteration method, i.e. we need to find the value of $x$ for which $f(x)=0$ (the root). This script will be called iteration.m and we will construct it step by step.

\bgroup\color{red}\framebox{\em MAKE A NEW FILE}\egroup \bgroup\color{black}$\phantom{0}$\egroupThe first steps are to open a new file called iteration.m using the Nedit editor and to open a MATLAB window, by typing matlab at the unix prompt in an xterm window.

Whenever new code is to be added to the file iteration.m it will be introduced with the phrase: \bgroup\color{red}\framebox{\em ADD CODE TO FILE}\egroup \bgroup\color{black}$\phantom{0}$\egroup.



Charlie Macaskill 2004-07-26