# Engineering Analysis/Projections

## Projection

The projection of a vector ${\displaystyle v\in V}$ onto the vector space ${\displaystyle W\in V}$ is the minimum distance between v and the space W. In other words, we need to minimize the distance between vector v, and an arbitrary vector ${\displaystyle w\in W}$:

${\displaystyle \|w-v\|^{2}=\|{\hat {W}}{\hat {a}}-v\|^{2}}$
${\displaystyle {\frac {\partial \|{\hat {W}}{\hat {a}}-v\|^{2}}{\partial {\hat {a}}}}={\frac {\partial \langle {\hat {W}}{\hat {a}}-v,{\hat {W}}{\hat {a}}-v\rangle }{\partial {\hat {a}}}}=0}$

[Projection onto space W]

${\displaystyle {\hat {a}}=({\hat {W}}^{T}{\hat {W}})^{-1}{\hat {W}}^{T}v}$

For every vector ${\displaystyle v\in V}$ there exists a vector ${\displaystyle w\in W}$ called the projection of v onto W such that <v-w, p> = 0, where p is an arbitrary element of W.

### Orthogonal Complement

${\displaystyle w^{\perp }={x\in V:\langle x,y\rangle =0,\forall y\in W}}$

## Distance between v and W

The distance between ${\displaystyle v\in V}$ and the space W is given as the minimum distance between v and an arbitrary ${\displaystyle w\in W}$:

${\displaystyle {\frac {\partial d(v,w)}{\partial {\hat {a}}}}={\frac {\partial \|v-{\hat {W}}{\hat {a}}\|}{\partial {\hat {a}}}}=0}$

## Intersections

Given two vector spaces V and W, what is the overlapping area between the two? We define an arbitrary vector z that is a component of both V, and W:

${\displaystyle z={\hat {V}}{\hat {a}}={\hat {W}}{\hat {b}}}$
${\displaystyle {\hat {V}}{\hat {a}}-{\hat {W}}{\hat {b}}=0}$
${\displaystyle {\begin{bmatrix}{\hat {a}}\\{\hat {b}}\end{bmatrix}}={\mathcal {N}}([{\hat {v}}-{\hat {W}}])}$

Where N is the nullspace.