Notes

The Web pages that will be posted here are not a full or complete set of lecture notes. If you miss a lecture, be sure to check with other students in the class for what went on. The definitive set of material for the course is that which is presented or referred to in the lectures.
  1. Some general software tools of interest and use:

    Accessing remote machines is dangerous if you send passwords in the clear. Use ssh to set up a more secure way of transfering files, and especially for opening windows from a remote machine on a local console. The CS department's systems staff has more up-to-date notes showing how to use OpenSSH, which is now a campus standard. They also have other platform notes about using SSH from a web browser or Windows. Using ssh is not a class requirement - it's just something to avoid being hacked.

  2. Basic Matlab

    1. Intro to Matlab
    2. Matlab Help
    3. Getting Data into Matlab
    4. Matlab Array Notation
    5. General Matlab Notes
    6. More Matlab Plotting
    7. Matlab functions and script files

  3. Relational operators AKA "relops". The files are m-files, so you can download and run them.

    1. Booleans (AKA logical variables)
    2. Relational operators
    3. Test for equality in floating point arithmetic, and why you shouldn't do it.
    4. Applying relational operators in a signal processing context. This shows how you can use an array of Boolean (i.e., 1/0 or true/false) variables to modify a vector, suppress graphing of points, etc.

  4. Linear least squares, motivated in part by a simple example of six observations about the heights of three hills. As well as the usual refinements and ideas (using a "residual vector" as a measure of error, formatting an m-file to be easier to read and debug, ...), this sequence of files shows how and why to convert a simple single-purpose Matlab script into a more general purpose Matlab function.

    The files test_hillsX.m correspond to the similarly numbered files experiment_least_squaresX.m, X = 1, 2, 3. See the internal comments in each m-file for more info.

    1. info , brief information about the m-files used in class.
    2. hills1.m , the first stab.
    3. hills2.m , a minor formatting modification.
    4. experiment_least_squares1.m , the first attempt to separate out the functionality of least squares from the script hills2.m.
    5. test_hills0.m , a test driver for experiment_least_squares1.m that has a small but illuminating bug in it.
    6. test_hills1.m , a corrected version of the test driver for experiment_least_squares1.m.
    7. experiment_least_squares2.m , more refinements and shuffling functionality between the test driver script and the least squares function.
    8. test_hills2.m
    9. experiment_least_squares3.m , final version.
    10. test_hills3.m

    leastsquares.zip bundles together all of the above least squares files.

  5. More tweaks and types of plotting and processing. The information was discussed in class, and most of the important points are in comments in the m-files, or the README files for each directory. Notice that the files with a .mat suffix are binary, so they should just be downloaded instead of viewed with a browser (unless you are using Matlab's browser).
    1. moreplotting.zip, a zip file with all of the files in it. For anyone using an older version of Matlab, these files all have the Windows line-ending convention embedded.
    2. moreplotting.tar, a tar file with all of the files in it.
    3. README . Well, duh. This has a description of the files in its directory.
    4. gatlinberg.m , showing colormaps and basic "handle graphics".
    5. otherplots.m , examples of using other plotting commands.
    6. findprimes.m , a script that computes the factors of all integers 1 to n, and then displays info about them. It in turn creates two output files:
    7. factor_info.mat , a binary file with all of the working data, and
    8. factors , a plain text (ASCII) file with the info formatted. Creating it is an example of how to format when the number of numbers to be printed is not known in advance.
    9. eigenvalues/README , mutatis mutandi for the README in the superdirectory.
    10. eigenvalues/evdriver.m , a simple driver for the main function eigenvalue_plot(). Another near-identical driver is
    11. eigenvalues/compare.m.
    12. eigenvalues/eigenvalue_plot.m has the full meghillah.
    13. eigenvalues/A_eigenvalues.mat and
    14. eigenvalues/B_eigenvalues.mat are data files needed by the drivers evdriver.m and compare.m.


Changes to this page:
  1. Initialized, 12 Jan 2009
  2. Added relational operators, 16 Feb 2009
  3. Minor formatting and corrections in list of relational operator m-files, 16 Feb 2009
  4. Added least squares notes and files, 22 Feb 2009
  5. More formatting for readability, including typo killing, 24 Feb 2009
  6. Added notes and links to other plotting stuff, 09 Mar 2009.