MAT 167 Homework Page (Fall 2006)
Homework Assignment #1 Due Monday Oct. 9
- Read Sec. 1.1-1.3
- Do Exercises 1.2.3, 1.2.8, 1.2.9, 1.2.10, 1.3.1
Homework Assignment #2 Due Wednesday Oct. 11
- Read Sec. 2.1-2.4
- Do Exercises 2.1.1(a), 2.2.1(a), 2.2.5, 2.3.1(d), 2.3.3, 2.3.5
Homework Assignment #3 Due Friday Oct. 13
- Read Sec. 2.5, Sec.4.1
- Do Exercises 2.4.3, 2.4.6, 2.5.4, 2.5.6, 4.1.1, 4.1.2
Homework Assignment #4 Due Monday Oct. 16
- Read Sec. 3.9, Sec. 4.2
- Do Exercises 4.1.6, 4.1.8, 4.2.4, 3.9.2, 3.9.5, 3.9.6
Homework Assignment #5 Due Wednesday Oct. 18
- Do Exercises 4.2.1, 4.2.2, 4.2.3, 4.2.6, 4.2.8
Homework Assignment #6 Due Friday Oct. 20
- Read Sec. 4.3
- Do Exercises 4.3.2, 4.3.3, 4.3.6, 4.3.8
Homework Assignment #7 Due Monday Oct. 23
- Read Sec. 4.4
- Do Exercises 4.4.1, 4.4.2, 4.4.3, 4.4.6, 4.4.8
Homework Assignment #8 Due Wednesday Oct. 25
- Read Sec. 4.5 (bounds on the rank of a product and page 218) and
Sec. 4.6
- Do Exercises 4.5.4, 4.6.2, 4.6.3
- Using MATLAB, do the following procedure:
- Download the data file to your directory, name it as hw8.mat, and load it into your MATLAB session by: >> load hw8;
- Check what variables (i.e., arrays) are defined in this data
file by running: >> whos
- Plot the data by: >>
plot(x,y); grid;
- Create the Vandermonde matrix by: >> A=[x.^0
x.^1];
- Compute the least squares line over the given data by: >> sol =
inv(A'*A)*A'*y;
- Overlay the least squares line over the current plot by: >> hold on;
plot(x, sol(1)+sol(2)*x, '--');
- Put title, axis labels by: >>
title('Least squares line fit'); xlabel('x'); ylabel('y');
- Print out this plot and submit the hardcopy of the plot.
Homework Assignment #9 Due Friday Oct. 27
- Read Sec. 4.7, 4.8
- Do Exercises 4.7.2, 4.7.6, 4.7.8, 4.7.11, 4.7.13
Homework Assignment #10 Due Monday Oct. 30
- Read Sec. 4.7, 4.8
- Do Exercises 4.7.14, 4.8.3, 4.8.4
Homework Assignment #11 Due Wednesday Nov. 1
- Do Exercises 4.8.6, 4.8.7, 4.8.8
- Using MATLAB, do the following procedure:
- Download the data file to your directory, name it as hw10.mat, and load it into your MATLAB session as in HW8 (except the filename change).
This is exactly the same dataset as before but now I used older MATLAB data format.
For those who use older versions (older than 7.x) of MATLAB and who had difficulty loading
the file before, please let me know whether you can download this file and
load it to your MATLAB session.
- Repeat the same procedure as in HW8, i.e., draw the original data and
the least squares line.
- Now, compute the least squares parabola
(i.e., the second order polynomial),
and overlay it on the plot so that you can compare it with the least squares
line. Use '.' option in the plot function for this parabola to see the
difference instead of '--' option used for the least squares line.
- Submit the hardcopy of the plot.
Homework Assignment #12 Due Friday Nov. 3
- Read Sec. 5.1
- Do Exercises 5.1.1, 5.1.2, 5.1.5, 5.1.6, 5.1.8
Homework Assignment #13 Due Monday Nov. 6
- Read Sec. 5.2
- Do Exercises 5.2.1, 5.2.2, 5.2.3, 5.2.4, 5.2.5
Homework Assignment #14 Due Wednesday Nov. 8
- Read Sec. 5.3, 5.4
- Do Exercises 5.3.2, 5.4.2, 5.4.6, 5.4.11
Homework Assignment #15 Due Monday Nov. 13
- Read Sec. 5.5
- Do Exercises 5.5.1(a)(b), 5.5.2, 5.5.3, 5.5.4, 5.5.5
Homework Assignment #16 Due Monday Nov. 20
- Do Exercises 5.5.6, 5.5.7, 5.5.11
Homework Assignment #17 Due Wednesday Nov. 22
- Read Sec. 5.6 pages 320-324
- Do Exercises 5.5.9, 5.6.2, 5.6.4, 5.6.5, 5.6.10
Homework Assignment #18 Due Monday Nov. 27
- Read Sec. 5.9
- Do Exercises 5.6.11, 5.9.1, 5.9.3, 5.9.8, 5.9.12
Homework Assignment #19 Due Wednesday Nov. 29
- Read Sec. 5.11
- Do Exercises 5.11.1, 5.11.2, 5.11.3, 5.11.6
Homework Assignment #20 Due Friday Dec. 1
- Read Sec. 5.11 and Lecture Note 1
- Do Exercises 5.11.7, 5.11.9, 5.11.10
Homework Assignment #21 Due Monday Dec. 4
Homework Assignment #22 Due Wednesday Dec. 6
Homework Assignment #23 Due Friday Dec. 8
- Using MATLAB, do the following exercises:
- Load the image called mandrill.mat, via:
>> load
mandrill;
This loads a matrix X containing a face of mandrill, and a map containing
the colormap of the image. If you cannot load this data in your MATLAB, then
download this data from this
link. Then, do the load
command
again. Display this matrix on your screen by:
>>
image(X); colormap(map)
-
Compute the SVD of this mandrill image and plot the distribution
of its singular values on your screen (Note that the MATLAB
svd function returns three matrices U, S, V for a given input matrix. So, the singular values are plotted by:
>>
plot(diag(S));
Then print this figure.
- Let σj, uj, vj be a singular value, the left and
right singular vectors of the mandrill image, respectively.
In other words, they are S(j,j), U(:,j), V(:,j) of the SVD of X
in MATLAB. Let us
define the rank k
approximation
of the image x as
xk
:= σ1
u1 v'1
+ ... + σk uk v'k, where
v'j is
a transpose of vj.
Then, for k=1,6,11,31, compute xk of
the mandrill, and display the results. Fit these four images in one
page by using
subplot function in MATLAB (i.e., use
subplot(2,2,1) to display the first image,
subplot(2,2,2) to display the second image, etc.)
- For k=1,6,11,31, display the residuals, i.e., x-xk,
fit them in one page, and print them.
- Finally, submit those three printouts as HW.
Please email me
if you have any comments or questions!
Go
back
to MAT 167 Home Page