-
Notifications
You must be signed in to change notification settings - Fork 2
/
chap3-systems.tex
717 lines (490 loc) · 19.3 KB
/
chap3-systems.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% Chapter 3 - System Models
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{topic}[Models of Systems]
\vfil
\begin{center}
\begin{minipage}{300pt}
\includegraphics*[width=300pt]{images/chap3-xkcd.png}
\hfill {\footnotesize (image from \href{https://www.xkcd.com/2063/}{xkcd - comic \#2063})}
\end{minipage}
\end{center}
\end{topic}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% MODULE - Modelling Two Interconnected Quantities
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{module}{Modelling Two Quantities}
\label{sys:model}
\input{modules/module16-sys-model.tex}
\input{modules/module16-sys-model-exercises.tex}
\end{module}
\begin{lesson}
\Title{Modelling Two Quantities I}
\Heading{Textbook}
\begin{itemize}
\item Module 15
\end{itemize}
\Heading{Objectives}
\begin{itemize}
\item Model with two interconnected quantities
\item Follow the step-by-step procedure to create a model
\end{itemize}
\Heading{Motivation}
Again, this is the main goal of this course: learn how to create models.
In this class, the goal is to study how to model quantities that affect each other (and are affected by external factors).
After the students create a model, they should get used to making sure the model is ``good'', i.e., using some software look at some approximation of solutions to see the consequences of the model.
\Heading{Preparation for Class}
\begin{itemize}
\item Read textbook
\item Read the core exercise \ref{sys:competition} and solve steps 1 (define problem) and 2 (create a mind map)
\end{itemize}
\Heading{Tutorials and Projects}
\begin{itemize}
\item Project \ref{proj:pursuit}: \pursuittitle
\item Project \ref{proj:epidemic}: \epidemictitle
\item Project \ref{proj:lotkavolterra}: \lotkavolterratitle
\end{itemize}
\end{lesson}
\begin{annotation}
\begin{goals}
\Goal{Pre-class exercise.}
Students bring their mind map and the definition of the functions they need to find.
\end{goals}
\end{annotation}
\question \label{sys:competition}
We want to model two competing populations, like cheetahs and lions: they don't hunt each other, but they hunt the same prey.
\begin{annotation}
\begin{goals}
Stress that students should follow the step-by-step approach from chapter 1.
\emph{.4} only if there is time. Tell the students to ``go nuts'' and include everything that relates.
\end{goals}
\end{annotation}
\begin{parts}
\item Create a model for these two populations.
\item Using Desmos or WolframAlpha, create a slope field in the plane where the horizontal axis is one population and the vertical one is the other.
\item Using the slope field, deduce some properties of your model and discuss how closely it matches what you expect from these populations.
\item Extend the model to include a population of antelopes.
\end{parts}
\bookonlynewpage
\begin{lesson}
\Title{Modelling Two Quantities II}
\Heading{Textbook}
\begin{itemize}
\item Module 15
\end{itemize}
\Heading{Objectives}
\begin{itemize}
\item Model with two interconnected quantities
\item Follow the step-by-step procedure to create a model
\end{itemize}
\Heading{Motivation}
This class students work on a model that involves a little more calculus (for the cheetah's movement) and also is more \textbf{open ended} on how the cheetah will follow the antelope, but mainly on how the antelope will try to escape the cheetah.
The instructor should encourage different solutions from students.
\Heading{Preparation for Class}
\begin{itemize}
\item Read textbook
\item Read the core exercise \ref{sys:chase} and solve steps 1 (define problem) and 2 (create a mind map)
\end{itemize}
\Heading{Tutorials and Projects}
\begin{itemize}
\item Project \ref{proj:pursuit}: \pursuittitle
\item Project \ref{proj:epidemic}: \epidemictitle
\item Project \ref{proj:lotkavolterra}: \lotkavolterratitle
\item Project \ref{proj:arms}: \armstitle
\end{itemize}
\end{lesson}
\begin{annotation}
\begin{goals}
\Goal{Pre-class exercise.}
Students bring their mind map and the definition of the functions they need to find.
\end{goals}
\begin{goals}
This exercise is not required to do in lecture. \\
Be careful with assumptions! A very general model will be very hard to study. \\
Allow some brainstorming and try to create a structure for this problem:
\begin{itemize}
\item Positions seen from above ($xy-$plane).
\item Only need $x_a(t), y_a(t)$ and $x_c(t), y_c(t)$
\item Focus on the cheetah: where is she heading to?
\item For the antelope, students need to come up with an escape strategy
\item Model will be nonlinear!
\end{itemize}
\end{goals}\end{annotation}
\question \label{sys:chase}
A cheetah is chasing an antelope. We want a model of their positions as they run.
\standardonlynewpage
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% MODULE - Solving Systems
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{module}{Systems of two linear ODEs with constant coefficients}
\label{sys:solve}
\input{modules/module17-sys-solving.tex}
\input{modules/module17-sys-solving-exercises.tex}
\end{module}
\begin{lesson}
\Title{Systems of two linear ODEs with constant coefficients I}
\Heading{Textbook}
\begin{itemize}
\item Module 16
\end{itemize}
\Heading{Objectives}
\begin{itemize}
\item Know how to find eigenvalues and eigenvectors of a matrix
\item Know how to find a solution from an eigenvalue and an eigenvector
\item Know how to write the general solution to a system of ODEs
\item Know how to find the constants given an initial condition
\end{itemize}
\Heading{Motivation}
Linear Algebra strikes again!!! It will be very important to know how to solve a linear system of equations (although we'll focus on $2\times 2$ systems only) and how to find eigenvalues and eigenvectors.
This is the more computational part of the course.
Even though it's not the focus of the course, students need to know how solutions are found. This will give some insight for the analysis of a system of ODEs later.
We start with problems involving two real distinct eigenvalues.
\Heading{Preparation for Class}
\begin{itemize}
\item Review Linear Algebra (Appendix 7.1)
\item Read textbook: Two real distinct eigenvalues
\item Watch video
\item Solve the core exercise \ref{sys:2real}.1.
\end{itemize}
\Heading{Tutorials and Projects}
\begin{itemize}
\item Project \ref{proj:arms}: \armstitle
\end{itemize}
\end{lesson}
\question \label{sys:2real}
Consider a cheetah-lion inspired problem:
$$
\frac{d \,\vec{r}}{dt} = \begin{bmatrix} 3 & -2 \\ -1 & 4\end{bmatrix} \vec{r}.
$$
\begin{annotation}
\begin{goals}
\Goal{Superposition Principle.}
After .5, can introduce the principle of superposition:
\begin{itemize}
\item If $\vec{r}_1$ and $\vec{r}_2$ are solutions of a linear homogeneous (system of) ODE(s), then $\vec{r} = c_1 \vec{r}_1 + c_2\vec{r}_2$ is also a solution for any constants $c_1,c_2$.
\end{itemize}
\end{goals}
\end{annotation}
\begin{parts}
\item Find the two solutions $\vec{r}_1, \vec{r}_2$.
\item Is $\vec{r}_1(t) + \vec{r}_2(t)$ a solution?
\item Is $\vec{r}_1(t) - \vec{r}_2(t)$ a solution?
\item Is $2\vec{r}_1(t) + 3\vec{r}_2(t)$ a solution?
\item What is the general solution?
\item Find the solution that satisfies $\vec{r}(0) = \begin{bmatrix} 6 \\ 7\end{bmatrix}$?
\end{parts}
\begin{annotation}
\begin{goals}
\Goal{If there is more time.}
Start working on the core exercise for the next lesson.
\end{goals}
\end{annotation}
\bookonlynewpage
\begin{lesson}
\Title{Systems of two linear ODEs with constant coefficients II}
\Heading{Textbook}
\begin{itemize}
\item Module 16
\end{itemize}
\Heading{Objectives}
\begin{itemize}
\item Know how to find complex eigenvalues and eigenvectors of a matrix
\item Know how to find a complex solution from an eigenvalue and an eigenvector
\item Know how to re-write the solution using Euler's Formula and only real numbers
\end{itemize}
\Heading{Motivation}
We now add some complex numbers into the mix! Although students only need a very (Very) superficial knowledge of complex numbers.
We study problems involving two complex eigenvalues or one repeated real eigenvalue.
The third case: One repeated real eigenvalue will not be worked on in lecture. Students should learn it by themselves and practice it.
\Heading{Preparation for Class}
\begin{itemize}
\item Read textbook: Two complex eigenvalues
\item Watch corresponding video
\item Solve the core exercise \ref{sys:corecomplex}.
\end{itemize}
\Heading{Tutorials and Projects}
\begin{itemize}
\item Project \ref{proj:arms}: \armstitle
\end{itemize}
\end{lesson}
\begin{annotation}
\begin{goals}
\Goal{Skip .2 and start working on next core exercise}
\end{goals}
\end{annotation}
\question \label{sys:corecomplex}
Consider a problem:
$$
\frac{d \,\vec{r}}{dt} = \begin{bmatrix} 2 & -5 \\ 1 & -2\end{bmatrix} \vec{r}.
$$
\begin{parts}
\item Find the general solution.
\item Find the solution that satisfies $\vec{r}(0) = \begin{bmatrix} 6 \\ 7\end{bmatrix}$?
\end{parts}
\bookonlynewpage
\begin{annotation}
\begin{goals}
\Goal{Non-Homogeneous Problem}
% Introduce this core exercise as a non-homogeneous problem. \\
Students don't know how to solve it yet:
\begin{enumerate}
\item Equilibrium solution ($\begin{bmatrix}2\\-1\end{bmatrix}$)
\item Show phase portrait using WolframAlpha \url{https://uoft.me/modelling-sys-nonhom}
\item Ask students about properties of the phase portrait (\emph{Goal}: solutions revolve around the equilibrium point)
\item Redefine centre: $\vec{r} = \vec{\rm eq} + \vec{p}$. What system foes $\vec{p}$ solve?
\item $\cdots$
\end{enumerate}
There are practice problems about this.
\end{goals}
\end{annotation}
\question
Consider a problem:
$$
\frac{d \,\vec{r}}{dt} = \begin{bmatrix} 2 & -5 \\ 1 & -2\end{bmatrix} \vec{r} - \begin{bmatrix} 9 \\ 4 \end{bmatrix}.
$$
%[2,-1]
\begin{parts}
\item Find the equilibrium solution.
\item Find the general solution.
\item Find the solution that satisfies $\vec{r}(0) = \begin{bmatrix} 8 \\ 6 \end{bmatrix}$?
\end{parts}
\standardonlynewpage
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% MODULE - Phase Portraits
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{module}{Phase Portraits}
\label{sys:phase}
\input{modules/module18-sys-phase.tex}
\input{modules/module18-sys-phase-exercises.tex}
\end{module}
\begin{lesson}
\Title{Phase Portraits I}
\Heading{Textbook}
\begin{itemize}
\item Module 17
\end{itemize}
\Heading{Objectives}
\begin{itemize}
\item Interpret a phase portrait
\item Sketch a phase portrait
\end{itemize}
\Heading{Motivation}
After learning how to create a model involving a system of ODEs and how to find the solution, we turn our attention to how to represent the solutions.
The phase portrait is a compact way to represent all possible solutions of a system of two ODEs.
Through sketching phase portraits, we are also learning the different possible behaviours of solutions of systems of two ODEs.
We start with systems of two ODEs with two real distinct eigenvalues.
It usually takes a while to sketch the first phase portrait, so the first lesson is dedicated to sketching only one.
\Heading{Preparation for Class}
\begin{itemize}
\item Read textbook
\item Watch first video
\item Solve the core exercise \ref{sys:phaseportrait-real}.
\end{itemize}
\Heading{Tutorials and Projects}
\begin{itemize}
\item Project \ref{proj:lotkavolterra}: \lotkavolterratitle
\item Project \ref{proj:arms}: \armstitle
\end{itemize}
\end{lesson}
\begin{annotation}
\begin{goals}
\Goal{Pre-class exercise}
\end{goals}
\begin{goals}
\Goal{Unstable Saddle Point}
At the end, let the students know that the equilibrium is called \emph{saddle point} and it is \emph{unstable}, because solutions go away from it.
For the interpretation question, when one population hits zero, it is extinct, so the graph doesn't make sense.
We can interpret that if a population becomes extinct, then the other will behave as it would without competitors: grow exponentially fast!
\end{goals}
\end{annotation}
\question \label{sys:phaseportrait-real}
Consider the following model for cheetah's and lions, where
$$ \vec{p}(t) = \begin{bmatrix} \ell(t) = \text{population of lions} \\ c(t) = \text{population of cheetahs} \end{bmatrix} $$
which satisfies
$$
\frac{d\,\vec{p}}{dt} = \begin{bmatrix}
1 & -1 \\
-3 & 1
\end{bmatrix}
$$
The general solution is:
$$
\vec{p}(t) = c_1 \begin{bmatrix} 1 \\ \sqrt{3} \end{bmatrix} e^{(1-\sqrt{3})t} + c_2 \begin{bmatrix} -1 \\ \sqrt{3} \end{bmatrix} e^{(1+\sqrt{3})t}.
$$
\begin{parts}
\item Without computing them, what are the eigenvalues and eigenvectors of the matrix?
\item Sketch the graph of the solution with $c_1=\pm 1$ and $c_2=0$.
\item Sketch the graph of the solution with $c_1=0$ and $c_2=\pm 1$.
\item When one constant is set to 0, what is the shape of the graph? Is it always like that? Can you prove it?
\item Sketch the graph of the solution with $c_1=\pm 1$ and $c_2=\pm 1$.
\item Provide an interpretation of the different types of solutions.
\end{parts}
\bookonlynewpage
\begin{lesson}
\Title{Phase Portraits II}
\Heading{Textbook}
\begin{itemize}
\item Module 17
\end{itemize}
\Heading{Objectives}
\begin{itemize}
\item Interpret a phase portrait
\item Sketch a phase portrait
\end{itemize}
\Heading{Motivation}
There are a few more different behaviours, so we study some more cases.
We start with a non-homogeneous case and then study some other cases of phase portraits with two real distinct eigenvalues.
\Heading{Preparation for Class}
\begin{itemize}
\item Solve the core exercise \ref{sys:phaseportrait-real-equil}.
\end{itemize}
\Heading{Tutorials and Projects}
\begin{itemize}
\item Project \ref{proj:lotkavolterra}: \lotkavolterratitle
\item Project \ref{proj:arms}: \armstitle
\end{itemize}
\end{lesson}
\begin{annotation}
\begin{goals}
\Goal{Pre-class exercise}
\begin{itemize}
\item Solve quickly in class.
\item Get students to compare their results with the previous core exercise.
\item How does the interpretation of the population dynamics change?
\end{itemize}
% Some students might try to sketch everything from scratch.
% Remind them that the solutions look very similar and they only have to adapt the phase portrait they had before.\\
\end{goals}
\end{annotation}
\question \label{sys:phaseportrait-real-equil}
Let us expand the model from the previous exercise to:
$$ \vec{p}(t) = \begin{bmatrix} \ell(t) = \text{population of lions} \\ c(t) = \text{population of cheetahs} \end{bmatrix} $$
which satisfies
$$
\frac{d\,\vec{p}}{dt} = \begin{bmatrix}
1 & -1 \\
-3 & 1
\end{bmatrix} \vec{p}
+ \begin{bmatrix}
- 10 \\ 50
\end{bmatrix}.
$$
The extra term corresponds to the effect of harvesting 10 lions and bringing in 50 cheetahs every year to the reserve. \\
The general solution is:
$$
\vec{p}(t) = \begin{bmatrix} 20 \\ 10 \end{bmatrix} +
c_1 \begin{bmatrix} 1 \\ \sqrt{3} \end{bmatrix} e^{(1-\sqrt{3})t} + c_2 \begin{bmatrix} -1 \\ \sqrt{3} \end{bmatrix} e^{(1+\sqrt{3})t}.
$$
\begin{parts}
\item Sketch the phase portrait.
\item Provide an interpretation of the different types of solutions.
\end{parts}
\bookonlynewpage
\begin{annotation}
\begin{goals}
At the end, let the students know what these equilibria are called:
\begin{itemize}
\item \emph{source} and it is \emph{unstable}, because solutions go away from it.
\item \emph{sink} and it is \emph{asymptotically stable}, because solutions converge to it.
\end{itemize}
If there is time, students can think about:
\begin{itemize}
\item Given a matrix $A$, which part of $A$ indicates whether the equilibrium is stable / unstable? Which part indicates whether it's a sink/source vs spiral sink/source?
\end{itemize}
\end{goals}
\end{annotation}
\question
For each of the following general solutions, sketch the phase portrait.
\begin{parts}
\item $ \vec{r}(t) = c_1 \begin{bmatrix} 2 \\ 1 \end{bmatrix} e^{2t} + c_2 \begin{bmatrix} -1 \\ 1 \end{bmatrix} e^{5t}.$
\item $ \vec{r}(t) = c_1 \begin{bmatrix} 2 \\ 1 \end{bmatrix} e^{-2t} + c_2 \begin{bmatrix} -1 \\ 1 \end{bmatrix} e^{-5t}.$
\end{parts}
\standardonlynewpage
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% MODULE - Analysis of Systems
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{module}{Analysis of Models with Systems}
\label{sys:analysis}
\input{modules/module19-sys-analysis.tex}
\input{modules/module19-sys-analysis-exercises.tex}
\end{module}
\begin{lesson}
\Title{Analysis of Models with Systems}
\Heading{Textbook}
\begin{itemize}
\item Module 18
\end{itemize}
\Heading{Objectives}
\begin{itemize}
\item Deduce properties of solutions of systems of ODEs using different approaches
\end{itemize}
\Heading{Motivation}
Analysis of a system of ODEs is important.
It's not always possible to find the solution of a model, but it's usually possible to sketch a rough phase portrait, to approximate the solution, or to just deduce some properties of the solutions.
\Heading{Preparation for Class}
\begin{itemize}
\item Read textbook
\item Solve the core exercise \ref{sys:clothes}.1
\end{itemize}
\Heading{Tutorials and Projects}
\begin{itemize}
\item Project \ref{proj:pursuit}: \pursuittitle
\item Project \ref{proj:epidemic}: \epidemictitle
\item Project \ref{proj:lotkavolterra}: \lotkavolterratitle
\item Project \ref{proj:arms}: \armstitle
\end{itemize}
\end{lesson}
\question \label{sys:clothes}
Consider the following model for the sales from a designer clothing brand:
\begin{itemize}
\item $x_1(t) = $ purchases by ``common mortals'' (CM) at time $t$ in years since the beginning of 2015.
\item $x_2(t) = $ purchases by ``famous people'' (FP) at time $t$.
\end{itemize}
Our model is based on the following two principles:
\begin{enumerate}[label={($P_{\arabic*}$)}]
\item CM will buy more items from the brand when CM or FP buy more.
\item FP will buy less when CM buy them, but will buy more when FP buy it.
\end{enumerate}
The model we considered is:
$$
\vec{x}'(t) =
\begin{bmatrix}
a & b \\
-c & d
\end{bmatrix}
\vec{x}(t)
$$
\begin{parts}
\item Suppose that at the beginning only CM buy this brand. Describe how $x_1(t)$ and $x_2(t)$ evolve as $t>0$.
\item Suppose that at the beginning only FP buy this brand. Describe how $x_1(t)$ and $x_2(t)$ evolve as $t>0$.
\item What conditions on the constants $a,b,c,d$ will guarantee that the solutions will spiral? In that case, is it a spiral source or spiral sink? Is it clockwise or counterclockwise?
\item Are there constants $a,b,c,d>0$, such that the solution $\vec{x}$ is periodic?
\begin{annotation}
\begin{goals}
\Goal{If there isn't enough time to finish:}
\begin{itemize}
\item Take an extra lecture if there is enough to do
\item Can leave .6 as a practice problem
\end{itemize}
\end{goals}
\end{annotation}
\item Consider the constants $a=b=c=d=1$. Assume that initially CM were buying $c_0>0$ items and FP were buying $f_0>0$ items.
What will happen to $x_1(t)$ and $x_2(t)$ as $t \to \infty$? Explain the results in terms of the evolution of purchases from CM and FP.
\item Consider the constants $a=b=c=d=1$. If $c_0=10$, $f_0=100$, then at what time will FP stop buying items? And at what time will FP be buying the maximum number of items?
\end{parts}
\begin{notslides}
\bookonlynewpage
\hfill
\bookonlynewpage
\standardonlynewpage
\end{notslides}