Projection Gram-Schmidt and QR Factorization

# Projection Gram-Schmidt and QR Factorization

## 1. 投影

$$\mathbb {R}^n$$ 中寻找一个列向量 $$\mathbf {\hat x}$$ ，使得向量 $$(\mathbf {b} – A \mathbf {\hat x})$$ 的长度最小。或者说，在何种情况下，下图中的向量 $$\mathbf {e}$$ 长度最小 ？

• It equals its square: $$P^2 = P$$
• It equals its transpose: $$P^T = P$$

## 2. Gram-Schmidt orthogonalization

### 2.1 正交矩阵 (orthogonal matrix)

1. $$QQ^T$$$$Q$$ 列空间的向量，效果和 $$I$$ 是相同的
$$(QQ^T) (Q \mathbf{x}) = Q(Q^TQ)\mathbf{x} = Q\mathbf{x}$$
这里 $$(QQ^T)$$ 效果和 矩阵 $$I$$ 相同

2. $$QQ^T$$$$Q$$ 左零空间的向量， 效果和左零空间的正交空间的向量是相同的
因为如果 $$Q^T \mathbf{b} = \mathbf {0}$$ ，则 $$(QQ^T) \mathbf{b} = Q (Q^T \mathbf{b}) = \mathbf {0}$$
也就是说，对于左零空间的任何向量 $$\mathbf{b}$$ , 都有 $$QQ^T\mathbf{b} = \mathbf{0}$$
其实很好理解，$$QQ^T$$ 的列空间 是 $$Q$$ 的列空间的子集，

• 它是投影矩阵，自然 $$QQ^T$$ 会把任何向量投影到 $$Q$$ 的列空间
• $$QQ^T$$ 的列向量是 $$Q$$ 的列向量的线性组合

### 2.3 施密特正交化

To substract every new vector its components in the directions that are already settled.

## 3. QR Factorization

$$A = QR$$

Every $$m$$ by $$n$$ matrix with independent columns can be factored into $$A=QR$$. The columns of $$Q$$ are orthonormal, and $$R$$ is upper triangular and invertible. When $$m=n$$ and all matrices are square, $$Q$$ becomes an orthogonal matrix.

## One thought on “Projection Gram-Schmidt and QR Factorization”

This site uses Akismet to reduce spam. Learn how your comment data is processed.