Docsity

Problem Set 4 for Numerical Analysis I | CAAM 453, Assignments of Mathematical Methods for Numerical Analysis and Optimization

Toggle sidebar
bg1
CAAM 453 ·NUMERICAL ANALYSIS I
Problem Set 4
Posted Sunday 7 October 2007. Due Wednesday, 17 October 2007.
1. [25 points] Determine by hand calculation, the singular value decompositions of the matrices
(a) 3 0
0−2(b) 2 0
0 3 (c)
0 2
0 0
0 0
(d) 1 1
0 0 (e) 1 1
1 1
and, for each matrix, write down the optimal (2-norm) rank-1 approximation.
[Trefethen and Bau, problem 4.1]
2. [25 points]
(a) Suppose A∈
C
m×n,m≥n, has full rank. The exact solution to the least squares problem
min
x∈
C
nkAx −bk2
is given by x=A
+b, where the pseudoinverse A
+is defined, for full rank A, by
A
+= (A
∗A)−1A
∗.
Show that the matrix Π=AA
+is an orthogonal projector onto Ran(A).
(b) If A∈
C
m×n,m≥n, has full-rank, develop an expression for A
+in terms of the singular value
decomposition of A.
(c) From (b), deduce a formula for A
+that is suitable when rank(A) = r < n for A∈
C
m×n,m≥n.
Check that AA
+is still an orthogonal projector on Ran(A).
3. [25 points]
We have previously analyzed the sensitivity of the linear system Ax =bsubject to infinitesimal
perturbations δAto A. Specifically, if Ax =band (A+δA)(x+δx) = b, then
kδxk ≤ kA−1kkδAkkxk.(∗)
For this problem, you shall perform similar analysis for the least squares problem
min
xkb−Axk2,
where now A∈
C
m×n,m≥n, and we assume that Ahas full column rank.
Recall that one can determine the optimal xby solving the system
A
∗Ax =A
∗b,(∗∗)
i.e., x=A
+b, where A
+= (A
∗A)−1A
∗.
pf3
pf4
pf5

Partial preview of the text

Download Problem Set 4 for Numerical Analysis I | CAAM 453 and more Assignments Mathematical Methods for Numerical Analysis and Optimization in PDF only on Docsity!

CAAM 453 · NUMERICAL ANALYSIS I

Problem Set 4

Posted Sunday 7 October 2007. Due Wednesday, 17 October 2007.

  1. [25 points] Determine by hand calculation, the singular value decompositions of the matrices

(a)

(b)

(c)

 (^) (d)

(e)

and, for each matrix, write down the optimal (2-norm) rank-1 approximation. [Trefethen and Bau, problem 4.1]

  1. [25 points]

(a) Suppose A ∈ Cm×n, m ≥ n, has full rank. The exact solution to the least squares problem

min x∈Cn^ ‖Ax − b‖ 2

is given by x = A+b, where the pseudoinverse A+^ is defined, for full rank A, by

A+^ = (A∗A)−^1 A∗.

Show that the matrix Π = AA+^ is an orthogonal projector onto Ran(A). (b) If A ∈ Cm×n, m ≥ n, has full-rank, develop an expression for A+^ in terms of the singular value decomposition of A. (c) From (b), deduce a formula for A+^ that is suitable when rank(A) = r < n for A ∈ Cm×n, m ≥ n. Check that AA+^ is still an orthogonal projector on Ran(A).

  1. [25 points] We have previously analyzed the sensitivity of the linear system Ax = b subject to infinitesimal perturbations δA to A. Specifically, if Ax = b and (A + δA)(x + δx) = b, then

‖δx‖ ≤ ‖A−^1 ‖‖δA‖‖x‖. (∗)

For this problem, you shall perform similar analysis for the least squares problem

min x ‖b − Ax‖ 2 ,

where now A ∈ Cm×n, m ≥ n, and we assume that A has full column rank. Recall that one can determine the optimal x by solving the system

A∗Ax = A∗b, (∗∗)

i.e., x = A+b, where A+^ = (A∗A)−^1 A∗.

(a) Write down the analogue of the linear system (∗∗) for the perturbed least squares problem

min x+δx ‖b − (A + δA)(x + δx)‖ 2.

(b) Manipulate your answer from part (a), using (∗∗) and neglecting second order terms (i.e., products of involving two terms like δA, (δA)∗, or δx), to show that

δx = (A∗A)−^1 (δA)∗^ (b − Ax) − A+^ δAx.

(c) Characterize ‖(A∗A)−^1 ‖ 2 in terms of the singular values of A.

(d) Assuming that Ax 6 = b, i.e., the least squares problem has a nonzero residual, how does the sensitivity of this problem compare to the sensitivity of the standard linear system Ax = b for square, invertible A described by (∗)?

  1. [25 points] Recall the example of image compression using the singular value decomposition that we saw in class. Now it is your turn to compress an image, this time a simple bitmap.

(a) Write a MATLAB routine to construct the 15 × 40 matrix A that is zero everywhere except for ones in the positions marked in the figure below. The upper-left point of the ‘H’ is in the (2,2) entry, and the bottom-right point of the ‘O’ is in the (13,39) entry.

(b) What are the singular values of A? (Use MATLAB’s svd and format long to print 14 digits after the decimal point.) By counting the number of independent rows and columns of A, determine the exact rank of A. Does this agree with your output from svd?

(c) For each k from 1 to rank(A), compute the rank-k matrix B that best approximates A in the 2-norm. Visualize this matrix using the commands: pcolor(B) set(gca,’YDir’,’reverse’) axis equal, axis([.5 40.5 .5 15.5]) colormap(flipud(gray))

[Adapted from Trefethen and Bau, problem 9.3]

S4. Suppose that A ∈ Rm×n^ with m ≥ n.

(a) Suppose r < n, and let Z be any subset of r distinct integers from 1,... , m. Prove that there always exists some nonzero z ∈ Rn^ such that q := Az is zero in each entry in Z, i.e., qj = 0 for all j ∈ Z.

The rest of this problem walks through a proof (adapted from Powell’s Approximation Theory and Methods) of the following remarkable fact: there exists some vector w ∈ Rn^ for which

‖b − Aw‖ 1 = min x∈Rn^ ‖b − Ax‖ 1

and the residual b − Aw has at least n zero entries, i.e., an optimal 1-norm approximation exactly satisfies at least n of the equations in Ax ≈ b. Suppose that ‖b − Aw‖ 1 = minx∈Rn^ ‖b − Ax‖ 1 , and set y := Aw. Let Z denote the subset of the indices 1,... , m that correspond to zero entries of the vector b − Aw. We wish to show that Z must contain at least n distinct indices. If Z contains r < n distinct entries, then, from part (a), we can construct some vector q = Az that is zero in every entry in Z, i.e., qj = 0 for all j ∈ Z. Define the function γ(θ) := ‖b − A(w + θz)‖ 1 =

∑^ n

j=

|bj − (yj + θqj )|.

(b) Explain why γ is a continuous and piecewise linear function of θ, why γ must have a minimum at θ = 0, and why γ(θ) → ∞ as |θ| → ∞. (c) Explain why γ is constant in a neighborhood about θ = 0. (Hint: use the zero structure in q.) (d) Since γ(θ) → ∞ as |θ| → ∞, γ(θ) cannot be constant for all θ. Explain why, as θ increases from θ = 0, the value of γ(θ) must remain constant until θ reaches some distinguished value θ̂, where bj − (yj + ̂θqj ) = 0 for some value of j ∈ { 1 ,... , m} for which qj 6 = 0, i.e., j 6 ∈ Z. (e) Explain why this implies that w + θ̂z must be as good an approximation as w itself was, but that b − A(w + ̂θ) has (at least) r + 1 zeros. Repeatedly applying this argument, we see that there must exist some best approximation, say ŵ for which b − A ŵ has at least n zero entries.

S5. In a celebrated 2003 article in the Proceedings of the National Academy of Sciences, Lawrence Sirovich analyzed US Supreme Court voting patterns using the singular value decomposition. Thanks to your skills with the SVD, and data kindly supplied by Prof. Keith Poole at the University of Houston, you can do the same analysis for yourself. The data is found in supreme_court.mat, available from the course web site. With this file in your working directory, the command load supreme_court will create an 493-by-9 matrix A. Each row of this matrix corresponds to a decision made by the between the period that Justice Stephen Breyer joined the court in 1994, and approximately 2002. (The period from Breyer’s appointment to Renquist’s death in 2005 was one of the longest intervals over which the same nine justices served the court.) Each of the nine columns of A corresponds to one of the justices. The (j, k) entry of A corresponds to the opinion of justice k on case j: agreement with the majority is denoted by 1, dissent by 0. Here is how three famous recent Supreme Court cases would be encoded. The Bush v. Gore decision ended the Florida vote recount after the 2000 presidential election; the Lawrence v. Texas decision overturned the Texas sodomy law in 2003; the 2004 Hamdi v. Rumsfeld decision stated that Yaser Hamdi could challenge his ‘enemy combatant’ status in court; the Kelo v. New London decision, handed down in summer 2005, allows municipalities to seize the land of private citizens for the municipality’s economic benefit. These results would contribute the following rows:

Rehnquist Stevens O’Connor Scalia Kennedy Souter Thomas Ginsberg Breyer

1 0 1 1 1 0 1 0 0 0 1 1 0 1 1 0 1 1 1 1 1 1 1 1 0 1 1 0 1 0 0 1 1 0 1 1

Bush v. Gore Lawrence v. Texas Hamdi v. Rumsfeld Kelo v. New London

(a) Compute the singular values of A.

(b) From your answer to part (a), explain why A might be well approximated by a rank-2 matrix. Report the value of ‖A − X 2 ‖ 2 , where X 2 is that optimal rank-2 approximation to A.

(c) The leading right singular vectors v 1 and v 2 indicate properties of the most common rows of A (though the entries will be positive and negative entries and the vectors will be scaled to have norm one). What are the first two right singular vectors, v 1 and v 2? What voting patterns do these two vectors correspond to? That is, for each vector, list the justices most likely to side with the majority, and those that dissent. From v 2 , can you deduce the two most frequent ‘swing votes’ — that is, those least tied to the other members of the v 2 majority? [Here is an example of how you would interpret the last singular vector,

v 9 ≈ (0. 02 , − 0. 02 , − 0. 03 , − 0. 70 , − 0. 04 , 0. 02 , 0. 70 , 0. 10 , − 0 .03)T^.

There are two large entries, − 0 .70 corresponding to Scalia, and 0.70 corresponding to Thomas. As the signs of these entries are opposite, we would interpret this vector as representing decisions in which Scalia and Thomas disagreed. (Such cases are quite rare, which explains why this is the least significant singular vector!) The other components, be they positive or negative, are small, so we would regard those justices as ‘swing voters’.]

N.B. For those unfamiliar with the US Supreme Court: the Renquist court was said to consist of a conservative wing (Rehnquist, Scalia, Thomas), a liberal wing (Stevens, Souter, Ginsberg, Breyer), and two swing voters (O’Connor and Kennedy) who usually aligned with the conservatives but broke from them on key votes, such as Lawrence v. Texas above. The last part of question (c) is essentially asking you to assess how well the singular values confirm this conventional wisdom.