MATH 133 Linear Algebra and Geometry • McGill University, Montreal
Corrected exercises: diagonalization and its applications (MATH 133)
This is the corrected exercise set for the diagonalization chapter of MATH 133, Linear Algebra and Geometry, at McGill University: Nicholson sections 3.3, 3.4 and 5.5.It covers the definition P−1AP=D, the criterion of n independent eigenvectors, algebraic and geometric multiplicities, powers An=PDnP−1, similar matrices and their invariants, and the three applications the course examines: linear dynamical systems, two-state Markov chains and linear recurrences.
What the set covers, the traps it targets
It covers the definition P−1AP=D, the criterion of n independent eigenvectors, algebraic and geometric multiplicities, powers An=PDnP−1, similar matrices and their invariants, and the three applications the course examines: linear dynamical systems, two-state Markov chains and linear recurrences.
No calculator anywhere: every characteristic polynomial factors by hand.
The thread running through the whole set: diagonalizable is a COUNTING question. Are there n independent eigenvectors or not? A repeated eigenvalue is not a verdict, the dimension of its eigenspace is, and it costs one rank. Once P is built, every application is read in the eigenvector axes, where A does nothing but stretch each axis by its eigenvalue: powers, the long run of a population, the steady state of a chain and the closed formula of a recurrence are the same computation four times.
The traps named explicitly in the solutions: concluding "double root, so not diagonalizable" without computing a rank, taking one eigenvector per eigenvalue whatever the multiplicity, writing the eigenvalues of D in a different order from the columns of P, putting the eigenvectors in the rows, writing A=P−1DP, raising the entries of A to the power n, believing that shared invariants prove similarity, and quoting an eigenvector as a steady state without scaling it to the total.
•A is diagonalizable when P−1AP=D, with P invertible and D diagonal; then A=PDP−1.
•Criterion: n linearly independent eigenvectors. They are the COLUMNS of P, and the i-th diagonal entry of D is the eigenvalue of the i-th column.
•Geometric multiplicity dimEλ=n−rank(A−λI), and 1≤dimEλ≤ algebraic multiplicity. Diagonalizable if and only if they are equal for every eigenvalue.
•n distinct eigenvalues: diagonalizable. The converse is false (I is diagonal).
•An=PDnP−1 and Dn=diag(λ1n,…,λnn). If v0=c1u1+⋯+cnun in eigenvectors, Akv0=c1λ1ku1+⋯+cnλnkun.
•Similar matrices (B=P−1AP) share determinant, trace, rank, characteristic polynomial and eigenvalues. Sharing them does not prove similarity.
•A Markov matrix has columns adding up to 1, so 1 is an eigenvalue; the steady state is its eigenvector scaled to the total.
Part A: the basics (/50)
Exercise 1: One sign apart: a double eigenvalue decided by its eigenspace
10 answers to check
An n×n matrix is diagonalizable when it has n linearly independent eigenvectors. A repeated eigenvalue is the only place where that count can fall short, and it is exactly where students stop thinking and start guessing.
Consider A=31−1021012 and B=311021012. The two matrices differ by a single sign, in the bottom left corner.
a) Compute the characteristic polynomial of A by cofactor expansion along a well-chosen row, and give the eigenvalues with their algebraic multiplicities. Explain why B has exactly the same polynomial.
b) For the repeated eigenvalue of A, find the eigenspace: its dimension and a basis.
c) Do the same for B.
d) Decide which of A and B is diagonalizable. For the one that is, give P and D with P−1AP=D.
e) Explain why the simple eigenvalue λ=1 never needed a rank test, in either matrix.
Show the solution
Answers
a)det(A−λI)=(3−λ)2(1−λ) for both: λ=3 (algebraic multiplicity 2), λ=1 (multiplicity 1)
b)dimE3=2, basis (1,1,0), (−1,0,1)
c)dimE3=1, basis (0,1,1)
d)A is diagonalizable, P=110−10101−1, D=diag(3,3,1); B is not
Expand along row 1, which holds two zeros, so only one cofactor survives: det(A−λI)=(3−λ)det(2−λ112−λ)=(3−λ)((2−λ)2−1). The bracket is a difference of squares, (2−λ−1)(2−λ+1)=(1−λ)(3−λ), so the polynomial is (3−λ)2(1−λ): λ=3 with algebraic multiplicity 2 and λ=1 with multiplicity 1. For B the same expansion along row 1 deletes row 1 and column 1, and what remains is the SAME 2×2 block: the entry that changed sign sits in column 1, which the minor never sees. Two quick checks: the trace 3+2+2=7=3+3+1, and detA=3×(4−1)=9=3×3×1.
b)
A−3I=01−10−1101−1. The operation R3→R3+R2 turns row 3 into a zero row, so one pivot remains: rank 1, and the nullity is 3−1=2. The single equation x−y+z=0 leaves y and z free, x=y−z, so E3=span{(1,1,0),(−1,0,1)}. Check each one: A(1,1,0)=(3,3,0) and A(−1,0,1)=(−3,0,3). The geometric multiplicity is 2, equal to the algebraic one: the double root has kept a whole PLANE of eigenvectors.
c)
B−3I=0110−1101−1. Now R3→R3−R2 gives (0,2,−2), a second pivot: rank 2, nullity 1. The equations x−y+z=0 and y−z=0 give y=z and x=0, so E3=span{(0,1,1)}, and indeed B(0,1,1)=(0,3,3). The geometric multiplicity is 1, strictly less than 2: the eigenvalue is DEFECTIVE. Same polynomial, same eigenvalues, and one sign has cost a whole dimension of eigenvectors.
d)
For A, the eigenvalue 1: A−I=21−1011011 gives x=0 from R1, then y+z=0, so E1=span{(0,1,−1)}. Together with the basis of E3 that is 3 eigenvectors, and they are independent: detP=−2=0 for P=110−10101−1. So A is diagonalizable and P−1AP=D=diag(3,3,1), with the eigenvalues in the order of the columns. For B, the eigenspaces supply 1+1=2 independent eigenvectors, one short of 3: no invertible P can be built, and B is NOT diagonalizable. The verdict came from one rank, never from the polynomial.
e)
For every eigenvalue, 1≤ geometric multiplicity ≤ algebraic multiplicity: an eigenvalue always has at least one eigenvector, and it can never have more independent ones than its multiplicity as a root. Algebraic multiplicity 1 squeezes the geometric one to exactly 1, so a simple eigenvalue can never be the reason a matrix fails. On an exam, the rank test is spent on the repeated eigenvalues only; computing E1 is still needed, but to fill a column of P, not to decide anything.
Points are earned before the solution; after it, you can keep practising.
For you:
Tick the exercises you have done or want to review: a free account, no password, keeps your ticks and your right answers from one visit to the next, tells you which chapter to tackle next and lets you ask for the exercise you are missing. Create your space, an email is enough.
Exercise 2: A parameter decides, and it is not the one you expect
9 answers to check
Let A=200a201b−1, where a and b are real numbers.
The matrix is triangular, so its eigenvalues cost nothing. The whole question is what happens inside the eigenspace of the repeated one, and which of the two parameters can reach it.
a) Give the eigenvalues of A with their algebraic multiplicities, and justify in one line.
b) Find all values of a and b for which A is diagonalizable.
c) Take a=0 and b=3, so A=20002013−1. Find an invertible P and a diagonal D with P−1AP=D.
d) For which real k is C=(101k) diagonalizable?
e) From d), a student concludes: "a matrix is diagonalizable exactly when its eigenvalues are distinct". Give the counterexample that kills the word exactly, and state the correct criterion.
Show the solution
Answers
a)2 (algebraic multiplicity 2) and −1 (multiplicity 1), for all a, b
b)Diagonalizable if and only if a=0, whatever b
c)P=100010−1−33, D=diag(2,2,−1)
d)All k=1
e)I2: repeated eigenvalue, already diagonal. Criterion: geometric = algebraic multiplicity for every eigenvalue
a)
A−λI is still upper triangular, and the determinant of a triangular matrix is the product of its diagonal: det(A−λI)=(2−λ)2(−1−λ). So λ=2 with algebraic multiplicity 2 and λ=−1 with multiplicity 1, whatever a and b are. The parameters are invisible to the polynomial, which is exactly why the polynomial alone can never settle the question.
b)
Only λ=2 needs a test. A−2I=000a001b−3. Row 3 is a multiple of (0,0,1) and so is row 2: R2→R2+3bR3 turns row 2 into zeros for EVERY b. What remains is (0,a,1) and (0,0,−3). If a=0 these two rows have pivots in columns 2 and 3: rank 2, nullity 1<2, not diagonalizable. If a=0, R1→R1+31R3 kills row 1 too: rank 1, nullity 2, diagonalizable. So A is diagonalizable if and only if a=0, and b plays no role. The reason is structural: b couples the eigenvalue 2 to the eigenvalue −1, which are distinct, while a couples the eigenvalue 2 to ITSELF, and only that coupling can crush an eigenspace. Writing "a=0 and b=0" costs the part.
c)
E2: with a=0, A−2I reduces to the single equation z=0, so E2=span{(1,0,0),(0,1,0)}. E−1: A+I=300030130 gives 3x+z=0 and 3y+3z=0; with z=3 this is x=−1, y=−3, so the eigenvector is (−1,−3,3). Check: A(−1,−3,3)=(−2+3,−6+9,−3)=(1,3,−3), which is −1 times the vector. Hence P=100010−1−33 and D=diag(2,2,−1), the two columns for λ=2 first because the two 2 come first in D. P is triangular with detP=3=0.
d)
C is triangular, with eigenvalues 1 and k. If k=1 they are distinct, and two distinct eigenvalues give two independent eigenvectors: diagonalizable, no further work. If k=1, C−I=(0010) has rank 1, so dimE1=1<2 and C is not diagonalizable. Answer: every k=1.
e)
The identity I2 has the single eigenvalue 1, repeated, and it is diagonal already, with P=I. The matrix of c) is another counterexample. Distinct eigenvalues are SUFFICIENT, never necessary. The correct criterion: A is diagonalizable if and only if, for every eigenvalue, the geometric multiplicity equals the algebraic multiplicity; equivalently the dimensions of the eigenspaces add up to n.
Points are earned before the solution; after it, you can keep practising.
For you:
Exercise 3: Building P and D, and the order that ties them
11 answers to check
Diagonalizing is a change of axes: along an eigenvector, A does nothing but stretch. The matrix P lists those axes as its COLUMNS, and D lists the stretch factors in the SAME order. Both halves of that sentence cost marks when they are forgotten.
Let A=(1322).
a) Find an invertible P and a diagonal D with P−1AP=D.
b) Check your answer without computing P−1, by comparing AP with PD column by column.
c) Swap the two columns of P: what becomes of D? And if instead you multiply the first column of P by −5?
d) A student writes the eigenvectors as the ROWS of a matrix Q. Compute Q−1AQ and show it is not diagonal.
e) Compute P−1 and verify that PDP−1=A.
Show the solution
Answers
a)P=(231−1), D=diag(4,−1)
b)AP=PD=(812−11)
c)Swapping gives D=diag(−1,4); scaling a column leaves D unchanged
d)Q−1AQ=51(28−1222−13), not diagonal
e)P−1=51(131−2) and PDP−1=A
a)
det(A−λI)=(1−λ)(2−λ)−6=λ2−3λ−4=(λ−4)(λ+1). For λ=4: A−4I=(−332−2), and R2→R2+R1 leaves −3x+2y=0, so (2,3). For λ=−1: A+I=(2323), and R2→R2−23R1 leaves x+y=0, so (1,−1). Two distinct eigenvalues, so diagonalizability is automatic: P=(231−1) and D=diag(4,−1). The 4 comes first in D because (2,3) comes first in P.
b)
AP is A applied to each column of P: A(2,3)=(2+6,6+6)=(8,12)=4(2,3) and A(1,−1)=(1−2,3−2)=(−1,1)=−1(1,−1). And PD multiplies each column of P by the matching diagonal entry: PD=(812−11). The two agree. Since P is invertible (detP=−2−3=−5), AP=PD is the same statement as P−1AP=D, and it costs two matrix-vector products instead of an inverse. This is the check to write on every copy.
c)
Swapping the columns, P′=(1−123), forces D′=diag(−1,4): the i-th diagonal entry of D is the eigenvalue of the i-th column of P, so the two lists move together. Keeping D=diag(4,−1) with the swapped P gives AP′=P′D, and the answer is wrong although every number in it is right. Multiplying the first column by −5 gives (−10,−15), still an eigenvector for 4, so D does not change. P is never unique; D is unique up to the order of its entries.
d)
Q=(213−1), detQ=−5, Q−1=51(113−2). Then AQ=(4817) and Q−1AQ=51(28−1222−13), which is not diagonal. The reason is in the product itself: AQ applies A to the COLUMNS of Q, here (2,1) and (3,−1), and neither of those is an eigenvector. Rows of P are never read by the product AP.
e)
For a 2×2, swap the diagonal, negate the off-diagonal, divide by the determinant: P−1=−51(−1−3−12)=51(131−2). Then PDP−1=51(812−11)(131−2)=51(5151010)=(1322)=A. Note where P sits: A=PDP−1, with P on the LEFT. Multiplying P−1AP=D by P on the left and by P−1 on the right is the only way to get it back.
Points are earned before the solution; after it, you can keep practising.
For you:
Exercise 4: Powers of a matrix, read in the eigenvector axes
14 answers to check
Let A=(41−21). The figure draws its eigenvectors v1=(1,1), for λ=2, and v2=(2,1), for λ=3, as two new axes, and writes the standard vector e1=(1,0) in those axes as the diagonal of a parallelogram.
In the eigenvector axes, A multiplies the first coordinate by 2 and the second by 3; An does it n times. That is the whole reason diagonalization computes powers.
a) Check that v1 and v2 are eigenvectors, and write P, D and P−1.
b) Prove that An=PDnP−1 for every integer n≥1.
c) Give An entry by entry. Check the formula at n=0, at n=1, and against A3 computed directly.
d) Read on the figure how e1 is written in terms of v1 and v2, and deduce Ane1 without any matrix product. Compare with c).
e) Put n=−1 in the formula of c) and check that it gives A−1.
b)P−1P=I cancels between consecutive factors; induction on n
c)An=(2⋅3n−2n3n−2n2n+1−2⋅3n2n+1−3n), and A3=(4619−38−11)
d)e1=−v1+v2, so Ane1=−2nv1+3nv2=(2⋅3n−2n,3n−2n)
e)A−1=(1/6−1/61/32/3)
a)
Av1=(4−2,1+1)=(2,2)=2v1 and Av2=(8−2,2+1)=(6,3)=3v2. So P=(1121), with the columns in the order v1,v2, and D=diag(2,3) in the same order. detP=1−2=−1, so P−1=−11(1−1−21)=(−112−1). Check: PP−1=(−1+2−1+12−22−1)=I.
b)
From P−1AP=D we get A=PDP−1. Then A2=PDP−1PDP−1=PD(P−1P)DP−1=PD2P−1: the inner P−1P collapses to I. By induction, if An=PDnP−1 then An+1=AnA=PDnP−1PDP−1=PDn+1P−1. Finally Dn=diag(2n,3n), because a product of diagonal matrices multiplies the diagonal entries. Only D is raised entry by entry; An is NOT the matrix of the n-th powers of the entries of A.
c)
PDn=(2n2n2⋅3n3n), then multiply by P−1: An=(2⋅3n−2n3n−2n2n+1−2⋅3n2n+1−3n). At n=0: (2−11−12−22−1)=I. At n=1: (6−23−24−64−3)=A. At n=3: (54−827−816−5416−27)=(4619−38−11), and directly A2=(145−10−1), A3=A2A=(56−1020−1−28−10−10−1): the same. The two checks at n=0 and n=1 take ten seconds and catch a P−1 on the wrong side every time.
d)
Following the parallelogram, e1=−v1+v2: indeed −(1,1)+(2,1)=(1,0). Its eigen-coordinates are (−1,1), and An acts on them one at a time: Ane1=−2nv1+3nv2=(−2n+2⋅3n,−2n+3n). That is exactly the first column of c), as it must be, since Ane1 IS the first column of An. The figure also says where things go: 3n outgrows 2n, so Ane1 turns toward the line of v2 as n grows.
e)
With n=−1: A−1=(32−2131−211−321−31)=(1/6−1/61/32/3). The 2×2 formula agrees: detA=4+2=6 and A−1=61(1−124). The formula is allowed at n=−1 because D−1=diag(21,31) exists, that is because 0 is not an eigenvalue.
Points are earned before the solution; after it, you can keep practising.
For you:
Exercise 5: Similar matrices: what they share, and what sharing does not prove
10 answers to check
Two n×n matrices A and B are similar when B=P−1AP for some invertible P. They are then the same linear map written in two different bases, and everything that does not depend on the basis is shared: determinant, trace, rank, characteristic polynomial, eigenvalues.
The trap is the converse. Invariants can prove that two matrices are NOT similar; no list of invariants can prove that they are.
a) Prove that similar matrices have the same determinant and the same characteristic polynomial. Deduce that they have the same eigenvalues and the same trace.
b) Are (1324) and (5100) similar?
c) Show that M=(2012) and 2I have the same characteristic polynomial, trace, determinant and rank, and yet are not similar.
d) Show that M1=(1023) and M2=(3501) ARE similar, by going through a diagonal matrix, and give an S with M2=S−1M1S.
e) In Exercise 1, A and B had the same characteristic polynomial. Use an invariant to prove that they are not similar.
Show the solution
Answers
a)det(P−1AP)=detA and P−1AP−λI=P−1(A−λI)P
b)No: det=−2 against 0 (the traces agree, which proves nothing)
c)Both (2−λ)2, trace 4, det 4, rank 2; but P−1(2I)P=2I=M for every P
d)Both are similar to diag(1,3); S=PQ−1=(−21/210)
e)rank(A−3I)=1 but rank(B−3I)=2: not similar
a)
det(P−1AP)=det(P−1)detAdetP=detP1detAdetP=detA, by the product rule. For the polynomial, the key line is P−1AP−λI=P−1(A−λI)P, true because P−1(λI)P=λP−1P=λI. Taking determinants, det(B−λI)=det(A−λI) for every λ: same polynomial, hence same eigenvalues with the same algebraic multiplicities. The trace is the sum of the eigenvalues (for a 2×2 it is the coefficient in λ2−(tr)λ+det), so it is shared too. Rank is shared because multiplying by invertible matrices never changes it.
b)
The traces agree, 1+4=5=5+0, and a student who stops there concludes wrongly. The determinants are 4−6=−2 and 0. One invariant that differs is enough: NOT similar. The second matrix is singular and the first is not, and no change of basis can make a map lose invertibility.
c)
det(M−λI)=(2−λ)2=det(2I−λI); trace 4 and determinant 4 for both; rank 2 for both. Suppose P−1(2I)P=M. But P−1(2I)P=2P−1P=2I, whatever P is, and 2I=M. So the ONLY matrix similar to 2I is 2I itself. The four invariants were all equal and the conclusion is still no. What separates them is the eigenspace: M−2I has rank 1, so M has a single line of eigenvectors, while every vector is an eigenvector of 2I.
d)
M1 is triangular with eigenvalues 1 and 3, distinct, so M1=PDP−1 with D=diag(1,3): E1=span{(1,0)} and M1−3I=(−2020) gives (1,1), so P=(1011). M2 is triangular with eigenvalues 3 and 1: M2−I=(2500) gives (0,1) and M2−3I=(050−2) gives (2,5); ordering the columns to match the SAME D, Q=(0125) and M2=QDQ−1. Then D=P−1M1P, so M2=QP−1M1PQ−1=S−1M1S with S=PQ−1. Here Q−1=−21(5−1−20) and S=(−21/210). The route through the diagonal matrix is the only general way to PROVE similarity in this course.
e)
If B=S−1AS, then B−3I=S−1(A−3I)S, so A−3I and B−3I would have the same rank. Exercise 1 found rank(A−3I)=1 and rank(B−3I)=2. So A and B are not similar, although they share their polynomial (3−λ)2(1−λ). Equivalently: a matrix similar to a diagonalizable one is diagonalizable, and A is while B is not. This is the 3×3 version of c).
Points are earned before the solution; after it, you can keep practising.
For you:
Part B: problems and reasoning (/50)
Exercise 6: A population with two age classes, and its dominant eigenvalue
13 answers to check
A bird population is counted each spring in two classes: juveniles jk, hatched the previous year, and adults ak. Each adult produces on average 3 juveniles that survive to the next count, juveniles do not breed, half of the juveniles survive to become adults, and half of the adults survive another year. With vk=(jk,ak) this reads vk+1=Avk with A=(00.530.5).
The count starts at v0=(100,100). The figure plots the first five counts in the (j,a) plane, in hundreds of birds.
a) Diagonalize A.
b) Write v0 as a combination of the eigenvectors, and deduce a closed formula for vk.
c) Check the formula against the points v1 and v2 on the figure.
d) Describe the long-term behaviour: the growth rate per year and the eventual ratio of juveniles to adults. Explain why the negative eigenvalue does not matter in the long run.
e) Keep everything except the juvenile survival rate s, the 0.5 in the bottom left corner of A. For which s does the population neither grow nor shrink in the long run?
Show the solution
Answers
a)P=(21−31), D=diag(1.5,−1)
b)v0=80(2,1)+20(−3,1), so vk=80(1.5)k(2,1)+20(−1)k(−3,1)
c)v1=(300,100) and v2=(300,200), as plotted
d)Growth of 50 per cent a year, juveniles to adults tending to 2:1
e)s=61
a)
det(A−λI)=−λ(0.5−λ)−1.5=λ2−0.5λ−1.5. Doubling clears the decimals: 2λ2−λ−3=(2λ−3)(λ+1), so λ1=1.5 and λ2=−1. For 1.5: A−1.5I=(−1.50.53−1), and R1→R1+3R2 leaves j=2a, so u1=(2,1). For −1: A+I=(10.531.5), and R2→R2−0.5R1 leaves j=−3a, so u2=(−3,1). Distinct eigenvalues: P=(21−31), D=diag(1.5,−1), detP=5.
b)
Solve c1(2,1)+c2(−3,1)=(100,100): the second coordinate gives c2=100−c1, and the first 2c1−300+3c1=100, so c1=80 and c2=20. Since Akui=λikui, vk=Akv0=80(1.5)k(2,1)+20(−1)k(−3,1). This is Ak=PDkP−1 applied to v0, without ever writing P−1: the coefficients c1,c2 ARE P−1v0.
c)
k=1: (240,120)+(60,−20)=(300,100), and directly Av0=(0+300,50+50)=(300,100). k=2: 80×2.25=180, so (360,180)+(−60,20)=(300,200), and directly Av1=(300,150+50)=(300,200). These are the points (3,1) and (3,2) on the figure, in hundreds.
d)
Divide by 1.5k: 1.5kvk=80(2,1)+20(1.5−1)k(−3,1), and the second term tends to 0. So in the long run vk≈80(1.5)k(2,1): the population grows by 50 per cent a year and the juveniles outnumber the adults two to one, whatever the starting count (as long as c1=0). The eigenvalue −1 makes the second component flip sign every year, but its size stays 20 while the first grows without bound, so its relative weight vanishes. On the figure the counts do not converge to a point, they run away; it is their DIRECTION that settles on the line of u1, the dashed line of the solution figure.
e)
With s in the corner, det(A−λI)=λ2−0.5λ−3s. The population is stationary in the long run when the dominant eigenvalue is exactly 1: 1−0.5−3s=0, so s=61. Check that 1 really is dominant: the two roots add up to 0.5, so the other one is −0.5, smaller in absolute value. One juvenile in six must survive to adulthood; with one in two the colony grows, with fewer than one in six it dies out.
Points are earned before the solution; after it, you can keep practising.
For you:
Exercise 7: A two-state Markov chain and its steady state
11 answers to check
A bike-sharing network has two stations, Hilltop (H) and Riverside (R). Each bike is picked up once a day and returned to one of the two stations. Of the bikes taken at Hilltop, 80 per cent come back to Hilltop and 20 per cent end at Riverside; of those taken at Riverside, 30 per cent end at Hilltop and 70 per cent stay at Riverside. The figure is the transition diagram.
On the morning of day 0 all 500 bikes are at Hilltop. Let xk=(hk,rk) be the numbers of bikes at the two stations on the morning of day k.
a) Write the transition matrix T with xk+1=Txk. What do its columns add up to, and why?
b) Show that 1 is an eigenvalue of T without solving the characteristic equation, then get the other eigenvalue from the trace.
c) Diagonalize T and give xk as an explicit formula.
d) Give the steady state and the long-run share of each station. Show that it does not depend on how the 500 bikes were placed on day 0.
e) From which day on does Riverside hold at least 190 bikes?
Show the solution
Answers
a)T=(0.80.20.30.7); each column adds up to 1
b)T−I has rows adding to zero, so λ=1; then λ2=1.5−1=0.5
d)(300,200): 60 per cent at Hilltop, 40 per cent at Riverside, for any start with 500 bikes
e)From day 5 on
a)
Column j says where the bikes that start the day at station j end up: T=(0.80.20.30.7), so that hk+1=0.8hk+0.3rk and rk+1=0.2hk+0.7rk. Each column adds up to 1 because every bike ends the day SOMEWHERE: no bike is created or lost. Writing the probabilities along the rows instead gives the transpose, and xk+1=Txk then produces nonsense; check on day 1: T(500,0)=(400,100), which adds up to 500 as it must.
b)
T−I=(−0.20.20.3−0.3): its second row is minus its first, because each column of T−I adds up to 1−1=0. So T−I is singular and 1 is an eigenvalue, for EVERY matrix whose columns add up to 1. The trace is the sum of the eigenvalues: 0.8+0.7=1.5=1+λ2, so λ2=0.5. Check with the determinant: 0.56−0.06=0.5=1×0.5.
c)
For 1: −0.2h+0.3r=0, so u1=(3,2). For 0.5: T−0.5I=(0.30.20.30.2) gives h+r=0, so u2=(1,−1). Hence P=(321−1) and D=diag(1,0.5). Decompose x0: c1(3,2)+c2(1,−1)=(500,0) gives, by adding the two coordinates, 5c1=500, so c1=100 and c2=200. Then xk=100(3,2)+200(0.5)k(1,−1)=(300+200(0.5)k,200−200(0.5)k). Check: x1=(400,100) and x2=(350,150), while directly T(400,100)=(320+30,80+70)=(350,150).
d)
(0.5)k→0, so xk→(300,200): in the long run 60 per cent of the bikes are at Hilltop and 40 per cent at Riverside. The steady-state vector is the eigenvector for 1 SCALED to the total, (0.6,0.4) as proportions; quoting (3,2) as the answer is not a distribution. It does not depend on the start: the eigenvector (1,−1) adds up to 0, so the total of x0 equals 5c1, and a total of 500 forces c1=100 whatever the split. Only the transient term, which dies out, remembers where the bikes started.
e)
rk≥190 means 200−200(0.5)k≥190, that is (0.5)k≤0.05, that is 2k≥20. Since 24=16 and 25=32, this holds from k=5 on. On day 4 Riverside has 200−12.5=187.5 bikes on average, on day 5 it has 200−6.25=193.75. No calculator and no logarithm: the powers of 2 do the work.
Points are earned before the solution; after it, you can keep practising.
For you:
Exercise 8: Five statements to correct
5 answers to check
Each statement below was written by a student revising diagonalization for the MATH 133 final. Each is false as written. Say what is wrong, give the smallest counterexample that settles it, and write the correct statement.
a) "A matrix with a repeated eigenvalue cannot be diagonalized."
b) "A diagonalizable matrix is invertible, and an invertible matrix is diagonalizable."
c) "If P−1AP=D, then A=P−1DP."
d) "The long-run behaviour of vk+1=Avk depends only on the largest eigenvalue, never on v0."
e) "If A2 is diagonalizable, then so is A."
Show the solution
Answers
a)False: I2 has the double eigenvalue 1 and is diagonal
b)False both ways: diag(1,0) is diagonalizable and singular; (1011) is invertible and not diagonalizable
c)False: A=PDP−1; with P=(1011), D=diag(1,2) the two products differ
d)False: with A=diag(2,0.5) and v0=(0,1), vk→0
e)False: N=(0010) has N2=0 diagonal, but N is not diagonalizable
a)
FALSE. The identity I2 has the single eigenvalue 1, repeated twice, and it is already diagonal; so is the matrix A of Exercise 1, with its double eigenvalue 3. A repeated eigenvalue is where diagonalizability CAN fail, not where it does. Correct statement: A is diagonalizable if and only if, for each eigenvalue, dimEλ equals its algebraic multiplicity; only the repeated eigenvalues need that test.
b)
FALSE in both directions, because the two properties answer different questions. diag(1,0) is diagonal, so diagonalizable, and singular. (1011) has determinant 1, so it is invertible, and its double eigenvalue 1 has rank(A−I)=1, so dimE1=1<2: not diagonalizable. Correct: invertibility asks whether 0 is an eigenvalue; diagonalizability asks whether there are enough eigenvectors. Neither implies the other.
c)
FALSE: the P and the P−1 have changed sides. Multiply P−1AP=D on the left by P and on the right by P−1: A=PDP−1. With P=(1011) and D=diag(1,2): PDP−1=(1012) while P−1DP=(10−12). They differ, and only the first one has (1,1), the second column of P, as an eigenvector for 2. Correct: A=PDP−1, with the eigenvector matrix on the LEFT.
d)
FALSE. Writing v0=c1u1+c2u2, the dominant eigenvalue wins only if c1=0. With A=diag(2,0.5) and v0=(0,1), c1=0 and vk=(0,0.5k)→0, although the largest eigenvalue is 2. Correct: if ∣λ1∣ is strictly the largest and the component of v0 along u1 is non-zero, then vk behaves like c1λ1ku1. In real models the condition c1=0 is almost always true, which is why it is forgotten.
e)
FALSE. N=(0010) has N2=(0000), which is diagonal. But N has the double eigenvalue 0 and rank(N−0I)=1, so dimE0=1<2: not diagonalizable. The TRUE direction is the other one: if A=PDP−1 then A2=PD2P−1 with the same P, so every power of a diagonalizable matrix is diagonalizable.
Points are earned before the solution; after it, you can keep practising.
For you:
Exercise 9: Counting pavings: a recurrence solved by diagonalization
16 answers to check
A garden path 2 units wide and n units long is paved with two kinds of slabs: 1×2 rectangles, laid either across the path or along it, and 2×2 squares. Let tn be the number of different pavings, with t0=1 (the empty path) and t1=1 (one slab across).
The figure shows the three pavings of a path of length 2. The recurrence behind this count is a cousin of Fibonacci's, and diagonalization turns it into an exact formula.
a) Explain why tn=tn−1+2tn−2 for n≥2, and compute t2 to t5.
b) With Vn=(tn,tn+1), find the matrix A such that Vn+1=AVn.
c) Diagonalize A.
d) Deduce that tn=32n+1+(−1)n, and check it for n=0 to 5.
e) Compute t10, and explain why tntn+1 tends to 2.
Show the solution
Answers
a)Last slab across, or a 2×2 end block in two ways; t2=3, t3=5, t4=11, t5=21
b)A=(0211)
c)P=(121−1), D=diag(2,−1)
d)V0=32(1,2)+31(1,−1), first coordinate tn=32n+1+(−1)n
e)t10=683; the ratio tends to the dominant eigenvalue 2
a)
Look at the right end of the path. Either the last column is ONE slab laid across: what is left is a path of length n−1, paved in tn−1 ways. Or it is not: then the last column is covered by slabs that also cover the column before it, so the last 2×2 block is filled either by two slabs along the path or by one square, two ways, and what is left has length n−2. The cases are disjoint and cover everything, so tn=tn−1+2tn−2. Then t2=1+2=3, the three pictures of the figure, t3=3+2=5, t4=5+6=11, t5=11+10=21.
b)
Vn+1=(tn+1,tn+2)=(tn+1,2tn+tn+1), so the first new coordinate copies the old second one, and A=(0211). Turning a recurrence of order two into a first-order system on a PAIR of consecutive terms is the whole trick of Nicholson 3.4.
c)
det(A−λI)=−λ(1−λ)−2=λ2−λ−2=(λ−2)(λ+1). For 2: A−2I=(−221−1), and R2→R2+R1 leaves y=2x, so (1,2). For −1: A+I=(1212), and R2→R2−2R1 leaves x+y=0, so (1,−1). Hence P=(121−1), D=diag(2,−1), detP=−3.
d)
V0=(1,1)=c1(1,2)+c2(1,−1): adding the two equations c1+c2=1 and 2c1−c2=1 gives 3c1=2, so c1=32, c2=31. Then Vn=AnV0=322n(1,2)+31(−1)n(1,−1), whose first coordinate is tn=32n+1+(−1)n. Check: 32+1=1, 34−1=1, 38+1=3, 316−1=5, 332+1=11, 364−1=21. A formula for an integer sequence with a 3 in the denominator is believable only after this check: the numerator must always be a multiple of 3, and it is.
e)
t10=3211+1=32049=683, a number nobody would enumerate by hand. In the ratio tntn+1=2n+1+(−1)n2n+2−(−1)n, the terms ±1 stay bounded while the powers of 2 explode, so the ratio tends to 2: the DOMINANT eigenvalue. The solution figure shows it: the points hug the curve 322n, alternately 31 above and below it, and that alternating gap is the eigenvalue −1 at work.
Points are earned before the solution; after it, you can keep practising.
For you:
Exercise 10: Foxes and hares: where the dominant eigenvalue crosses 1
14 answers to check
In a predator and prey model, Fk is the number of foxes and Hk the number of hares, in hundreds, in year k. Without hares the foxes would halve every year; without foxes the hares would grow by 10 per cent a year. With xk=(Fk,Hk) the model is xk+1=Axk, where A=(0.5−p0.41.1) and p>0 measures how many hares a fox eats.
Every characteristic polynomial below factors by hand. This is a final-exam question in its usual shape: diagonalize, then read the long run off the eigenvalues.
a) Take p=0.2. Diagonalize A and describe what happens to both populations in the long run.
b) Find the value of p for which 1 is an eigenvalue of A.
c) Take p=0.125 and x0=(40,30). Diagonalize A and write xk explicitly.
d) Give the limit of xk and interpret it. Would another starting point lead to the same limit?
e) Without computing any eigenvector, explain what happens when p is slightly below 0.125.
Show the solution
Answers
a)λ=0.9, (1,1) and λ=0.7, (2,1): both populations die out, about 100 hares per fox
d)(20,25): 20 foxes and 2500 hares; another start gives another point of the line H=1.25F
e)The dominant eigenvalue exceeds 1: both populations eventually grow
a)
det(A−λI)=(0.5−λ)(1.1−λ)+0.4p=λ2−1.6λ+0.55+0.4p. With p=0.2: λ2−1.6λ+0.63=(λ−0.9)(λ−0.7), since 0.9+0.7=1.6 and 0.9×0.7=0.63. For 0.9: A−0.9I=(−0.4−0.20.40.2) gives F=H, so (1,1). For 0.7: A−0.7I=(−0.2−0.20.40.4) gives F=2H, so (2,1). P=(1121), D=diag(0.9,0.7). Then xk=c10.9k(1,1)+c20.7k(2,1)→(0,0): both species die out. The slower factor 0.9 dominates, so the decline settles at 10 per cent a year with Fk≈Hk, one fox per hundred hares, all the way down.
b)
1 is an eigenvalue exactly when A−I is singular: det(A−I)=(−0.5)(0.1)+0.4p=0, so 0.4p=0.05 and p=0.125. No need to solve the quadratic: the definition of an eigenvalue IS the singularity test.
c)
p=0.125: λ2−1.6λ+0.6=(λ−1)(λ−0.6). For 1: A−I=(−0.5−0.1250.40.1) gives 5F=4H, so (4,5). For 0.6: A−0.6I=(−0.1−0.1250.40.5) gives F=4H, so (4,1). P=(4541), D=diag(1,0.6). Decompose x0: c1(4,5)+c2(4,1)=(40,30); the first coordinate gives c1+c2=10, the second 5c1+c2=30, so c1=5 and c2=5. Hence xk=5(4,5)+5(0.6)k(4,1)=(20+20(0.6)k,25+5(0.6)k). Check k=1: the formula gives (32,28) and directly (0.5×40+0.4×30,−0.125×40+1.1×30)=(32,28).
d)
(0.6)k→0, so xk→(20,25): 20 foxes and 2500 hares, a stable coexistence. The solution figure shows the approach: the points slide toward the limit along the direction (4,1) of the eigenvalue 0.6, while the dashed line H=1.25F is the line of eigenvalue 1, every point of which is a fixed point. So another starting point gives another limit, c1(4,5), with the SAME ratio of 125 hares per fox. Compare with a Markov chain, where the total is conserved and fixes c1; nothing is conserved here.
e)
Write q(λ)=λ2−1.6λ+0.55+0.4p. Then q(1)=−0.05+0.4p, which is NEGATIVE when p<0.125. The parabola q opens upward and is positive for large λ, so it crosses zero somewhere beyond 1: the dominant eigenvalue is greater than 1. Then c1λ1k grows, and both populations eventually increase together in the proportions of the dominant eigenvector. The value p=0.125 is the knife edge between extinction and growth, and the whole analysis came from the sign of one number.
Points are earned before the solution; after it, you can keep practising.
Something missing from this set?A type of exercise your teacher gives, a problem you are stuck on, a mistake you spotted: tell me, I read every request.
Sending goes through your free space: that is how I can answer you and tell you when the exercise is added. An email is enough, no password. Create your space.
Rather not create an account? Write to me directly.
I tutor first-year linear algebra at McGill University and Concordia University, in English or in French, in Montreal or online. Get in touch for a first session.