Vectors Homework
Vectors Homework
b2y
b1x = b1y =
1
θ 1 b1y b2x = b2y =
θ
b1 x
Copyright
c 1992-2009 by Paul Mitiguy 273 Homework 2
2.6 Calculating vector dot products with bases.
The figure to the right shows a right-handed (dextral) set of orthogonal
unit vectors nx , ny , nz . The vectors u, v, w are defined as:
u = 2 nx + 3 ny + 4 nz
ny
v = x nx + y ny + z nz
nx
w = 5 nx − 6 ny + 7 nz nz
(a) Use the distributive law for dot products to write u · v in terms of nx · nx , nx · ny , nx · nz , etc.
Result:
u · v = 2 x nx · nx + 2 y nx · ny + 2 z nx · nz
+ + +
+ + +
a = ax nx + ay ny + az nz
b = bx nx + by ny + bz nz
a · b = ax bx + ay by + az bz
Copyright
c 1992-2009 by Paul Mitiguy 274 Homework 2
2.7 Definition of a dot product and its use for calculating angles.
(c) Using equation (2.1), calculate the unit vector u directed from A to C in terms of n1 , n2 , n3 .
Next, find the unit vector v directed from A to D in terms of n1 , n2 , n3 .
Result:
3 n1 − 2 n2
u = √ v =
13
(d) Calculate BAC, the angle between line AB and line AC.
Next, calculate CAD, the angle between line AC and line AD.
Result:
◦
BAC = CAD = 47.97◦
Copyright
c 1992-2009 by Paul Mitiguy 275 Homework 2
2.8 Dot products and distance calculations.
LC
The figure to the right shows a
crane whose cab A supports a
LB
boom B that swings a wrecking θC
ball Co . To prevent the wreck- B
Co
ing ball from accidently destroy-
ing nearby cars, the distance be- N
tween the nearest car, point No , θB
and the tip of the boom, point
BC, must be controlled. x
A
(a) Express the position vector of BC from No in terms of x, LB , and the unit vectors nx , and bx .
Result:
r BC/No = +
(b) Using the distributive property for dot-multiplication of vectors, i.e.,
(a + b) · (c + d) = a · c + a · d + b · c + b · d
(d) Using your previous two results, rewrite r BC/No · r BC/No in terms of x, LB , and θB .
Result:
r BC/No · r BC/No =
(e) Using equation (2.3) to calculate the magnitude of r BC/No , express the distance from No to BC
in terms of x, LB , and θB , and calculate its value when x=20, LB =10, and θB =30◦ .
Result:
BC/No
r = = 29.1
(f) Two colleagues are confused by your use of mixed-bases vectors (i.e., r BC/No = x nx + LB bx ),
and ask you to verify the position vector of B from No can be expressed in the uniform-basis
as
shown below. Use this uniform-basis expression to verify your previous result for r BC/No . Note:
This uniform-basis approach necessitates the simplifying trigonometric identity sin2 (θB ) + cos2 (θB ) = 1.
Result:
r BC/No = [x + LB cos(θB )] nx + LB sin(θB ) ny
(g) Optional∗∗ : Calculate the distance from No to Co in terms of x, LB , LC , θB , and θC .
Result:
Co /No
r =
Copyright
c 1992-2009 by Paul Mitiguy 276 Homework 2
2.9 Cross products and determinants.
Copyright
c 1992-2009 by Paul Mitiguy 277 Homework 2
2.11 Cross products and area calculations.
One reason that triangles are important is that complex planar objects can be decomposed into
triangles. For example, the polygon B in the figure below can be decomposed into triangles. Knowing
the area of two-dimensional objects is helpful in various professions. For example, area measurements
are necessary in calculating the acreage and costs associated with building and farming. Knowing
the mass properties of a polygon is helpful in determining the motion of two-dimensional objects.
B7 B5 B4
r B1 /B0 = 2.0 bx + 2.0 by
B8 B6 r B2 /B0 = 0.5 bx + 2.5 by
B3
r B3 /B0 = 3.0 bx + 4.0 by
r B4 /B0 = 0.2 bx + 6.0 by
B2
Bc
r B5 /B0 = -0.5 bx + 7.0 by
B
B1 r B6 /B0 = -1.0 bx + 5.0 by
by r B7 /B0 = -2.0 bx + 7.0 by
Copyright
c 1992-2009 by Paul Mitiguy 278 Homework 2
2.12 Scalar triple product with bases.
The figure to the right shows a right-handed set of orthogonal unit
vectors nx , ny , nz . The vectors u, v, w are defined as:
u = 2 nx + 3 ny + 4 nz
ny
v = x nx + y ny + z nz nx
w = 5 nx − 6 ny + 7 nz nz
Calculate u × v · u, u × v · w, and u · v × w.
Note: Although the order of operations in u × v · u is unambiguous, parentheses may clarify your work.
Result:
u×v· u =
u×v· w =
u· v×w = 27 z − 45 x − 6 y
a = ax nx + ay ny + az nz
Given right-handed orthogonal unit vectors nx , ny , nz and
b = bx nx + by ny + bz nz
three arbitrary vectors a, b, and c that are expressed in terms
of nx , ny , nz as shown to the right, prove that calculating c = cx nx + cy ny + cz nz
a · (b × c) happens to be equal to the determinant of the matrix
ax ay az
shown to the right.
a · b × c = bx by bz
cx cy cz
3 nx − 4 ny ny
3 nx − 4 ny + 12 nz
nx
c nx
nz
Copyright
c 1992-2009 by Paul Mitiguy 279 Homework 2
2.15 Getting started with Autolev.
Go to http://www.stanford.edu/class/me331b and click on Getting Started. Follow the directions
up to Vector Operations. Print out and submit your firstDemo.al file with your homework.
Continue through Vector Operations and also submit your vectorDemo.al.
ny u = 2 nx + 3 ny + 4 nz
v = x nx + y ny + z nz
nz nx w = 5 nx − 6 ny + 7 nz
Use the Autolev commands Cross, Dot, and UnitVector to calculate the following quantities. Submit
your work via the printed Autolev files vectorOperations.al and vectorOperations.all.
Note: Assign each output quantity in Autolev to a scalar or vector name, e.g., type:
a = Dot(u>,v>); b = Dot(u>,w>); c = Dot(v>,w>); d> = Cross(u>,v>)
Copyright
c 1992-2009 by Paul Mitiguy 280 Homework 2
2.17 More vector operations with Autolev.
Dot-products and cross-products are fundamental vector operations and are useful for kinematics
(motion), mass-distribution calculations, kinetics (forces), statics, and dynamics. Use the Autolev
commands Dot, Cross, Magnitude, UnitVector, and AngleBetweenVectors to perform the following
operations and pass in the file VectorOperationsB.al.
Note: Assign each output quantity in Autolev to a scalar or vector name, e.g., type:
a> = 10*v>; b> = v> / 10; c> = v> + w>; d> = v> - w>
The figure to the left shows a right-handed set of orthogonal unit vectors
nx , ny , nz . Given below are two vectors v and w.
ny
v = 2 nx + 3 ny + 4 nz
nx w = 5 nx − 6 ny + 7 nz
nz
10 ∗ v =
v/10 =
v +w =
v −w =
v· w =
v×w =
w×v =
|w| =
|v| =
v2 =
v3 =
2 nx + 3 ny + 4 nz
UnitVector (v) = √
29
= 0.3714 nx + 0.5571 ny + 0.7428 nz
◦
(v, w) = radians or
v ∗ w = 10 nx nx − 12 nx ny + 14 nx nz
+
+
w ∗ v = 10 nx nx + 15 nx ny + 20 nx nz
−
+
Copyright
c 1992-2009 by Paul Mitiguy 281 Homework 2
2.18 Locating a microphone (2D). Also see Homework 1.20.
A microphone Q is attached to two pegs B and C by two cables. The point of this practical problem
is to determine the distance between Q and point No knowing the peg locations, cable lengths, and
the fact that B, C, Q, and No all lie in the same plane. Introduce whatever identifiers facilitate
your work and try to do the problem first using Euclidean geometry - and then try vectors.
Note: There are at two “mathematical” answers to this problem, but one is above the ceiling and requires the cables
to be in compression.
15
B C
9 Quantity Value
8
Q Distance from B to C 15 m
8 Distance from No to B 8m
Length of cable joining B and Q 9m
ny Length of cable joining C and Q 8m
Distance between No and Q 9.01 m
No nx
1
Hint: See Section 2.10.4 and introduce whatever identifiers facilitate your work. Note: Section 1.11.1 shows how to solve
nonlinear algebraic equations. This problem can also be solved “by-hand”.
Copyright
c 1992-2009 by Paul Mitiguy 282 Homework 2