Linear Algebra Quiz: Qr Factorization
19 questions · exam conditions
0:00
Qr FactorizationQuestion 1 of 19

Let AA be an invertible n×nn \times n matrix with QR factorization A=QRA=QR, where QQ is an orthogonal matrix and RR is an upper triangular matrix with positive diagonal entries. Which expression correctly gives the determinant of AA?

det(A)=det(R)\det(A) = \det(R)
det(A)=det(Q)\det(A) = \det(Q)
det(A)=±det(R)\det(A) = \pm \det(R)
det(A)=det(Q)+det(R)\det(A) = \det(Q) + \det(R)
← Back to quizzes

Linear Algebra Quiz

Linear Algebra Quiz: Qr Factorization

Practice Qr Factorization in Linear Algebra with focused quiz questions that help you check what you know, review explanations, and build confidence with test-style prompts.

What this quiz covers

This quiz focuses on Qr Factorization, giving you a quick way to practice the rules, question types, and explanations that matter most for Linear Algebra.

How to use this quiz

Try each quiz question before looking at the correct answer. Use the explanations to review missed ideas, then come back to similar questions until the pattern feels familiar.

All questions

Question 1

Let AA be an invertible n×nn \times n matrix with QR factorization A=QRA=QR, where QQ is an orthogonal matrix and RR is an upper triangular matrix with positive diagonal entries. Which expression correctly gives the determinant of AA?

  1. det(A)=det(R)\det(A) = \det(R)
  2. det(A)=det(Q)\det(A) = \det(Q)
  3. det(A)=±det(R)\det(A) = \pm \det(R) (correct answer)
  4. det(A)=det(Q)+det(R)\det(A) = \det(Q) + \det(R)
Explanation: Using the property that the determinant of a product of matrices is the product of their determinants, we have det(A)=det(QR)=det(Q)det(R)\det(A) = \det(QR) = \det(Q)\det(R). Since QQ is an orthogonal matrix, its columns are orthonormal. This means QTQ=IQ^TQ = I. Taking the determinant gives det(QT)det(Q)=det(I)\det(Q^T)\det(Q) = \det(I), which is (det(Q))2=1(\det(Q))^2 = 1. Therefore, det(Q)\det(Q) must be either 11 or 1-1. Substituting this into the equation for det(A)\det(A) gives det(A)=(±1)det(R)=±det(R)\det(A) = (\pm 1)\det(R) = \pm \det(R).

Question 2

Let A=(11131113)A = \begin{pmatrix} 1 & 1 \\ 1 & 3 \\ 1 & 1 \\ 1 & 3 \end{pmatrix}. In the QR factorization A=QRA=QR, the first column of QQ is q1=[12,12,12,12]T\mathbf{q}_1 = [\frac{1}{2}, \frac{1}{2}, \frac{1}{2}, \frac{1}{2}]^T. What is the value of the entry r12r_{12} in the matrix RR?

  1. 22
  2. 44 (correct answer)
  3. 88
  4. 00
Explanation: The entries of the matrix RR in the QR factorization are given by rij=qiTajr_{ij} = \mathbf{q}_i^T \mathbf{a}_j. To find r12r_{12}, we compute the dot product of the first column of QQ and the second column of AA. Given q1=[12,12,12,12]T\mathbf{q}_1 = [\frac{1}{2}, \frac{1}{2}, \frac{1}{2}, \frac{1}{2}]^T and a2=[1,3,1,3]T\mathbf{a}_2 = [1, 3, 1, 3]^T, the calculation is: r12=q1Ta2=(12)(1)+(12)(3)+(12)(1)+(12)(3)=12+32+12+32=82=4r_{12} = \mathbf{q}_1^T \mathbf{a}_2 = (\frac{1}{2})(1) + (\frac{1}{2})(3) + (\frac{1}{2})(1) + (\frac{1}{2})(3) = \frac{1}{2} + \frac{3}{2} + \frac{1}{2} + \frac{3}{2} = \frac{8}{2} = 4.

Question 3

Let A=[a1,a2]A = [\mathbf{a}_1, \mathbf{a}_2] be a matrix with QR factorization A=QRA=QR. A new matrix AA' is formed by scaling the second column: A=[a1,3a2]A' = [\mathbf{a}_1, 3\mathbf{a}_2]. If the QR factorization of AA' is A=QRA' = Q'R', how do QQ' and RR' relate to QQ and RR?

  1. Q=QQ'=Q, and the second column of RR' is 3 times the second column of RR. (correct answer)
  2. R=RR'=R, and the second column of QQ' is 3 times the second column of QQ.
  3. Q=QQ'=Q, and the second row of RR' is 3 times the second row of RR.
  4. The first column of QQ' is different from the first column of QQ.
Explanation: The first step of the Gram-Schmidt process depends only on a1\mathbf{a}_1, so q1=q1\mathbf{q}'_1 = \mathbf{q}_1 and r11=r11r'_{11} = r_{11}. We have a1=r11q1\mathbf{a}_1 = r_{11}\mathbf{q}_1 and a2=r12q1+r22q2\mathbf{a}_2 = r_{12}\mathbf{q}_1 + r_{22}\mathbf{q}_2. For AA', we have A=[a1,3a2]=[r11q1,3(r12q1+r22q2)]=[r11q1,(3r12)q1+(3r22)q2]A' = [\mathbf{a}_1, 3\mathbf{a}_2] = [r_{11}\mathbf{q}_1, 3(r_{12}\mathbf{q}_1 + r_{22}\mathbf{q}_2)] = [r_{11}\mathbf{q}_1, (3r_{12})\mathbf{q}_1 + (3r_{22})\mathbf{q}_2]. This can be written as A=[q1,q2](r113r1203r22)A' = [\mathbf{q}_1, \mathbf{q}_2] \begin{pmatrix} r_{11} & 3r_{12} \\ 0 & 3r_{22} \end{pmatrix}. Thus, Q=QQ'=Q and the second column of RR' is 3 times the second column of RR.

Question 4

Let a1=[1,1,0]T\mathbf{a}_1 = [1, 1, 0]^T and a2=[1,2,2]T\mathbf{a}_2 = [1, 2, 2]^T. When applying the Gram-Schmidt process to the set of vectors {a1,a2}\{\mathbf{a}_1, \mathbf{a}_2\}, what is the resulting second orthogonal vector v2\mathbf{v}_2?

  1. [32,32,0]T[\frac{3}{2}, \frac{3}{2}, 0]^T
  2. [52,72,2]T[\frac{5}{2}, \frac{7}{2}, 2]^T
  3. [12,12,2]T[-\frac{1}{2}, \frac{1}{2}, 2]^T (correct answer)
  4. [0,1,2]T[0, 1, 2]^T
Explanation: The Gram-Schmidt process sets v1=a1=[1,1,0]T\mathbf{v}_1 = \mathbf{a}_1 = [1, 1, 0]^T. The second orthogonal vector v2\mathbf{v}_2 is found by subtracting the projection of a2\mathbf{a}_2 onto v1\mathbf{v}_1 from a2\mathbf{a}_2. The projection is projv1(a2)=a2v1v12v1=1(1)+2(1)+2(0)12+12+02[1,1,0]T=32[1,1,0]T=[32,32,0]T\mathrm{proj}_{\mathbf{v}_1}(\mathbf{a}_2) = \frac{\mathbf{a}_2 \cdot \mathbf{v}_1}{\|\mathbf{v}_1\|^2}\mathbf{v}_1 = \frac{1(1)+2(1)+2(0)}{1^2+1^2+0^2}[1, 1, 0]^T = \frac{3}{2}[1, 1, 0]^T = [\frac{3}{2}, \frac{3}{2}, 0]^T. Then, v2=a2projv1(a2)=[1,2,2]T[32,32,0]T=[12,12,2]T\mathbf{v}_2 = \mathbf{a}_2 - \mathrm{proj}_{\mathbf{v}_1}(\mathbf{a}_2) = [1, 2, 2]^T - [\frac{3}{2}, \frac{3}{2}, 0]^T = [-\frac{1}{2}, \frac{1}{2}, 2]^T.

Question 5

In the QR factorization A=QRA=QR, the Gram-Schmidt process is used to generate an orthogonal set of vectors {v1,v2,,vn}\{\mathbf{v}_1, \mathbf{v}_2, \ldots, \mathbf{v}_n\} from the columns of AA. How are the diagonal entries rkkr_{kk} of the matrix RR related to these vectors?

  1. rkk=vkr_{kk} = \|\mathbf{v}_k\| (correct answer)
  2. rkk=1r_{kk} = 1 for all kk
  3. rkk=akr_{kk} = \|\mathbf{a}_k\|
  4. rkk=vkvkr_{kk} = \mathbf{v}_k \cdot \mathbf{v}_k
Explanation: The columns of QQ are the normalized versions of the orthogonal vectors vk\mathbf{v}_k, so qk=vkvk\mathbf{q}_k = \frac{\mathbf{v}_k}{\|\mathbf{v}_k\|}. The relationship between the columns of AA and the columns of QQ is given by ak=r1kq1++rkkqk\mathbf{a}_k = r_{1k}\mathbf{q}_1 + \dots + r_{kk}\mathbf{q}_k. The Gram-Schmidt process defines vk\mathbf{v}_k as the component of ak\mathbf{a}_k orthogonal to the subspace spanned by {q1,,qk1}\{\mathbf{q}_1, \dots, \mathbf{q}_{k-1}\}. This component is rkkqkr_{kk}\mathbf{q}_k. Therefore, vk=rkkqk\mathbf{v}_k = r_{kk}\mathbf{q}_k, and taking the norm of both sides gives vk=rkkqk=rkk\|\mathbf{v}_k\| = |r_{kk}| \|\mathbf{q}_k\| = |r_{kk}|. By convention, rkkr_{kk} is chosen to be positive, so rkk=vkr_{kk} = \|\mathbf{v}_k\|.

Question 6

Given the QR factorization of a matrix AA, a linear system Ax=bA\mathbf{x} = \mathbf{b} can be solved more easily. The first step is to transform the system into an equivalent upper triangular system. What is this equivalent system?

  1. Qx=R1bQ\mathbf{x} = R^{-1}\mathbf{b}
  2. Rx=bR\mathbf{x} = \mathbf{b}
  3. Rx=QTbR\mathbf{x} = Q^T\mathbf{b} (correct answer)
  4. QTx=RbQ^T\mathbf{x} = R\mathbf{b}
Explanation: Starting with Ax=bA\mathbf{x} = \mathbf{b}, we substitute A=QRA=QR to get QRx=bQR\mathbf{x} = \mathbf{b}. Since the columns of QQ are orthonormal, QTQ=IQ^TQ=I. We can multiply both sides of the equation on the left by QTQ^T: QT(QRx)=QTbQ^T(QR\mathbf{x}) = Q^T\mathbf{b}, which simplifies to (QTQ)Rx=QTb(Q^TQ)R\mathbf{x} = Q^T\mathbf{b}, and then IRx=QTbIR\mathbf{x} = Q^T\mathbf{b}. This gives the equivalent system Rx=QTbR\mathbf{x} = Q^T\mathbf{b}. This system is easy to solve using back substitution because RR is upper triangular.

Question 7

Let A=[a1,a2]A = [\mathbf{a}_1, \mathbf{a}_2] have the QR factorization A=QRA=QR. In this context, what is the geometric interpretation of the vector r12q1r_{12}\mathbf{q}_1?

  1. The projection of the vector a2\mathbf{a}_2 onto the subspace spanned by q1\mathbf{q}_1. (correct answer)
  2. The component of the vector a1\mathbf{a}_1 that is orthogonal to the vector a2\mathbf{a}_2.
  3. A vector of length r12r_{12} in the direction of the vector a2\mathbf{a}_2.
  4. The projection of the vector a1\mathbf{a}_1 onto the subspace spanned by q2\mathbf{q}_2.
Explanation: From the definition of the QR factorization, r12=q1Ta2r_{12} = \mathbf{q}_1^T \mathbf{a}_2. Since q1\mathbf{q}_1 is a unit vector ( ⁣q1 ⁣=1\!\|\mathbf{q}_1\!\|=1), this dot product is the scalar projection of a2\mathbf{a}_2 onto q1\mathbf{q}_1. Multiplying this scalar by the unit vector q1\mathbf{q}_1 gives the vector projection of a2\mathbf{a}_2 onto the line (subspace) spanned by q1\mathbf{q}_1. This is a key step in the Gram-Schmidt process, where this projection is subtracted from a2\mathbf{a}_2 to find a vector orthogonal to q1\mathbf{q}_1.

Question 8

Consider the matrix A=(031504)A = \begin{pmatrix} 0 & 3 \\ 1 & 5 \\ 0 & 4 \end{pmatrix}. Let A=QRA=QR be its QR factorization. What are the first column of QQ, denoted q1\mathbf{q}_1, and the entry r11r_{11} of RR?

  1. q1=[0,1,0]T\mathbf{q}_1 = [0, 1, 0]^T and r11=1r_{11} = 1 (correct answer)
  2. q1=[0,1,0]T\mathbf{q}_1 = [0, 1, 0]^T and r11=5r_{11} = 5
  3. q1=[0,1/50,0]T\mathbf{q}_1 = [0, 1/\sqrt{50}, 0]^T and r11=50r_{11} = \sqrt{50}
  4. q1=[0,1,0]T\mathbf{q}_1 = [0, 1, 0]^T and r11=0r_{11} = 0
Explanation: The first step in the Gram-Schmidt process is to set v1=a1=[0,1,0]T\mathbf{v}_1 = \mathbf{a}_1 = [0, 1, 0]^T. Next, we find the norm of v1\mathbf{v}_1, which is v1=02+12+02=1\|\mathbf{v}_1\| = \sqrt{0^2+1^2+0^2} = 1. The first diagonal entry of RR is this norm, so r11=1r_{11} = 1. The first column of QQ is found by normalizing v1\mathbf{v}_1: q1=v1v1=[0,1,0]T1=[0,1,0]T\mathbf{q}_1 = \frac{\mathbf{v}_1}{\|\mathbf{v}_1\|} = \frac{[0, 1, 0]^T}{1} = [0, 1, 0]^T. Since the first column of AA was already a unit vector, the process is simplified for the first step.

Question 9

Let AA be an m×nm \times n matrix with nn linearly independent columns. Its QR factorization is A=QRA=QR, where QQ is an m×nm \times n matrix and RR is an n×nn \times n matrix. Which statement most accurately describes the columns of the matrix QQ?

  1. They form an orthonormal basis for the null space of ATA^T.
  2. They form an orthonormal basis for the row space of AA.
  3. They form an orthogonal (but not necessarily orthonormal) basis for the column space of AA.
  4. They form an orthonormal basis for the column space of AA. (correct answer)
Explanation: The QR factorization is constructed by applying the Gram-Schmidt process to the columns of AA. This process explicitly creates a set of orthonormal vectors that span the same space as the original set of vectors. Therefore, the columns of QQ are an orthonormal set of vectors that form a basis for the column space of AA. Distractor C is incorrect because the columns of Q are normalized to have unit length, making them orthonormal, not just orthogonal. The other distractors refer to incorrect fundamental subspaces.

Question 10

Let AA be a 4×24 \times 2 matrix with linearly independent columns, and let A=QRA = QR be its QR factorization. If b\mathbf{b} is a vector in R4\mathbb{R}^4 such that QTb=(52)Q^T\mathbf{b} = \begin{pmatrix} 5 \\ -2 \end{pmatrix} , what is the solution to the least squares problem minxAxb2\min_{\mathbf{x}} ||A\mathbf{x} - \mathbf{b}||^2?

  1. (correct answer)
Explanation: When you encounter QR factorization in least squares problems, you're dealing with an elegant computational shortcut that avoids the numerical instability of the normal equations. The key insight is that for the least squares problem minxAxb2\min_{\mathbf{x}} ||A\mathbf{x} - \mathbf{b}||^2, the normal equations give us ATAx=ATbA^T A \mathbf{x} = A^T \mathbf{b}. When A=QRA = QR, we can substitute: (QR)T(QR)x=(QR)Tb(QR)^T(QR)\mathbf{x} = (QR)^T\mathbf{b}, which simplifies to RTRx=RTQTbR^TR\mathbf{x} = R^TQ^T\mathbf{b}. Since RR is upper triangular and invertible (because AA has linearly independent columns), we can multiply both sides by (RT)1(R^T)^{-1} to get Rx=QTbR\mathbf{x} = Q^T\mathbf{b}. Therefore, x=R1QTb\mathbf{x} = R^{-1}Q^T\mathbf{b}. Since we're given that QTb=(52)Q^T\mathbf{b} = \begin{pmatrix} 5 \\ -2 \end{pmatrix} , the solution is $$\mathbf{x} = R^{-1}\begin{pmatrix} 5 \ -2 \end{pmatrix} Option A represents the traditional normal equations approach but incorrectly applies $$(A^TA)^{-1}$$ to $$Q^T\mathbf{b}$$ instead of $$A^T\mathbf{b}$$. Option B gives you a vector in $$\mathbb{R}^4$$, but $$\mathbf{x}$$ must be in $$\mathbb{R}^2$$ to match $$A$$'s column space. Option D ignores the matrix $$R$$ entirely, which would only work if $$R$$ were the identity matrix. Remember: QR factorization transforms least squares into the simpler system $$R\mathbf{x} = Q^T\mathbf{b}$$. This is computationally superior to forming $$A^TA$$ explicitly.

Question 11

Consider the matrix A=(240300)A = \begin{pmatrix} 2 & 4 \\ 0 & 3 \\ 0 & 0 \end{pmatrix} . In any QR factorization A=QRA = QR of this matrix, what can be concluded about the matrix RR?

  1. RR must have exactly two zero entries below the main diagonal
  2. RR must be identical to AA since AA is already upper triangular
  3. R11=2R_{11} = 2 and R22=3R_{22} = 3 necessarily
  4. RR must be a 2×22 \times 2 matrix with positive diagonal entries (correct answer)
Explanation: Since AA has rank 2 (two linearly independent columns), the reduced QR factorization gives QQ as 3×23 \times 2 and RR as 2×22 \times 2 upper triangular. The diagonal entries of RR are the norms of the orthogonalized vectors, which are positive. Choice A describes the wrong dimension of RR. Choice B is incorrect because the columns of AA are not orthonormal (the first column has norm 2, not 1). Choice C is wrong because R11=a1=2R_{11} = ||\mathbf{a}_1|| = 2 but R22R_{22} equals the norm of the component of a2\mathbf{a}_2 orthogonal to a1\mathbf{a}_1, which is not 3.

Question 12

A 4×34 \times 3 matrix AA has the property that its first two columns are orthogonal unit vectors, and its third column is orthogonal to the first column but not to the second. In the QR factorization A=QRA = QR, which entry of RR represents the component of the third column of AA in the direction of the second column of AA?

  1. R31R_{31}
  2. R32R_{32}
  3. R13R_{13}
  4. R23R_{23} (correct answer)
Explanation: When you encounter QR factorization questions, remember that the process systematically orthogonalizes columns using the Gram-Schmidt procedure, and the RR matrix stores the "memory" of how each original column relates to the orthogonal basis being built. In QR factorization, each entry RijR_{ij} represents how the jj-th original column projects onto the ii-th orthogonal vector. Since the first two columns of AA are already orthogonal unit vectors, they become the first two columns of QQ directly. When processing the third column, the algorithm computes its projections onto all previous orthogonal vectors. The component of the third column in the direction of the second column is exactly what R23R_{23} captures - this is the projection coefficient of column 3 onto the second orthogonal basis vector. This makes (D) R23R_{23} correct. (A) R31R_{31} would represent how a hypothetical fourth column projects onto the first basis vector, but we only have three columns. (B) R32R_{32} reverses the indices - this entry doesn't exist in the standard QR decomposition since RR is upper triangular. (C) R13R_{13} represents how the third column projects onto the first column, not the second. Study tip: In RijR_{ij}, think "column jj projected onto basis vector ii." The upper triangular structure means iji \leq j, and each column index corresponds to an original column of AA while each row index corresponds to a basis vector in QQ.

Question 13

A 3×23 \times 2 matrix AA has QR factorization A=QRA = QR where QQ is 3×23 \times 2 and RR is 2×22 \times 2. If Ax2=17||A\mathbf{x}||^2 = 17 for some vector xR2\mathbf{x} \in \mathbb{R}^2, what is the value of Rx2||R\mathbf{x}||^2?

  1. 1717 (correct answer)
  2. 17\sqrt{17}
  3. Cannot be determined without knowing QQ
  4. Cannot be determined without knowing x\mathbf{x}
Explanation: Since A=QRA = QR and QQ has orthonormal columns, QTQ=I2Q^TQ = I_2. Therefore, Ax2=QRx2=(QRx)T(QRx)=xTRTQTQRx=xTRTRx=Rx2=17||A\mathbf{x}||^2 = ||QR\mathbf{x}||^2 = (QR\mathbf{x})^T(QR\mathbf{x}) = \mathbf{x}^TR^TQ^TQR\mathbf{x} = \mathbf{x}^TR^TR\mathbf{x} = ||R\mathbf{x}||^2 = 17. Choice B incorrectly takes a square root. Choice C fails to recognize that orthonormality of QQ makes the result independent of the specific form of QQ. Choice D incorrectly suggests the relationship depends on the specific vector x\mathbf{x} rather than being a general property.

Question 14

Consider the matrix A=(110101011)A = \begin{pmatrix} 1 & 1 & 0 \\ 1 & 0 & 1 \\ 0 & 1 & 1 \end{pmatrix} . If A=QRA = QR is the QR factorization where QQ has orthonormal columns, what is the entry in position (2,1)(2,1) of the matrix QQ?

  1. 12\frac{1}{\sqrt{2}} (correct answer)
  2. 16\frac{1}{\sqrt{6}}
  3. 23\frac{\sqrt{2}}{\sqrt{3}}
  4. 12\frac{1}{2}
Explanation: To find Q, we apply Gram-Schmidt to the columns of A. Let the columns be a1=(1,1,0)T\mathbf{a}_1 = (1,1,0)^T, a2=(1,0,1)T\mathbf{a}_2 = (1,0,1)^T, a3=(0,1,1)T\mathbf{a}_3 = (0,1,1)^T. First, u1=a1=(1,1,0)T\mathbf{u}_1 = \mathbf{a}_1 = (1,1,0)^T with u1=2||\mathbf{u}_1|| = \sqrt{2}, so q1=12(1,1,0)T\mathbf{q}_1 = \frac{1}{\sqrt{2}}(1,1,0)^T. The (2,1)(2,1) entry of Q is the second component of q1\mathbf{q}_1, which is 12\frac{1}{\sqrt{2}}. Choice B gives the incorrect normalization factor. Choice C involves an erroneous calculation mixing norms. Choice D uses the wrong denominator from incomplete normalization.

Question 15

Consider a 3×33 \times 3 matrix AA whose columns have norms a1=2||\mathbf{a}_1|| = 2, a2=3||\mathbf{a}_2|| = 3, and a3=1||\mathbf{a}_3|| = 1. After applying Gram-Schmidt orthogonalization, the resulting orthogonal vectors have norms u1=2||\mathbf{u}_1|| = 2, u2=5||\mathbf{u}_2|| = \sqrt{5}, and u3=23||\mathbf{u}_3|| = \frac{2}{3}. In the QR factorization A=QRA = QR, what is R22R_{22}?

  1. 33
  2. 5\sqrt{5} (correct answer)
  3. 23\frac{2}{3}
  4. 53\frac{\sqrt{5}}{3}
Explanation: In the QR factorization, the diagonal entries of RR are the norms of the orthogonalized vectors from Gram-Schmidt: Rii=uiR_{ii} = ||\mathbf{u}_i||. Therefore, R22=u2=5R_{22} = ||\mathbf{u}_2|| = \sqrt{5}. Choice A incorrectly uses the original norm of a2\mathbf{a}_2. Choice C uses the norm of u3\mathbf{u}_3. Choice D incorrectly attempts to normalize u2||\mathbf{u}_2|| by the original norm of a2\mathbf{a}_2, which is not how the QR factorization works.

Question 16

Let AA be a 4×34 \times 3 matrix with QR factorization A=QRA = QR, where QQ is 4×34 \times 3 with orthonormal columns and RR is 3×33 \times 3 upper triangular. If the second column of AA is orthogonal to the first column of AA, which of the following must be true about the matrix RR?

  1. R12=0R_{12} = 0 and R21=0R_{21} = 0
  2. R12=0R_{12} = 0 only (correct answer)
  3. R21=0R_{21} = 0 only
  4. R11=R22R_{11} = R_{22}
Explanation: In the Gram-Schmidt process, Rij=aj,qiR_{ij} = \langle \mathbf{a}_j, \mathbf{q}_i \rangle for iji \leq j. Since a2a1\mathbf{a}_2 \perp \mathbf{a}_1, we have a2,q1=a2,a1a1=0\langle \mathbf{a}_2, \mathbf{q}_1 \rangle = \frac{\langle \mathbf{a}_2, \mathbf{a}_1 \rangle}{||\mathbf{a}_1||} = 0, so R12=0R_{12} = 0. Since RR is upper triangular, R21=0R_{21} = 0 by definition, not due to orthogonality. Choice A incorrectly suggests both are consequences of orthogonality. Choice C misses the key implication. Choice D makes an unrelated claim about diagonal entries.

Question 17

The QR factorization of a matrix AA with linearly independent columns is A=QRA=QR. Under which condition is this factorization guaranteed to be unique?

  1. The factorization is unique only if AA is a square matrix.
  2. The factorization is unique if the diagonal entries of RR are required to be positive. (correct answer)
  3. The factorization is always unique due to the deterministic nature of the Gram-Schmidt algorithm.
  4. The factorization is never unique because any column qi\mathbf{q}_i can be replaced with qi-\mathbf{q}_i.
Explanation: The QR factorization is not strictly unique because of sign choices. If we have a factorization A=QRA = QR, we can define a diagonal matrix DD with entries ±1\pm 1. Then A=(QD)(D1R)=QRA = (QD)(D^{-1}R) = Q'R' is another valid QR factorization. The matrix QQ' still has orthonormal columns, and RR' is still upper triangular. To ensure uniqueness, a convention is adopted: requiring all diagonal entries of RR to be positive. This constraint fixes the signs of the columns in QQ.

Question 18

Let AA be an m×nm \times n matrix with linearly independent columns, and let A=QRA=QR be its QR factorization. Which of the following statements is always true?

  1. The matrix QQ is invertible.
  2. The matrix RR is symmetric.
  3. The columns of QQ form an orthonormal basis for the column space of AA. (correct answer)
  4. The determinant of RR is equal to the determinant of AA.
Explanation: The QR factorization is constructed using the Gram-Schmidt process on the columns of AA. This process generates an orthonormal set of vectors that spans the same subspace as the original columns. Therefore, the columns of QQ form an orthonormal basis for the column space of AA. Distractor A is false because QQ is only square (and thus invertible) if m=nm=n. Distractor B is false; RR is upper triangular, not necessarily symmetric. Distractor D is false because det(A)=det(Q)det(R)\det(A) = \det(Q)\det(R), and det(Q)\det(Q) is not always 1 (it can be -1).

Question 19

A 5×35 \times 3 matrix AA has rank 2. When computing the QR factorization using Gram-Schmidt orthogonalization, what happens during the process when reaching the third column?

  1. The process fails because QR factorization requires full column rank
  2. The third column is automatically orthogonal to the first two, so no modification is needed
  3. The third column becomes a zero vector after orthogonalization, requiring special handling to complete the factorization (correct answer)
  4. The third column is replaced by an arbitrary unit vector orthogonal to the column space
Explanation: When you encounter QR factorization problems involving rank-deficient matrices, focus on what happens during the Gram-Schmidt orthogonalization process when columns are linearly dependent. In Gram-Schmidt, each new column is made orthogonal to all previous columns by subtracting their projections. For a 5×35 \times 3 matrix with rank 2, the first two columns are linearly independent and will orthogonalize normally. However, the third column must be a linear combination of the first two (since the column space is only 2-dimensional). When you apply Gram-Schmidt to the third column, you subtract its projections onto the first two orthogonal vectors. Since the third column lies entirely in the span of the first two, these projections account for the entire vector - leaving nothing behind. The result is the zero vector, which cannot be normalized to create a unit vector for the QQ matrix. This is why answer C is correct: special handling is needed to complete the factorization, typically by adding an orthonormal vector to span the full space. Answer A is wrong because QR factorization can handle rank-deficient matrices with modifications. Answer B is incorrect because if the third column were already orthogonal to the first two, the matrix would have rank 3, not 2. Answer D mischaracterizes the process - the algorithm doesn't arbitrarily replace columns; it follows the mathematical consequence of linear dependence. Study tip: Remember that Gram-Schmidt reveals linear dependence by producing zero vectors - this is your signal that special techniques are needed for completion.