The dot and cross products have geometric interpretations that we will not explore here, but computationally they are easily described. For two vectors ,
, the dot product is a mapping
,
defined by the formula
dot(a,b) = .
The standard cross product, on the other hand, is defined only for vectors , where
, and returns a perpendicular vector,
cross: ,
cross(a,b) = .
An equivalent definition of cross product, which allows for easier generalization to higher dimensions, is given by
cross(a,b) = det.
The norm of a vector is the Euclidean length or ordinary sense of measuring a one-dimensional distance of a line in multiple dimensions, it is given by
,
norm(a) = .
There is a generalization of norms called p-norms (see for example the Wikipedia articles on Norms or Lp Space), but we will n0t go into details here.
The angle between two vectors
is given by the formula
,
angle(a,b) = .
The numerator is the dot product between vectors and
, and the denominator is the product of the norms.
Exercise 1. Let and
. Find the dot and cross products, the norms, and the angle between these two vectors.
Exercise 2. Using the formula for angle, show that .
Exercise 3. For in Exercise 1, compute the two different formulas for dot product and verify that they give the same answer. (There is a post about how to work with matrices).