6.1 Inner Product, Length & Orthogonality In order to solve problems like line of best fit, Fourier approximations and more, we must develop fundamental ideas of length, orthogonality and orthogonal projections. The Inner Product. In R2, we called the inner product the dot product. u1 v1 u v Inner product or dot product of u = 2 and v = 2 u n vn v1 v u • v = u T v = u1 u2 un 2 = u1v1 + u2v2 + + un vn vn Note that v u = v1u1 + + vnun = u1v1 + + unvn = u v = 2 −1 4 −1 0 −3 Ex 1: Compute each of the following given that u = , v = and w = 3 2 0 2 5 6 vgw a. b. ug(v − w) d. Find a unit vector in the direction of w. c. || u || Theorem 1: Let u, v and w be vectors in Rn , and let c be any scalar. Then a. u • v = v • u (symmetry axiom) b. (u + v ) • w = u • w + v • w c. ( cu ) • v = c ( u • v ) = u • ( cv ) (additivity axiom) (homogeneity axiom) d. u • u 0 and u • u = 0 if and only if u = 0. (positivity axiom) Length of a Vector v1 v For v = 2 , the length or norm of v is the nonnegative scalar v defined by v3 v = v • v = v12 + v22 + + vn2 and v = v • v a For example, if v = , then v = a 2 + b2 (distance between 0 and v) b For any scalar c, cv = c v dist (u, v) = u − v Distance in Rn The distance between u and v in Rn : This agrees with the usual formulas for R 2 and R3 . Let u = ( u1 , u2 ) and v = ( v1 , v2 ) . Then u – v = ( u1 − v1 , u2 − v2 ) and dist(u,v)= u − v = ( u1 − v1 , u2 − v2 ) = (u1 − v1 ) + (u2 − v2 ) 2 2 1 −2 3 1 Example 2: Find the distance between −3 and 0 4 4 0 3 u ||u-v|| v Orthogonal Vectors From Geometry, we know that two lines are geometrically perpendicular iff the distance from u to v is the same as the distance from u to –v. This also means that the squares of the distances is the same. [dist(u,v)]² = = = = ||u+v|| 0 ‖u-v² = (u-v)⋅(u-v) (u)⋅(u-v)+(-v)⋅(u-v) u⋅u - u⋅v + -v⋅u + v⋅v ‖u² +‖v² -2u⋅v u ⇒ [dist(u,v)]²=‖u‖²+‖v‖²- 2u⋅v Similarly, [dist(u,-v)]²=‖u‖²+‖v‖² + 2u⋅v Since [dist(u,-v)]² = [dist(u,v)]², u⋅v = __?___. Two vectors u and v are said to be orthogonal (to each other) if u⋅v = 0. 2 Also note that if u and v are orthogonal, then ‖u+v‖ =‖u‖² +‖v‖². 2 Theorem 2 (The Pythagorean Theorem): Two vectors u and v are orthogonal if and only if ‖u+v‖ =‖u‖²+‖v‖². Example 3: Determine whether the given vectors are orthogonal. a. u = (-1, 3, 2), v = (4, 2, -1) b. u = (u1, u1, u1), v = (0, 0, 0) c. u = (0, 3, -2, 1), v = (5, 2, -1, 0) Orthogonal Complements If a vector z is orthogonal to every vector in a subspace W of Rⁿ, then z is said to be orthogonal to W. The set of vectors z that are orthogonal to W is called the orthogonal complement of W and is denoted by W ⊥ (read as "W perp"). Row, Null and Columns Spaces Theorem 3: Let A be an m×n matrix. Then the orthogonal complement of the row space of A is the nullspace of A, and the orthogonal complement of the column space of A is the nullspace of AT (Row A)⊥ = Nul A and (Col A)⊥ = Nul AT 1 0 −1 Ex 4: Let A = −2 0 2 a. b. c. d. Find a basis for Nul A. Is Nul A is a line or plane in R2 or R3? Find a basis for Row A. Is Row A is a line or plane in R2 or R3? Find a basis for Col A. Is Col A is a line or plane in R2 or R3? Find a basis for Nul AT. Is Nul AT is a line or plane in R2 or R3? Geometric representations of previous problem: Nul A Col A Row A Nul AT