Anda di halaman 1dari 8

5

Lecture 2
2.1

Length, Dot Product, Cross Product

Length

We know that in 2-space, the distance between P1 (x1 , y1 ) and P2 (x2 , y2 ) is


p
d = (x2 x1 )2 + (y2 y1 )2 .

This is at the same time the length of the vector ~v = P1 P2 , denoted by ||~v||.

In 3-space, there is a similar formula: the distance between P1 (x1 , y1 , z1 ) and


P2 (x2 , y2 , z2 ) is
p
d = (x2 x1 )2 + (y2 y1 )2 + (z2 z1 )2

which again is the length ||~v|| of the vector ~v = P1 P2 .


Can you prove these formulas using elementary geometry and the following diagrams? (Hint: Pythagoras theorem).
y

(x 2 ,y 2 ,z 2 )

z 2 -z 1

(x2 ,y2 )
d
(x 1 ,y1 )

y2 -y 1

(x 1,y1 ,z 1 )

y2 -y 1

x 2 -x 1
y

x 2 -x 1
x
x

Thus, the length of a vector ~v = hv1 , v2 , v3 i (or ~v = hv1 , v2 , v3 , . . . vn i), also called
the norm of ~v , is given by

q
||~v|| = v12 + v22 + v32


q
2
2
2
2
or ||~v|| = v1 + v2 + v3 + + vn .

The zero vector ~0 has length 0.


A vector of length 1 is called a unit vector. For example, if ~v 6= ~0, then ||~v1|| ~v
is a unit vector (why? Please check). The following unit vectors are of special
importance:

2.2 Dot Product

~i = h1, 0i, ~j = h0, 1i in 2-space,


~i = h1, 0, 0i, ~j = h0, 1, 0i, ~k = h0, 0, 1i in 3-space.
This is because for any vector ~v = hv1 , v2 i, we have
~v = hv1 , v2 i = hv1 , 0i + h0, v2 i

= v1 h1, 0i + v2 h0, 1i
= v1~i + v2~j;

and for any vector ~v = hv1 , v2 , v3 i, we have


~v = hv1 , v2 , v3 i = v1~i + v2~j + v3~k.
These vectors are sometimes called the unit coordinate vectors.

2.2

Dot Product

The dot product assigns a scalar (number) to two vectors. It can be defined in
any dimension.
Let ~u = hu1 , u2 i, ~v = hu1 , v2 i. Then the dot product of ~u and ~v is given by
~u ~v = u1 v1 + u2v2 .
Similarly, for ~u = hu1 , u2, u3 i, ~v = hv1 , v2 , v3 i,
~u ~v = u1 v1 + u2 v2 + u3 v3 ,
or, generally, for ~u = hu1 , u2 , . . . , un i, ~v = hv1 , v2 , . . . , vn i,
~u ~v = u1 v1 + u2 v2 + + un vn .
Notice that the length of a vector ~v can be expressed as

||~v|| = ~v ~v.
The relation between the dot product and the Euclidean geometric notion of
angle is the subject of the Theorem below.

2.2 Dot Product

Theorem 1 Let ~u, ~v be nonzero vectors in 2-space or 3-space3 , and let be the
angle between ~u and ~v . Then

~u ~v = ||~u||||~v|| cos ,

i.e.

cos =

~
u~
v
.
||~
u||||~
v||

Proof: We prove the case that ~u ~v are 2-space vectors. The 3-space case can be
proved similarly.
As in the diagram, we can use
~u and ~v to form the triangle
OP Q, where ~u = hu1 , u2i, ~v = hv1 , v2 i,

and OP = ~u, OQ = ~v . Note that


the length of OP is ||~u||,
that of OQ is ||~v|| and

the length of P Q is ||P Q|| = ||~v ~u||

since P Q = hv1 u1 , v2 u2 i = ~v ~u.


The law of cosines applied to the triangle
OP Q gives

||~v ~u||2 = ||~u||2 + ||~v||2 2||~u||||~v|| cos

which is equivalent to


1
||~u||2 + ||~v||2 ||~v ~u||2
2


1 2
u1 + u22 + v12 + v22 (v1 u1 )2 + (v2 u2 )2
=
2
= u1 v1 + u2 v2

||~u||||~v|| cos =

= ~u ~v
i.e.
~u ~v = ||~u||||~v|| cos .
2
Theorem 1 shows that dot product can be used to calculate the angle between
two vectors. In particular, two non-zero vectors ~u, ~v are perpendicular if and only
if ~u ~v = 0, i.e. cos = 0.
Another consequence of Theorem 1 is the important Cauchy-Schwarz inequality
|~u ~v| ||~u||||~v||
3

In higher dimensional spaces the formula cos =


angle.

u
~ ~
v
||~
u||||~
v||

can be used to define the notion of

2.2 Dot Product

with equality occuring only if the two vectors are parallel or one of them is the zero
vector.
Example 1. Let P1 = (1, 1, 1), P2 = (3, 0, 2) and P3 = (2, 2, 3). Find the angle

between P1 P2 and P1 P3 .
Solution: Let denote the angle. Then, by Theorem 1,

P1 P2 P1 P3
cos =
||P1 P2 ||||P1P3 ||

We have P1 P2

P1 P3

P1 P2 P1 P3

||P1P2 ||

||P1P3 ||

= h3 1, 0 1, 2 1i = h2, 1, 1i

= h2 1, 2 1, 3 1i = h1, 1, 2i

= 2 1 + (1) 1 + 1 2 = 3
p

=
22 + (1)2 + 12 = 6

=
1 2 + 12 + 22 = 6

Hence

1
3
cos = = , = 60o (or )
2
3
6 6
2
Dot product has the usual arithmetic properties which we list below, the proof
follows from the definition of dot product directly, and therefore will not be provided.
You are encouraged to prove some of them, at least (d).
If ~u, ~v, and w
~ are vectors and k is a scalar, then

(a) ~u ~v = ~v ~u
(b) ~u (~v + w)
~ = ~u ~v + ~u w
~
(c) k(~u ~v ) = (k~u) ~v = ~u (k~v)
(d) ~v ~v = ||~v||2 0 (and equality holds only for ~v = ~0).
Property (a) is called symmetry, (b) and (c) together bilinearity and (d) positivity. In a more abstract setting these properties are used to define dot products
in arbitrary vector spaces. This concept will be developed in Pmth213.

2.3 Orthogonal Projections

2.3

Orthogonal Projections

Let ~u and ~b be two vectors in 2-space or 3-space. Then the vector w


~ formed as in
~
the diagram below is called the orthogonal projection of ~u on b, and is denoted
by proj~b ~u
u

If the angle between ~u and ~b is less than 90 , i.e.


direction of ~b. Therefore proj~b ~u has the form

,
2

then proj~b ~u is in the

proj~b ~u = k~b for some scalar k > 0.


Using the definition, we find that the length of proj~b ~u is
||~u|| cos = ||~u||
=

~u ~b

||~u|| ||~b||

(by Theorem 1)

~u ~b
.
||~b||

On the other hand, || proj~b ~u|| = ||k~b|| = k||~b||. Therefore


~u ~b
,
k||~b|| =
||~b||

that is k =

~u ~b
.
||~b||2

Substituting back, we obtain


Theorem 2

proj~b ~u =

~u ~b ~
b
||~b||2

The above formula is also true if is greater than 90 . Please check this by
modifying the above proof.
Let us now look at some of the uses of this formula.
By definition, the distance between two sets P and Q in 2- or 3-space is the
infimum of all distances of a point P P and Q Q, i.e., roughly speaking, the

10

2.3 Orthogonal Projections

distance between the two points in P and Q that are closest to each other in the
respective sets:
dist(P, Q) = inf ||P Q||.
P P,QQ

Example 2. Find a formula for the distance D between the point P (x0 , y0 ) and
the line Ax + By + C = 0.
Solution: Let us use the graph at the
right to help with the argument. The distance from P to an arbitrary point Q on
the line is the hypotenuse of a right triangle with one leg being the distance from
P to the orthogonal projection (say Q )
and the other being the distance between
Q and Q . From ||P Q|| ||P Q|| we see
that the infimum of distances ||P Q|| is attained for Q = Q . Therefore we need to
find the orthogonal projection of P on the
line.

y
n

P
Q
x
ax+by+c=0

Let Q = (x1 , y1 ) be any point on the line (i.e. Ax1 + By1 + C = 0) and position
~n so that Q is its initial point. Then

QP ~n
D = || proj~n QP || = ||
~n|| (using Theorem 2)
||~n||2

QP ~n


=
||~n|| (using ||k~v|| = |k|||~v||)
||~n||2

|QP ~n|
=
||~n||

But QP = hx0 x1 , y0 y1 i, ~n = hA, Bi. Hence

QP ~n = A(x0 x1 ) + B(y0 y1 )
= Ax0 + By0 Ax1 By1

= Ax0 + By0 + C (using Ax1 + By1 + C = 0),

A2 + B 2 and
||~n|| =

|Ax0 + By0 + C|
|QP
n|

=
D =

|| n ||
A2 + B 2

Note: The point Q is introduced just for an intermediate step, it does not appear
in the final formula.

11

2.4 Cross Product

Notice that the distance of a point P (x, y) to the y axis is just |x| and the distance
to the x-axis is just |y|. This can be verified by the formula with A = 0, B = 1, C = 0
and A = 1, B = 0, C = 0, respectively.

2.4

Cross Product

For vectors in 3-space only, another kind of product, called the cross product, is
defined. If ~uhu1, u2 , u3 i and ~v = hv1 , v2 , v3 i, then the cross product ~u ~v is a
vector given by


u2
~u ~v =
v2
~i


= u1

v1

u3
v3
~j
u2
v2











~i u1 u3 ~j + u1 u2 ~k


u1 v2

v1 v3
~k

u3

v3

Note that ~u ~v is a number, but ~u ~v is a vector. The following theorem shows


some of the properties of cross product are similar to dot product, but many are
different.
Theorem 3. Cross product has the following properties:

(1) ~u ~v is orthogonal to both ~u and ~v , i.e.


~u (~u ~v ) = 0, ~v (~u ~v ) = 0.
(2) ||~u ~v || = ||~u|| ||~v|| sin
(compare ~u ~v = ||~u||||~v|| cos )
Notice that this is the area of the parallelogram spanned by the vectors ~u and
~v.
It follows ||~u ~v || ||~u|| ||~v|| where the equality holds if and only if ~u ~v .
(3) (a) ~u ~v = (~v ~u) (compare ~u ~v = ~v ~u)
(b)
(c)
(d)
(e)

~u (~v + w)
~
(~u + ~v ) w
~
k(~u ~v)
~u ~0

=
=
=
=

(~u ~v ) + (~u w)
~
(~u w)
~ + (~v w)
~
(k~u) ~v = ~u (k~v )
~0 ~u = ~0

(f) ~u ~u = ~0 (compare ~u ~u = ||~u||2 )

similar to dot product

12

2.4 Cross Product

(4) If ~a = ha1 , a2 , a3 i, ~b = hb1 , b2 , b3 i and ~c = hc1 , c2 , c3 i, then




a1 a2 a3


~a (~b ~c) = b1 b2 b3
c c c
1
2
3

(5) |~a (~b ~c)| is the volume of the parallelepiped spanned on the vectors ~a, ~b and
~c.

Proof: We only prove (4) and (1).


We prove (4) first and then use (4) to deduce (1).
Proof of (4):

Hence




~b ~c =




=


~i ~j ~k

b1 b2 b3

c1 c2 c3





b2 b3 ~ b1 b3 ~ b1 b2 ~
k
i
j+
c2 c3
c1 c3
c1 c2







b1 b2
b1 b3
b2 b3
~






+ a3
a2
~a (b ~c) = a1
c1 c2
c1 c3
c2 c3


a1 a2 a3


= b1 b2 b3
c c c
1
2
3

Proof of (1) (using (4)):



u1 u2 u3


~u (~u ~v ) = u1 u2 u3 = 0,
v v v
1
2
3

because the first and second rows are the same.

Anda mungkin juga menyukai