Project v onto a unit direction u. The dot product v · u gives the signed length along that direction; here (3,2) · (1,0) = 3.

Project v onto a unit direction u. The dot product v · u gives the signed length along that direction; here (3,2) · (1,0) = 3.