Math1020 Sgta Week2 Solns
Math1020 Sgta Week2 Solns
Solution
(i) u ⋅ v = 21 − 48 + 25 − 6 + 9 = 1.
(ii) u and v are not orthogonal—their inner product is not zero.
(iii) ||v|| = √32 + (−12)2 + 52 + 62 + 92 = √295.
2. Let
2 1
3 1 1 2 3
𝐴 = [1 −1] , 𝐵=[ ], 𝐶=[ ]
0 −1 4 5 6
4 0
Determine which of the following matrix expressions are defined and, for those that are, calculate the
result.
Solution
3. (a) Write (1, 3, −1) as a linear combination of (1, 0, 0), (2, −2, 1) and (2, 0, 4).
(b) Write (0, −26, −9) as a linear combination of (5, 3, 7) and (2, −4, 1). Show that (1, 3, 5) cannot be
written as a linear combination of these two vectors.
Solution
(a) Let 𝑥, 𝑦, 𝑧 ∈ ℝ such that (1, 3, −1) = 𝑥(1, 0, 0) + 𝑦(2, −2, 1) + 𝑧(2, 0, 4). Writing this as an
augmented system,
1 2 2 1
⎡ ⎤
⎢0 −2 0 3 ⎥ 𝑅2 → − 1 𝑅2
⎢ ⎥ 2
⎣0 1 4 −1⎦
1 2 2 1 𝑅 → 𝑅1 − 2𝑅2
⎡ ⎤ 1
⎢0 1 0 − 3 ⎥
⎢ 2⎥
⎢ ⎥
⎣0 1 4 −1 ⎦ 𝑅3 → 𝑅3 − 𝑅2
1 0 2 4
⎡ ⎤
⎢0 1 0 − 3 ⎥
⎢ 2⎥
⎢ 1 ⎥
⎣0 0 4 2 ⎦
1 1 3 15
so 4𝑧 = or 𝑧 = , 𝑦 = − and 𝑥 = 4 − 2𝑧 = , and therefore
2 8 2 4
15 3 1
(1, 3, −1) = (1, 0, 0) − (2, −2, 1) + (2, 0, 4).
4 2 8
(b) Let 𝑥, 𝑦, 𝑧 ∈ ℝ such that (0, −26, −9) = 𝑥(5, 3, 7) + 𝑦(2, −4, 1). Writing this as an augmented
system,
1
5 2 0 𝑅 → 𝑅1
⎡ ⎤ 1 2
⎢3 −4 −26⎥
⎢ ⎥
⎣7 1 −9 ⎦
1 2/5 0
⎡ ⎤
⎢3 −4 −26⎥ 𝑅2 → 𝑅2 − 3𝑅1
⎢ ⎥
⎣7 1 −9 ⎦ 𝑅3 → 𝑅3 − 7𝑅1
1 2/5 0
⎡ ⎤
⎢0 −26/5 −26⎥ 𝑅2 → − 5 𝑅2
⎢ ⎥ 26
5
⎣0 −9/5 −9 ⎦ 𝑅3 → − 9 𝑅3
2
1 2/5 0 𝑅1 → 𝑅1 − 𝑅2
⎡ ⎤ 5
⎢0 1 5⎥
⎢ ⎥
⎣0 1 5⎦ 𝑅3 → 𝑅3 − 𝑅2
1 0 −2
⎡ ⎤
⎢0 1 5 ⎥
⎢ ⎥
⎣0 0 0 ⎦
So 𝑥 = −2 and 𝑦 = 5 and we can write (0, −26, −9) = −2(5, 3, 7) + 5(2, −4, 1)
With the vector (1, 3, 5), the reduced row echelon form of the augmented matrix
5 2 1 1 0 0
[3 −4 3] is [0 1 0]
7 1 5 0 0 1
This is inconsistent (the last row represents the “equation” 0 = 1) so the system has no solu-
tions, and therefore (1, 3, 5) cannot be written as a linear combination of (5, 3, 7) and (2, −4, 1).
2
1 2 −3 1
𝑥
4. Let 𝐴 = [1 −1], b1 = [ 3], b2 = [1], x = [ 1 ].
𝑥2
3 1 1 0
(a) Determine if each of the following systems of equations
(i) 𝐴x = b1 (ii) 𝐴x = b2
is consistent.
(b) Determine whether the vectors (−3, 3, 1) and (1, 1, 0) are in the span of the set
𝑆 = {(1, 1, 3), (2, −1, 1)}.
Solution
(a) We can deal with b1 and b2 simultaneously, via the following augmented matrix (both vectors
on the right hand side).
1 2 −3 1
⎡ ⎤
⎢1 −1 3 1⎥ 𝑅2 → 𝑅2 − 𝑅1
⎢ ⎥
⎣3 1 1 0⎦ 𝑅3 → 𝑅3 − 3𝑅1
1 2 −3 1
⎡ ⎤ 1
⎢0 −3 6 0 ⎥ 𝑅2 → − 𝑅2
⎢ ⎥ 3
⎣0 −5 10 −3⎦
1 2 −3 1 𝑅 → 𝑅1 − 2𝑅2
⎡ ⎤ 1
⎢0 1 −2 0 ⎥
⎢ ⎥
⎣0 −5 10 −3⎦ 𝑅3 → 𝑅3 + 5𝑅2
1 0 1 1
⎡ ⎤
⎢0 1 −2 0 ⎥
⎢ ⎥
⎣0 0 0 −3⎦
Solution
1 1 𝑎
[ ]
1 −2 𝑏 𝑅2 → 𝑅2 − 𝑅1
1 1 𝑎
[ ] 1
0 −3 𝑏 − 𝑎 𝑅2 → − 𝑅2
3
1 1 𝑎 𝑅1 → 𝑅1 − 𝑅2
[ ]
0 1 (𝑎 − 𝑏)/3
1 0 (2𝑎 + 𝑏)/3
[ ]
0 1 (𝑎 − 𝑏)/3
3
The system has a solution for all 𝑎 and 𝑏, so {u, v} spans ℝ2 .
6. For each of the elementary row operations below, find the elementary matrix 𝐸 such that 𝐸𝐴 is the
result of the row operation on the 3 × 5 matrix 𝐴,
(i) Multiplying the second row by the nonzero scalar 𝑎.
(ii) Exchanging the second and third rows.
(iii) Adding 𝑎 times the first row to the third row.
Solution
1 0 0
(i) [0 𝑎 0]
0 0 1
1 0 0
(ii) [0 0 1]
0 1 0
1 0 0
(iii) [ 0 1 0]
𝑎 0 1
7. What is the value of 𝑎 if (2, 3, 𝑎) is a linear combination of the vectors (1, 1, 0), (0, 1, −1)?
Solution
Solution
(a) Let 𝑥, 𝑦, 𝑧 ∈ ℝ such that (1, −3, −7) = 𝑥(1, −3, −1) + 𝑦(2, 0, −2) + 𝑧(1, 0, −5). Writing this as
an augmented system,
1 2 1 1
⎡ ⎤
⎢−3 0 0 −3⎥ 𝑅2 → 𝑅2 + 3𝑅1
⎢ ⎥
⎣−1 −2 −5 −7⎦ 𝑅3 → 𝑅3 + 𝑅1
1 2 1 1
⎡ ⎤ 1
⎢0 6 3 0 ⎥ 𝑅2 → 𝑅2
⎢ ⎥ 6 1
⎣0 0 −4 −6⎦ 𝑅3 → − 𝑅3 4
1 2 1 1 𝑅 → 𝑅1 − 2𝑅2
⎡ ⎤ 1
⎢0 1 1/2 0 ⎥ 𝑅2 → 𝑅2 − 1 𝑅3
⎢ ⎥ 2
⎣ 0 0 1 3/2 ⎦
1 0 0 1
⎡ ⎤
⎢0 1 0 −3/4⎥
⎢ ⎥
⎣0 0 1 3/2 ⎦
4
so 𝑥 = 1, 𝑦 = −3/4 and 𝑧 = 3/2, and therefore
3 3
(1, −3, −7) = (1, −3, −1) − (2, 0, −2) + (1, 0, −5).
4 2
(b) Yes, the system has a solution for any right-hand side.
(c) Let 𝑥, 𝑦 ∈ ℝ such that (−2, 0, 1) = 𝑥(1, −3, −1) + 𝑦(2, 0, −2). Writing this as an augmented
system,
1 2 −2
⎡ ⎤
⎢−3 0 0 ⎥ 𝑅2 → 𝑅2 + 3𝑅1
⎢ ⎥
⎣−1 −2 1 ⎦ 𝑅3 → 𝑅3 + 𝑅1
1 2 −2
⎡ ⎤
⎢0 6 −6⎥
⎢ ⎥
⎣0 0 −1⎦
This system is not consistent so (−2, 0, 1) cannot be written as a linear combination of (1, −3, −1)
and (2, 0, −2).
(0, 0, 0) = 0(1, −3, −1) + 0(2, 0, −2) can be written as a linear combination of the vectors.
1 −1 5 −1 3 𝑥1
9. Let 𝐴 = [0 1 −3], b1 = [ 2], b2 = [−2], x = [𝑥2 ].
2 1 1 1 0 𝑥3
(a) Determine if the system of equations
(i) 𝐴x = b1 (ii) 𝐴x = b2
is consistent.
(b) Determine whether the vectors (−1, 2, 1) and (3, −2, 0) are in the span of the set
Solution
(a) Once again, we can deal with b1 and b2 at the same time.
1 −1 5 −1 3
⎡ ⎤
⎢0 1 −3 2 −2⎥
⎢ ⎥
⎣2 1 1 1 0 ⎦ 𝑅3 → 𝑅3 − 2𝑅1
1 −1 5 −1 3 𝑅 → 𝑅1 + 𝑅2
⎡ ⎤ 1
⎢0 1 −3 2 −2⎥
⎢ ⎥
⎣0 3 −9 3 −6⎦ 𝑅3 → 𝑅3 − 3𝑅2
1 0 2 1 1
⎡ ⎤
⎢0 1 −3 2 −2⎥
⎢ ⎥
⎣0 0 0 −3 0 ⎦
5
10. (a) Write down the 3 × 3 elementary matrix that corresponds to the row operation 𝑅2 = 𝑅2 − 3𝑅1 .
(b) Write down the 4 × 4 elementary matrix that corresponds to the row operation 𝑅1 ⟷ 𝑅4 .
(c) Write down the row operation that corresponds to the elementary matrix
1 0 0
[−2 1 0] .
0 0 1
Solution
1 0 0
(a) [−3 1 0]
0 0 1
0 0 0 1
⎡ ⎤
0 1 0 0⎥
(b) ⎢
⎢0 0 1 0 ⎥
⎢ ⎥
⎣1 0 0 0 ⎦
(c) 𝑅2 = 𝑅2 − 2𝑅1
11. Determine 𝐸, a product of elementary matrices which when premultiplying 𝐴 performs Gauss-Jordan
1 −27 10 −5
pivoting on the (2, 2) entry of 𝐴 where 𝐴 = [0 12 −6 −21].
0 −6 −11 18
Check 𝐸 by computing 𝐸𝐴.
Solution
1 −27 10 −5
1
[0 12 −6 −21] 𝑅2 → 𝑅2 elementary matrix 𝐸1
12
0 −6 −11 18
1 −27 10 −5 𝑅1 → 𝑅1 + 27𝑅2 elementary matrix 𝐸2
[0 1 −1/2 −7/4]
0 −6 −11 18 𝑅3 → 𝑅3 + 6𝑅2 elementary matrix 𝐸3
1 0 −7/2 −209/4
[0 1 −1/2 −7/4 ]
0 0 −14 15/2
1 0 0 1 27 0 1 0 0
𝐸1 = [0 1/12 0] 𝐸2 = [0 1 0] 𝐸3 = [0 1 0]
0 0 1 0 0 1 0 6 1
6
so
1 0 0 1 27 0 1 0 0
𝐸 = 𝐸3 𝐸2 𝐸1 = [0 1 0] [0 1 0] [0 1/12 0]
0 6 1 0 0 1 0 0 1
1 27 0 1 0 0
= [0 1 0] [0 1/12 0]
0 6 1 0 0 1
1 27/12 0
= [0 1/12 0]
0 6/12 1
Check
1 27/12 0 1 −27 10 −5 1 0 −7/2 −209/4
𝐸𝐴 = [0 1/12 0] [0 12 −6 −21] = [0 1 −1/2 −7/4 ]
0 6/12 1 0 −6 −11 18 0 0 −14 15/2
Additional problems
These are problems that students who would like something a little more challenging can try at home after the
SGTA. Your SGTA instructor may discuss some of these problems in the SGTA if time permits.
Solution
(a)
𝑛 𝑛
‖x + y‖ + ‖x − y‖ = ∑ (𝑥𝑖 + 𝑦 𝑖 )2 + ∑ (𝑥𝑖 − 𝑦 𝑖 )2
2 2
𝑖=1 𝑖=1
𝑛 𝑛
= ∑ (𝑥𝑖2 + 2𝑥𝑖 𝑦 𝑖 + 𝑦2𝑖 ) + ∑ (𝑥𝑖2 − 2𝑥𝑖 𝑦 𝑖 + 𝑦2𝑖 )
𝑖=1 𝑖=1
𝑛 𝑛
= 2 ∑ 𝑥𝑖 + 2 ∑ 𝑦2𝑖
2
𝑖=1 𝑖=1
2 2
= 2 (‖x‖ + ‖y‖ )
(b)
𝑛
2
‖x − y‖2 = ∑ (𝑥𝑖 − 𝑦 𝑖 )
𝑖=1
𝑛
= ∑ (𝑥𝑖2 − 2𝑥𝑖 𝑦 𝑖 + 𝑦2𝑖 )
𝑖=1
𝑛 𝑛 𝑛
= ∑ 𝑥𝑖2 − 2 ∑ 𝑥𝑖 𝑦 𝑖 + ∑ 𝑦2𝑖
𝑖=1 𝑖=1 𝑖=1
2 2
= ‖x‖ − 2(x ⋅ y) + ‖y‖
7
If x and y are orthogonal then x ⋅ y = 0 so ‖x − y‖ = ‖x‖2 + ‖y‖2 which is Pythagoras in ℝ𝑛
since x − y is the hypotenuse joining points defined by x and y.
In general though, x ⋅ y = ‖x‖‖y‖ cos 𝜃 where 𝜃 is the angle between the vectors, so ‖x − y‖ =
‖x‖2 + ‖y‖2 − 2‖x‖‖y‖ cos 𝜃, which is the cosine rule.
13. Let u = (2, 5, 3), v = (1, 1, 1) and w = (3, 15, 7). Explain clearly why span{u, v, w} =span{u, v}.
Solution
14. Answer the following questions, giving reasons for your answers.
(a) Does any set of three vectors in ℝ3 span ℝ3 ?
(b) Can a set of three vectors in ℝ2 span ℝ2 ?
Solution
(a) No. Consider (1, 0, 0), (2, 0, 0), and (3, 0, 0).
(b) Yes. For example {(1, 0), (0, 1), (1, 1)} spans ℝ2 .