Scalar Product / Dot Product / Inner Product

Similar documents
Recall that two vectors in are perpendicular or orthogonal provided that their dot

9 Multiplication of Vectors: The Scalar or Dot Product

3. INNER PRODUCT SPACES

Similarity and Diagonalization. Similar Matrices

Lectures notes on orthogonal matrices (with exercises) Linear Algebra II - Spring 2004 by D. Klain

Figure 1.1 Vector A and Vector F

α = u v. In other words, Orthogonal Projection

Vector has a magnitude and a direction. Scalar has a magnitude

Math 215 HW #6 Solutions

9.4. The Scalar Product. Introduction. Prerequisites. Learning Style. Learning Outcomes

Section V.3: Dot Product

1.3. DOT PRODUCT If θ is the angle (between 0 and π) between two non-zero vectors u and v,

The Dot and Cross Products

Recall the basic property of the transpose (for any A): v A t Aw = v w, v, w R n.

Orthogonal Diagonalization of Symmetric Matrices

Geometry of Vectors. 1 Cartesian Coordinates. Carlo Tomasi

Lecture 14: Section 3.3

Orthogonal Projections and Orthonormal Bases

Adding vectors We can do arithmetic with vectors. We ll start with vector addition and related operations. Suppose you have two vectors

Inner product. Definition of inner product

Section 1.1. Introduction to R n

Inner Product Spaces and Orthogonality

Linear Algebra Review. Vectors

5. Orthogonal matrices

Linear Algebra Notes for Marsden and Tromba Vector Calculus

Linear Algebra: Vectors

Vector Math Computer Graphics Scott D. Anderson

L 2 : x = s + 1, y = s, z = 4s Suppose that C has coordinates (x, y, z). Then from the vector equality AC = BD, one has

Vectors Math 122 Calculus III D Joyce, Fall 2012

Orthogonal Projections

Unified Lecture # 4 Vectors

Section 4.4 Inner Product Spaces

Chapter 6. Orthogonality

Inner Product Spaces

Section 1.4. Lines, Planes, and Hyperplanes. The Calculus of Functions of Several Variables

Mechanics 1: Vectors

A vector is a directed line segment used to represent a vector quantity.

Problem Set 5 Due: In class Thursday, Oct. 18 Late papers will be accepted until 1:00 PM Friday.

Definition: A vector is a directed line segment that has and. Each vector has an initial point and a terminal point.

Problem set on Cross Product

Nonlinear Iterative Partial Least Squares Method

12.5 Equations of Lines and Planes

Vector Algebra II: Scalar and Vector Products

Notes on Orthogonal and Symmetric Matrices MENU, Winter 2013

MAT 242 Test 3 SOLUTIONS, FORM A

Linearly Independent Sets and Linearly Dependent Sets

Solutions to Math 51 First Exam January 29, 2015

5.3 The Cross Product in R 3

MAT 1341: REVIEW II SANGHOON BAEK

Equations Involving Lines and Planes Standard equations for lines in space

Chapter 20. Vector Spaces and Bases

Computing Orthonormal Sets in 2D, 3D, and 4D

Lecture L3 - Vectors, Matrices and Coordinate Transformations

CS3220 Lecture Notes: QR factorization and orthogonal transformations

Physics 235 Chapter 1. Chapter 1 Matrices, Vectors, and Vector Calculus

Name: Section Registered In:

Review Jeopardy. Blue vs. Orange. Review Jeopardy

Two vectors are equal if they have the same length and direction. They do not

28 CHAPTER 1. VECTORS AND THE GEOMETRY OF SPACE. v x. u y v z u z v y u y u z. v y v z

3 Orthogonal Vectors and Matrices

Section 9.5: Equations of Lines and Planes

Dot product and vector projections (Sect. 12.3) There are two main ways to introduce the dot product

One advantage of this algebraic approach is that we can write down

1 VECTOR SPACES AND SUBSPACES

Section 5.3. Section 5.3. u m ] l jj. = l jj u j + + l mj u m. v j = [ u 1 u j. l mj

13 MATH FACTS a = The elements of a vector have a graphical interpretation, which is particularly easy to see in two or three dimensions.

1 Introduction to Matrices

Chapter 17. Orthogonal Matrices and Symmetries of Space

Chapter 19. General Matrices. An n m matrix is an array. a 11 a 12 a 1m a 21 a 22 a 2m A = a n1 a n2 a nm. The matrix A has n row vectors

[1] Diagonal factorization

Essential Mathematics for Computer Graphics fast

is in plane V. However, it may be more convenient to introduce a plane coordinate system in V.

by the matrix A results in a vector which is a reflection of the given

ISOMETRIES OF R n KEITH CONRAD

Introduction to Geometric Algebra Lecture II

THREE DIMENSIONAL GEOMETRY

x = + x 2 + x

F B = ilbsin(f), L x B because we take current i to be a positive quantity. The force FB. L and. B as shown in the Figure below.

Geometric description of the cross product of the vectors u and v. The cross product of two vectors is a vector! u x v is perpendicular to u and v

v 1 v 3 u v = (( 1)4 (3)2, [1(4) ( 2)2], 1(3) ( 2)( 1)) = ( 10, 8, 1) (d) u (v w) = (u w)v (u v)w (Relationship between dot and cross product)

v w is orthogonal to both v and w. the three vectors v, w and v w form a right-handed set of vectors.

Section Inner Products and Norms

MATH 304 Linear Algebra Lecture 20: Inner product spaces. Orthogonal sets.

11.1. Objectives. Component Form of a Vector. Component Form of a Vector. Component Form of a Vector. Vectors and the Geometry of Space

Geometric Transformation CS 211A

MAT 200, Midterm Exam Solution. a. (5 points) Compute the determinant of the matrix A =

JUST THE MATHS UNIT NUMBER 8.5. VECTORS 5 (Vector equations of straight lines) A.J.Hobson

Unit 11 Additional Topics in Trigonometry - Classwork

6. Vectors Scott Surgent (surgent@asu.edu)

Biggar High School Mathematics Department. National 5 Learning Intentions & Success Criteria: Assessing My Progress

Applied Linear Algebra

Applied Linear Algebra I Review page 1

A QUICK GUIDE TO THE FORMULAS OF MULTIVARIABLE CALCULUS

x1 x 2 x 3 y 1 y 2 y 3 x 1 y 2 x 2 y 1 0.

Math 241, Exam 1 Information.

Section 9.1 Vectors in Two Dimensions

Cross product and determinants (Sect. 12.4) Two main ways to introduce the cross product

discuss how to describe points, lines and planes in 3 space.

521493S Computer Graphics. Exercise 2 & course schedule change

Solving Simultaneous Equations and Matrices

Transcription:

Scalar Product / Dot Product / Inner Product Scalar product, dot product, and inner product all are different name for the same operation. Scalar product should not be confused with multiplying a vector with a scalar. Scalar product refers to the product of two vectors whose result is a scalar. This operation is between two vectors of the same dimension. The notation for the operation is a DOT ( ). Scalar product between vectors a and b: a b = s Where s is a scalar.

How to compute scalar product? u = u u 2 u n and v = v v 2 v n u v = u u 2 u n v v 2 v n = u v + u 2 v 2 + + u n v n 2

Properties of scalar product Property (a) : Commutative Property (b) : Distributive Property (d) : Let u = (u, u 2, u n ). u. u = u 2 + u 2 2 + u n 2 which is positive, and 0 only if all components of u are 0 3

Geometric interpretation The result of scalar product is proportional to the cosine of the angle between the vectors. a b = a b cos θ Example: a = 3, b = 0 2, a b = 2 2 cos 60 = 2 By earlier approach, a b = 3 0 2 = 0+2=2 b θ a 4

Scalar product of perpendicular vectors Since a b = a b cos θ, the scalar product of two perpendicular vector is 0. (cos 90 = 0) If we are given two vectors, we can determine if they are perpendicular to each other or not. Example: u = 2 and v = 0 2 are perpendicular, because u v = 0. When two vectors are perpendicular they are linearly independent too! However, u = 2 and v = 0 are trivially perpendicular. u v = 0. 0 But they are linearly DEPENDENT! So when a question asked to find a perpendicular vector to u, DO NOT give this trivial answer!! 5

Scalar product of a vector with itself Since a a = a a cos 0, the scalar product of a vector with itself is a 2. (cos 0 = ) What if a is. In other words, a is a unit vector? a a = Let s make this claim stronger: a is a unit vector, if and only if a a = 6

Projection of vector b on vector a, and a on b a b = a b cos θ What if a is. In other words, a is a unit vector? a b = a b cos θ = b cos θ, which is the LENGTH (magnitude) of the perpendicular projection of b on a The dotted line is perpendicular to a What if a is not. b LENGTH of the perpendicular projection of b on a a b b cos θ = a LENGTH of the perpendicular projection of a on b a b a cos θ = b cos θ b 7 b sin θ

Projected VECTOR of vector b on vector a a b = a b cos θ Vector c is the image/perpendicular projection of b on a Direction of c is the same as a Magnitude of c is c = b cos θ = a b c = a b If a is the unit vector of a, vector c = a b a a a b a = a a a b cos θ = a b a a a c = a b a a a 8 b b sin θ

Orthogonal set Any set of vectors that are mutually orthogonal, is a an orthogonal set. 9

Orthonormal set Any set of unit vectors that are mutually orthogonal, is a an orthonormal set. In other words, any orthogonal set is an orthonormal set if all the vectors in the set are unit vectors. Example: u, u 2, u 3 is an orthonormal set, where, 3 u =, u 2 = 6 2 6, u 3 = 66 4 66 7 6 66 0

An orthogonal set is Linearly Independent

Orthogonal basis An orthogonal basis for a subspace W of R n is a basis for W that is also an orthogonal set. Example: 0 0, 0 0, 0 0 is basically the x, y, and z axis. It is an orthogonal basis in R 3, and it spans the whole R 3 space. It is also an orthogonal set. 2

Projected VECTOR of vector b on vector a a b = a b cos θ Vector c is the image/perpendicular projection of b on a Direction of c is the same as a Magnitude of c is c = b cos θ = a b c = a b If a is the unit vector of a, vector c = a b a a a b a = a a a b cos θ = a b a a a c = a b a a a 3 b b sin θ

Orthogonal basis We know that given a basis of a subspace, any vector in that subspace will be a linear combination of the basis vectors. For example, if u and v are linearly independent and form the basis for a subspace S, then any vector y in S can be expressed as: y = c u + c 2 v But computing c and c 2 is not straight forward. On the other hand, if u and v form an orthogonal basis, Then, c = y u = y u u u u c 2 = y v v = y v v v c 2 v y c u 4

Does not work if it is not Orthogonal basis y = c u + c 2 v But computing c and c 2 is not straight forward (yet). v What is computed is, d = y u u d 2 = y v v = y u u u = y v v v d 2 c 2 y u c d 5

For an orthogonal basis 6

Projection of a vector on a Subspace (span) 𝒖 and 𝒗 are orthogonal 3D vectors. They span a plane (green plane) in 3D 𝒚 is an arbitrary 3D vector out of the plane. 𝒚 is the projection of 𝒚 onto the plane. 𝒚 = 𝒚 𝒖 𝒖 𝒖 𝒖 + 𝒚 𝒗 𝒗 𝒗 𝒗 Perpendicular to 𝒚, 𝒖, 𝒗 𝒚 𝒗 𝒚 𝒖 The point 𝒚 is also the closest point to 𝒚 on the plane. 𝒚 𝒚 is perpendicular to 𝒚, Span{𝒖, 𝒗}, and hence 𝒖 𝑎𝑛𝑑 𝒗 7

Closest point of a vector to a span does not depend on the basis of that span 𝒚 is an arbitrary 3D vector out of the plane. 𝒚 𝒚 is the projection of 𝒚 onto the plane. 𝒖𝟒 𝒚 = 𝑥 𝒖𝟏 + 𝑥2 𝒖𝟐 𝒖𝟑 𝒚 = 𝑥3 𝒖𝟑 + 𝑥4 𝒖𝟒 𝒚 𝒚 = 𝑥5 𝒖𝟏 + 𝑥6 𝒖𝟑 𝒖𝟐 𝒖𝟏 Coordinates of 𝒚 change if the basis changes. But the vector 𝒚 itself does not change. Hence the the closest point to 𝒚 on the plane does not change. Even here, 𝒚 𝒚 is perpendicular to 𝒚 and Span{.,. } Perpendicular to 𝒚 and the span 8

Closest point of a vector to a span does not depend on the basis of that span FINDING THE CLOSEST POINT OF A VECTOR TO A SPAN means Finding the coordinates of the projection of the vector. So, if you want to compute the closest point of a vector to a span, then find an appropriate basis with which you can compute the coordinates of the projection easily. What would be that basis? Answer: An orthogonal basis! u 4 u 3 y y u 2 u Perpendicular to y and the span 9

Projection on a span of non-orthogonal vectors How to find projection of any arbitrary 3D vector onto the span of two non-orthogonal, linearly independent vectors? u and u 2 are not orthogonal, but linearly independent vectors in 3D. y is an arbitrary 3D vector. Find the projection of y in the space spanned by u and u 2. a) First, find the orthogonal set of vectors v and v 2 that span the same subspace as u and u 2. In other words, find an orthogonal basis. b) Project y onto the space spanned by orthogonal v and v 2 vectors, as we earlier. v 2 u 2 u v y y 20

How to find an orthogonal basis? Given two LI vectors {𝒖, 𝒖2 } find the orthogonal basis for Span{𝒖, 𝒖2 } Assume that the first vector 𝒖 is in the orthogonal basis. Other vector(s) of the basis are computed that are perpendicular to 𝒖 Let 𝒗 = 𝒖 𝒚 𝒖2 𝒗 Let 𝒗2 = 𝒖2 𝒗 𝒗 𝒗 We know that 𝒗2 is perpendicular to 𝒗. 𝒗2 is in the Span{𝒖, 𝒖2 } (Why?) So Span{𝒖, 𝒖2 } = Span{𝒗, 𝒗2 } And {𝒗, 𝒗2 } is an orthogonal basis Projection of 𝒚 on to the Span{𝒖, 𝒖2 } 𝒚 𝒗 𝒚 𝒗2 𝒚 = 𝒗 + 𝒗2 𝒗 𝒗 𝒗2 𝒖2 𝒚 𝒖 𝒗 𝒗2 𝒗2 2

The Gram-Schmidt process 22

Linear Least Squares Example A trader buys and/or sells tomatoes and potatoes. (Negative number means buys, positive number means sells.) In the process, he either makes profit (positive number) or loss (negative number). A week s transaction is shown; find the approximate cost of tomatoes and potatoes. Tomatoes (tons) Potatoes (tons) -6 - -2 2 7 6 Profit/Loss (in thousands) 23

t - 6p = t - 2p = 2 t + p = t + 7p = 6 t + 6 2 7 p = 2 6 The above equation might not have a solution (values of t and p that would satisfy that equation). So the best we can do is to find the values of t and p that would result in a vector on the right hand side that is as close as possible to the desired right hand side vector. 24

25