Project a vector \(v\) onto a line or a subspace. For a line spanned by \(u\), \(\mathrm{proj}(v)=\dfrac{v\cdot u}{\lVert u\rVert^2}u\). For a subspace with basis columns \(U\), \(\mathrm{proj}(v)=U(U^{\mathsf T}U)^{-1}U^{\mathsf T}v\). The orthogonal component is \(r=v-\mathrm{proj}(v)\).
Orthogonal Projection Calculator
Math Linear Algebra • Applications and Advanced Linear Algebra (capstone)
Frequently Asked Questions
What does orthogonal projection mean?
It is the closest point in the target line/subspace to the vector v, measured by Euclidean distance. The difference r=v-proj(v) is perpendicular to the target.
Why does subspace projection use (U^T U)α=U^T v?
Writing proj(v)=Uα and minimizing ||v-Uα||^2 yields the normal equations. The residual must be orthogonal to every column of U.
What if U^T U is singular?
That indicates the basis vectors are linearly dependent or nearly dependent. The calculator may use a tiny stabilization to compute a least-squares style projection.