Math 1C: Calculus III
Part 1: Multidimensional Differential Calculus
Lecture 3: The Dot Product
©Jeffrey A. Anderson

Key Terms List: Briggs Section 11.3
□ Cosine formula for dot product (p. 782)
□ Orthogonal vectors (p. 782)
□ The dot product between orthogonal vectors (p.782)
□ The component form of the dot product (p. 783)
□ Proof of cosine formula for dot product (Lesson 3: Jeff’s Handwritten Notes)
□ Algebraic Properties of Dot Product (p. 784)
	□ Length via dot product: (OverVector[a])·(OverVector[a]) = ||(OverVector[a])|(Subscript[|, 2]^2)
	□ Commutativity of dot product: (OverVector[a])·(OverVector[b]) = (OverVector[b])·(OverVector[a]) 
	□ Linearity of dot product: (OverVector[a])·((OverVector[b]) +(OverVector[c])) = (OverVector[a])·(OverVector[b]) +(OverVector[a])·(OverVector[c])
	□ Homogeneity of dot products: α((OverVector[a])·(OverVector[b])) = (α (OverVector[a]))·(OverVector[b]) = (OverVector[a])·(α (OverVector[b])) for α∈ ℝ
	□ Dot product with zero is always zero: (OverVector[0])·(OverVector[a]) = 0
□ Projection of (OverVector[u]) onto (OverVector[v]) (p. 786)
□ Scalar projection of (OverVector[u]) onto (OverVector[v]): the component of (OverVector[u]) along (OverVector[v]) (p. 786)

Section 9.3: Dot Product

Example 11.3.3 p. 786: Orthogonal Projections in (ℝ^2)

o = {0,0};
u = {4,1};
v = {3,4};
Show[
	Graphics[{PointSize[.03],Point[{o,u,v}],Axes->True}],
	Graphics[{Thickness[.008],Arrow[{{o,v}, {o,u}}],Axes->True}],
	Axes->True,
	AspectRatio->Automatic,
	TicksStyle-> Directive[FontSize->20],
	PlotRange-> {{-1,6},{-1,6}}
](*end: Show command*)

Calculating Dot Products

Let’s begin our discussion of how to use Mathematica to calculate dot product by illustrating the general definition of the dot product in (ℝ^2). We begin by defining two vectors (OverVector[v]), (OverVector[u]) ∈ (ℝ^2). To define the coordinates of these vectors, we use the period symbol as follows:

u = {4,1};
v = {3,4};
v.u

Notice this is the period on the keyboard. Be careful with this operator. Mathematica has overloaded the meaning and it can be used to solve a variety of problems. Today, we discuss just one of the uses (the dot product between vectors). Notice, we can also use the “Dot” command:

u = {4,1};
v = {3,4};
Dot[v,u]

Now that we’ve seen how the notation work, let’s use this to our advantage:

Calculating Length of Vector

u = {4,1};
v = {3,4};

Norm[u]

Projections of One Vector onto Another Vector

v = {4,1};
u = {3,4};

projv[x_]:=((Dot[v,x])/(Norm[v]))*(v/(Norm[v]))

proju[x_]:=((Dot[u,x])/(Norm[u]))*(u/(Norm[u]))

o = {0,0};
u = {4,1};
v = {3,4};
Show[
	Graphics[{PointSize[.03],Point[{o,u,v}],Axes->True}],
	Graphics[{Thickness[.008],Arrow[{{o,v}, {o,u}}],Axes->True}],
	Graphics[{Red,PointSize[.03],Point[{N[projv[u]]}],Axes->True}],
	Graphics[{Red,Thickness[.010],Arrow[{o,N[projv[u]]}],Axes->True}],
	Graphics[{Blue,Thickness[.003], Dashed,Line[{u,N[projv[u]]}],Axes->True}],
	Axes->True,
	AspectRatio->Automatic,
	TicksStyle-> Directive[FontSize->20],
	PlotRange-> {{-1,6},{-1,6}}
](*end: Show command*)