Worked example
Drop a perpendicular from a point
For and the line , find the foot of the perpendicular . Give the parameter and every coordinate of .
Put on the line. The displacement from to must be perpendicular to its direction.
Set the scalar product to zero. This gives , so .
Substitute into the line to obtain .
The perpendicular foot is at .