Any nonzero vector can be divided by its length to form a unit vector. Thus for a plane (or a line), a normal vector can be divided by its length to get a unit normal vector. Example:For the equation, x + 2y + 2z = 9, the vector A = (1, 2, 2) is a normal vector. |A| = square root of (1+4+4) = 3.
Trend Lines. Demo source. JavaScript TypeScript / ES6