-
Notifications
You must be signed in to change notification settings - Fork 0
/
linalg.xml
2985 lines (2736 loc) · 93.1 KB
/
linalg.xml
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
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<!-- <!DOCTYPE mathbook SYSTEM "/home/mdoob/mathbook.dtd"> -->
<!-- math1220.xml -->
<pretext>
<docinfo>
<brandlogo url="http://www.umanitoba.ca" source="images/umlogo.png" />
<macros>
\def\R{{\mathbb R}}
\def\C{{\mathbb C}}
\def\Q{{\mathbb Q}}
\def\Z{{\mathbb Z}}
\def\N{{\mathbb N}}
\def\vec#1{\mathbf #1}
\newcommand{\adj}{\mathop{\textrm{adj}}}
\newcommand{\proj}{\mathop{\textrm{proj}}}
\newcommand{\Span}{\mathop{\textrm{span}}} <!-- \span is a TeX primitive -->
\newcommand{\rowint}[2]{R_{#1} \leftrightarrow R_{#2}}
\newcommand{\rowmul}[2]{R_{#1}\gets {#2}R_{#1}}
\newcommand{\rowadd}[3]{R_{#1}\gets R_{#1}+#2R_{#3}}
\newcommand{\rowsub}[3]{R_{#1}\gets R_{#1}-#2R_{#3}}
</macros>
</docinfo>
<book xml:id="linalg"><title> Manitoba linear algebra </title>
<frontmatter>
<titlepage>
<author>
<personname>Michael Doob (editor)</personname>
<department> Department of Mathematics </department>
<institution> The University of Manitoba
</institution>
<email>Michael_Doob@UManitoba.ca</email>
</author>
<credit>
<title>
</title>
<author>
<personname>
</personname>
</author>
</credit>
<date>
<today />
</date>
</titlepage>
</frontmatter>
<chapter>
<title>Systems of Linear Equations</title>
<section><title>Review of two equations in two unknowns </title>
<subsection><title>The standard method for finding the solution </title>
<p>Suppose we want to find <em>all</em> solutions to the equations</p>
<p>
<md>
<mrow>2x+3y \amp = 5</mrow>
<mrow>3x+2y \amp= 7</mrow>
</md>
</p>
<p>The <em>standard</em> technique is to manipulate one or both of the equations until
either <m>x</m> has the same coefficient in both equations
or <m>y</m> has the same coefficient, and then
subtract to eliminate one variable. Since there is only one variable left,
its value can be found; with this information, the value for the other variable
can be found.</p>
<p>In the case above, we can multiply both sides of the second equation by
<m>\frac23</m>,
to get
<me>
2x+\tfrac43 y= \tfrac{14}3,
</me>
and subtracting from the first equation gives
<me>
\frac53y = \frac13,
</me>
or
<me>
y=\frac15.
</me>
</p>
<p>
Using the first equation and the (now) known value of <m>y</m>, we find that
<me>
x=\frac{11}5.
</me>
</p>
<p>
Hence we see that there is exactly one pair of values for
<m>x</m>
and
<m>y</m> that simultaneously satisfy both equations:
<m>x=\frac{11}5</m> and <m>y=\tfrac15.</m> We can also write this
as <m>(x,y)=(\frac{11}5,\frac15).</m>
In this case we say that there is a <em>unique</em> solution (in mathematics, the term
unique means <em>exactly one</em>).
</p>
</subsection>
<subsection><title>The geometric method of finding the solution</title>
<p>The set of equations solved in the previous section can also be
viewed geometrically. The points in the <m>x</m>-<m>y</m>
plane satisfying one of the equations lie on a straight line, and
any point satisfying both of the equations must lie on both lines.
The plot of the two lines looks like this:</p>
<!---see here -->
<figure>
<caption>Intersection of two lines in the plane</caption>
<image xml:id="TwoLinesInPlane" width="40%">
<asymptote>
import graph;
unitsize(30);
real xmin=-1; real xmax=4;
xaxis(LeftTicks);yaxis(LeftTicks);
real f1(real x) {return (5-2*x)/3;}
real f2(real x) {return (7-3*x)/2;}
draw((xmin,f1(xmin))--(xmax,f1(xmax)),green);
draw((xmin,f2(xmin))--(xmax,f2(xmax)),red);
dot((11/5,1/5));
label("\((\frac{11}5,\frac15)\)",(11/5,1/5),NE);
</asymptote>
</image>
</figure>
<p>The point of intersection is <m>(x,y)=(\frac{11}5,\frac15)</m>,
just as before.</p>
</subsection>
</section>
<section><title>Equations with multiple solutions or no solutions</title>
<subsection><title>Equations with no solutions</title>
<p>
Suppose we want to find all solutions to the equations
<md>
<mrow>2x+4y \amp = 5</mrow>
<mrow>-x-2y \amp = 1</mrow>
</md>
Using the <em>standard</em> approach we multiply the second equation by <m>2</m> and add it
to the first one to eliminate the variable <m>x</m>. This leaves us
with the equation
0=7
This is certainly an equality that is not valid. What happened? We can see by
multiplying the second equation by <m>-2</m>. We then have
<md>
<mrow>2x+4y \amp = 5</mrow>
<mrow>2x+4y \amp = -2</mrow>
</md>
</p>
<p>
Whatever <m>x</m> and <m>y</m> are, the value of <m>2x+4y</m> can't be
<m>5</m> and <m>-2</m> at the same time. So there are no solutions.
What happens if we try to graph these two equations? Here is what we get:
</p>
<figure>
<caption>Two Parallel lines in the Plane</caption>
<image xml:id="ParallelLinesInPlane" width="70%">
<asymptote>
import graph;
unitsize(40);
real xmin=-2; real xmax=4;
xaxis(LeftTicks);yaxis(LeftTicks);
real f1(real x) {return (5-2*x)/4;}
real f2(real x) {return (1+x)/-2;}
draw((xmin,f1(xmin))--(xmax,f1(xmax)),green);
draw((xmin,f2(xmin))--(xmax,f2(xmax)),red);
</asymptote>
</image>
</figure>
<p>
The geometry of the situation is now clear: the two lines are parallel and so there is no
point on both lines (indeed, both lines have slope <m>-\tfrac12</m>).
When we have equations with no common solution, they are called <em>inconsistent</em>.
</p>
</subsection>
<subsection><title> Equations with more than one solution </title>
<p>Now let's alter the situation of the previous section slightly.
We consider the pair of equations
<md>
<mrow>2x+4y \amp = -2</mrow>
<mrow>-x-2y \amp = 1</mrow>
</md>
We apply the <em>standard</em> method again: multiply the second equation by <m>2</m>
and add it to the first. The result is
<me>0=0</me>
This is certainly a valid, although not very interesting, equation. In fact, if we
multiply both sides of the second equation by <m>-2</m> the system becomes
<md>
<mrow>2x+4y \amp = -2</mrow>
<mrow>2x+4y \amp = -2</mrow>
</md>
This means that any solution of the first equation is also a solution of the second one.
Geometrically, if we plot the graph of the two equations, the same line results for
each one. How do we find all solutions in this case? Let us assign a value to <m>y</m>.
Let's call it <m>t</m> so <m>y=t</m>. Then, using either equation, we have
<m>x=-2t-1</m>.
This means that for <em>any</em> value of <m>t</m> we know that
<m>(x,y)=(-2t-1,t)</m> is a solution to both equations. So, in fact we have an infinite
number of solutions.</p>
<theorem xml:id="TwoEquationaTwoUnknowns"><title>Two equations in two unknowns</title>
<statement>
<p>Two equations in two unknowns may have:
<ul>
<li><p>No solutions</p></li>
<li><p>A single (unique) solutions</p></li>
<li><p>An infinite number of solutions</p></li>
</ul>
</p>
</statement>
<proof><p>
The corresponding lines in the plane are parallel, intersect at
a single point, or are identical.
</p></proof>
</theorem>
</subsection>
</section>
<section><title>Important Definitions for Linear Equations</title>
<subsection><title>The Definition of a Linear Equation</title>
<p>
The equations given above are linear equations in two variables.
A <em>linear equation in <m>n</m> variables</em>
<m>x_1, x_2, \dots, x_n</m> is an equation of the form
\<me>
a_1x_1+ a_2x_2+ \cdots +a_n x_n= b
</me>
where <m>a_1,\dots,a_n</m> and <m>b</m> are constants.
The numbers <m>a_1,a_2,\dots,a_n</m> are called the <em>coefficients</em>
of the equation, that is, <m>a_1</m> is the coefficient of <m>x_1</m>,
<m>a_2</m> is the coefficient of <m>x_2</m>, etc.
This is also called a <em>linear equation in <m>n</m> unknowns</em>.</p>
<p>The following are examples of linear equations:
<ul>
<li><p> <m>2x=4</m> (one variable)</p></li>
<li><p> <m>4x-2y=7</m> (two variables)</p></li>
<li><p><m>\tfrac12 x -\tfrac35 y +\pi z=0</m> (three variables)</p></li>
<li><p> <m>x_1-3x_2+4x_3-7x_4=100</m> (four variables)</p></li>
<li><p><m>3x_1+15x_5=-10</m>
(five variables: the ones with a coefficient of zero are not written)</p>
</li>
</ul>
</p>
</subsection>
<subsection><title>The Definition of a System of Linear Equations</title>
<p>A <em>system of <m>m</m> linear equations in <m>n</m>
unknowns</em> is a list of <m>m</m> linear equations, each of which
has the same set of <m>n</m> unknowns. They are usually presented
with the purpose of finding all of their simultaneous solutions.</p>
<p>The original example given above is a system of 2 equations in 2 unknowns.
Here are some more examples:
<ul>
<li><p>A system of 2 equations in 3 unknowns:
<md>
<mrow>x-y+z \amp = 1</mrow>
<mrow>2x+3y-z \amp = 2</mrow>
</md>
</p>
</li>
<li><p>A system of 3 equations in 2 unknowns:
<md>
<mrow>u+v \amp = 1</mrow>
<mrow>2u+v \amp = 3</mrow>
<mrow>u+2v \amp =3</mrow>
</md>
</p>
</li>
<li><p>A system of 4 equations in 5 unknowns:
<md alignment="alignat">
<mrow>x_1 \amp + \amp x_2 \amp \amp \amp \amp \amp \amp \amp =1</mrow>
<mrow>\amp \amp x_2 \amp +\amp x_3 \amp \amp \amp \amp \amp =2</mrow>
<mrow>\amp \amp \amp \amp x_3 \amp +\amp x_4 \amp \amp \amp = 3</mrow>
<mrow>\amp \amp \amp \amp \amp \amp x_4 \amp +\amp x_5 \amp =4</mrow>
</md>
</p>
</li>
<li><p>A system of <m>m</m> equations in <m>n</m> unknowns <m>x_1, x_2, x_3\dots,x_n</m>:
<md>
<mrow>a_{1,1}x_1 + a_{1,2}x_2 + \cdots + a_{1,n}x_n \amp = b_1</mrow>
<mrow>a_{2,1}x_1 + a_{2,2}x_2 + \cdots + a_{2,n}x_n \amp = b_2</mrow>
<mrow>\amp \vdots</mrow>
<mrow>a_{m,1}x_1 + a_{m,2}x_2 + \cdots + a_{m,n}x_n \amp = b_m</mrow>
</md>
</p>
</li>
</ul>
</p>
</subsection>
<subsection><title>The Coefficient and Augmented Matrix of a System of Linear Equations </title>
<p>A <em>matrix</em> is a rectangular array of numbers (the plural is <em>matrices</em>). Here is a matrix:
<me>
\begin{bmatrix}
1 \amp 2 \amp 3 \amp 4\\
5 \amp 6 \amp 7 \amp 8\\
9 \amp 10\amp 11\amp 12
\end{bmatrix}
</me>
This matrix has 3 rows:
<ul>
<li><p>
<m>
\begin{bmatrix}
1 \amp 2 \amp 3 \amp 4
\end{bmatrix}
</m> is row 1,
</p></li>
<li><p>
<m>
\begin{bmatrix}
5 \amp 6 \amp 7 \amp 8
\end{bmatrix}
</m> is row 2 and
</p></li>
<li><p>
<m>
\begin{bmatrix}
9 \amp 10\amp 11\amp 12
\end{bmatrix}
</m>
is row 3.
</p></li>
</ul>
</p>
<p>Similarly, the matrix has 4 columns:
<ul>
<li><p>
<m>
\begin{bmatrix}
1\\ 5\\ 9
\end{bmatrix}
</m>
is column <m>1</m>
</p></li>
<li><p>
<m>
\begin{bmatrix}
2\\ 6\\ 10
\end{bmatrix}
</m>
is column <m>2</m>
</p></li>
<li><p>
<m>
\begin{bmatrix}
3 \\ 7\\ 11
\end{bmatrix}
</m>
is column <m>3</m>, and
</p></li>
<li><p>
<m>
\begin{bmatrix}
4\\ 8\\ 12
\end{bmatrix}
</m>
is column <m>4</m>
</p></li>
</ul>
</p>
<p>We call a matrix with 3 rows and 4 columns a <m>3\times4</m>
matrix.</p>
<p>More generally, a matrix with <m>m</m> rows and <m>n</m> columns is called an
<m>m\times n</m> <em>matrix</em>. An <m>m\times n</m> matrix <m>A</m> has the form
<me>
A=\begin{bmatrix}
a_{1,1} \amp a_{1,2} \amp \cdots \amp a_{1,n}\\
a_{2,1} \amp a_{2,2} \amp \cdots \amp a_{2,n}\\
\amp \amp \vdots\\
a_{m,1} \amp a_{m,2} \amp \cdots \amp a_{m,n}
\end{bmatrix}
</me>
This notation means that <m>a_{i,j}</m> is the number in both row
<m>i</m> and column <m>j</m>. We will call the rows
<m>R_1, R_2,\ldots,R_m</m> and the columns <m>C_1, C_2, \ldots,C_n</m>.
In other words,
<me>
R_i =\begin{bmatrix} a_{i,1} \amp a_{i,2} \amp a_{i,3}, \amp \cdots \amp a_{i,n}\end{bmatrix},
</me>
and
<me>
C_j=\begin{bmatrix}
a_{1,j}\\ a_{2,j}\\ a_{3,j}\\ \vdots\\ a_{m,j}
\end{bmatrix}
</me>
The notation for this matrix is similar to that used for
a system of linear equations, and for good reason. Suppose
we have a system of <m>m</m> linear equations in <m>n</m> unknowns:
<me>
\begin{array}{lcl}
a_{1,1}x_1 + a_{1,2}x_2 +{} \amp \cdots \amp {}+ a_{1,n}x_n = b_1\\
a_{2,1}x_1 + a_{2,2}x_2 +{} \amp \cdots \amp {}+ a_{2,n}x_n = b_2\\
\amp \vdots\\
a_{m,1}x_1 + a_{m,2}x_2 +{} \amp \cdots \amp {}+ a_{m,n}x_n = b_m
\end{array}
</me>
The <em>coefficient matrix</em> <m>A</m> is then the <m>m\times n</m> matrix
<me>
A=\begin{bmatrix}
a_{1,1} \amp a_{1,2} \amp \cdots \amp a_{1,n}\\
a_{2,1} \amp a_{2,2} \amp \cdots \amp a_{2,n}\\
\amp \amp \vdots\\
a_{m,1} \amp a_{m,2} \amp \cdots \amp a_{m,n}
\end{bmatrix}
</me>
and the <em>augmented matrix</em> of the system is the <m>m\times( n+1)</m> matrix
<me>
A=\begin{bmatrix}
a_{1,1} \amp a_{1,2} \amp \cdots \amp a_{1,n}\amp b_1\\
a_{2,1} \amp a_{2,2} \amp \cdots \amp a_{2,n}\amp b_2\\
\amp \amp \vdots\amp \amp \\
a_{m,1} \amp a_{m,2} \amp \cdots \amp a_{m,n}\amp b_m
\end{bmatrix}
</me>
Hence the augmented is the coefficient matrix with one column (the constants on the
right side of the equations) added. To emphasize the extra column, the augmented
matrix is sometimes written as
<me>
A=\left[\begin{array}{llcl|l}
a_{1,1} \amp a_{1,2} \amp \cdots \amp a_{1,n}\amp b_1\\
a_{2,1} \amp a_{2,2} \amp \cdots \amp a_{2,n}\amp b_2\\
\amp \amp \vdots\amp \amp \\
a_{m,1} \amp a_{m,2} \amp \cdots \amp a_{m,n}\amp b_m
\end{array}\right]
</me></p>
<p>Here are some examples of coefficient matrices and augmented matrices:
<ul>
<li><p>A system of 2 equations in 3 unknowns:
<md>
<mrow>x-y+z \amp = 1</mrow>
<mrow>2x+3y-z \amp = 2</mrow>
</md>
Coefficient matrix:
<me>
\begin{bmatrix}
1\amp -1\amp 1\\
2\amp 3\amp -1
\end{bmatrix}
</me>
Augmented matrix:
<me>
\begin{bmatrix}
1\amp -1\amp 1\amp 1\\
2\amp 3\amp -1\amp 2
\end{bmatrix}
</me>
</p></li>
<li>
<p>A system of 3 equations in 2 unknowns:
<md>
<mrow>u+v \amp = 1</mrow>
<mrow>2u+v \amp = 3</mrow>
<mrow>u+2v \amp =3</mrow>
</md>
</p>
<p>Coefficient matrix: <m>\begin{bmatrix}
1\amp 1\\
2\amp 1\\
1\amp 2
\end{bmatrix}</m></p>
<p>Augmented matrix: <m>\left[\begin{array}{cc|c}
1\amp 1\amp 1\\
2\amp 1\amp 3\\
1\amp 2\amp 3
\end{array}\right]</m></p>
</li>
<li><p>A system of 4 equations in 5 unknowns</p>
<p>
<md>
<mrow>x_1\amp + \amp x_2 \amp \amp \amp \amp \amp \amp \amp =1</mrow>
<mrow>\amp \amp x_2 \amp +\amp x_3 \amp \amp \amp \amp \amp =2</mrow>
<mrow>\amp \amp \amp \amp x_3 \amp +\amp x_4 \amp \amp \amp = 3</mrow>
<mrow>\amp \amp \amp \amp \amp \amp x_4 \amp +\amp x_5 \amp =4</mrow>
</md>
</p>
<p>Coefficient matrix: <m>\begin{bmatrix}
\begin{array}{rrrrr}
1\amp 1\amp 0\amp 0\amp 0\\
0\amp 1\amp 1\amp 0\amp 0\\
0\amp 0\amp 1\amp 1\amp 0\\
0\amp 0\amp 0\amp 1\amp 1
\end{array}
\end{bmatrix}</m></p>
<p>Augmented matrix: <m>\left[\begin{array}{ccccc|c}
1\amp 1\amp 0\amp 0\amp 0\amp 1\\
0\amp 1\amp 1\amp 0\amp 0\amp 2\\
0\amp 0\amp 1\amp 1\amp 0\amp 3\\
0\amp 0\amp 0\amp 1\amp 1\amp 4
\end{array}\right]</m></p></li>
</ul>
</p>
</subsection>
<subsection><title>Exercises</title>
<!-- <exercises> -->
<exercise>
<statement>
<p>Which of the following equations are linear?
<ol>
<li> <p><m>x+y-z^2=0</m></p></li>
<li> <p><m>2x+yz=1</m></p></li>
<li> <p><m>z=3</m></p></li>
<li> <p><m>\pi^2 x-\sqrt[3]{3}y=8\sqrt{5}</m></p></li>
<li> <p><m>3x-4y=\frac73 z-5+t</m></p></li>
<li> <p><m>\cos{x}=3y+2z</m></p></li>
</ol></p>
</statement>
<solution>
<p>
<ol>
<li><p>Not linear because of <m>z^2</m></p></li>
<li><p>Not linear because of <m>yz</m></p></li>
<li><p>Linear</p></li>
<li><p>Linear (the exponents involve the constants, but not the variables)</p></li>
<li><p>Linear (Tricky because variables are on both sides of the equal sign.
It is the same as <m>3x-4y-\frac73 z-t =-5 </m>.)</p></li>
<li><p>Not linear because of the <m>\cos</m> function</p></li>
</ol>
</p>
</solution>
</exercise>
<exercise>
<statement>
<p>Consider the following system of linear equations:
<me>
2x-4y+z=-1\\
3x-3y+z=1
</me>
Which of the following are solutions to this system
<ul>
<li><p><m> (x,y,z)=(2,1,-1) </m></p></li>
<li><p><m> (x,y,z)=(1,1,1) </m></p></li>
<li><p><m> (x,y,z)=(0,0,1) </m></p></li>
</ul>
</p>
</statement>
<solution>
<p>
<ul>
<li><p>
Substitute <m> (x,y,z)=(2,1,-1) </m> into the equations:
<me>
2x-4y+z=4-4-1=-1\\
3x-3y+z=6-3-1=2 \not=1
</me>
and so <m>(2,1,-1)</m> is <em>not</em> a solution.
</p></li>
<li><p> Substitute <m> (x,y,z)=(1,1,1) </m> into the equations:
<me>
2x-4y+z=2-4+1=-1\\
3x-3y+z=3-3+1=1
</me>
and so <m>(1,1,1)</m> <em>is</em> a solution.
</p></li>
<li><p> Substitute <m> (x,y,z)=(0,0,1) </m> into the equations:
<me>
2x-4y+z=0+0+1\not=-1\\
3x-3y+z=0+0+1=1
</me>
and so <m>(0,0,1)</m> is <em>not</em> a solution.
</p></li>
</ul></p>
</solution>
</exercise>
<exercise>
<statement>
<p>
Give a system of two equations in two unknowns that has <m>(1,2)</m>
as its unique solution.
</p>
</statement>
<solution>
<p>
There are many solutions corresponding to two lines intersecting
at <m>(1,2)</m>. Surely the easiest is
<md>
<mrow>x\amp=1</mrow>
<mrow>y\amp=2</mrow>
</md>
</p>
</solution>
</exercise>
<exercise>
<statement>
<p>
Give the coefficient matrix and the augmented matrix this system of
linear equations:
<md>
<mrow>x+y \amp= 2 </mrow>
<mrow>x-y \amp= 0 </mrow>
</md>
</p>
</statement>
<solution>
<p>
<m>
\begin{bmatrix}
1\amp1\\1\amp-1
\end{bmatrix}
</m>
and
<m>
\left[\begin{array}{cc|c}
1 \amp 1 \amp 2 \\ 1 \amp -1 \amp 0
\end{array}\right]
</m>
</p>
</solution>
</exercise>
<exercise>
<statement>
<p>
Give the coefficient matrix and the augmented matrix this system of
linear equations:
<md>
<mrow>x_1+x_2-x_3+x_5\amp= 4 </mrow>
<mrow>2x_1-3x_2 +x_4\amp= 7 </mrow>
</md>
</p>
</statement>
<solution>
<p>
<m>
\begin{bmatrix}
1 \amp 1 \amp -1 \amp 0 \amp 1 \\
2\amp-3 \amp 0 \amp 1 \amp 0
\end{bmatrix}
</m>
and
<m>
\left[\begin{array}{ccccc|c}
1 \amp 1 \amp -1 \amp 0 \amp 1 \amp 4\\
2\amp-3 \amp 0 \amp 1 \amp 0 \amp7
\end{array}\right]
</m>
</p>
</solution>
</exercise>
<exercise>
<statement>
<p>
Give the coefficient matrix and the augmented matrix this system of
linear equations:
<md>
<mrow>x+y-z \amp=1</mrow>
<mrow>3x+y\amp= 2</mrow>
<mrow>y+z \amp=3</mrow>
<mrow>x+z\amp=4</mrow>
<mrow>x+y+z\amp=5</mrow>
</md>
</p>
</statement>
<solution>
<p>
<m>
\begin{bmatrix}
1 \amp 1 \amp -1 \\
3 \amp 1\amp 0 \\
0 \amp 1 \amp 1\\
1 \amp 0 \amp 1 \\
1 \amp 1 \amp 1
\end{bmatrix}
</m>
and
<m>
\left[\begin{array}{ccc|c}
1 \amp 1 \amp -1 \amp 1\\
3 \amp 1\amp 0 \amp 2\\
0 \amp 1 \amp 1\amp 3\\
1 \amp 0 \amp 1 \amp 4\\
1 \amp 1 \amp 1\amp 5
\end{array}\right]
</m>
</p>
</solution>
</exercise>
<exercise>
<statement>
<p>
Give the system of equations whose augmented matrix is
<me>
\left[\begin{array}{cc|c}
1 \amp 4 \amp 1\\
3 \amp -2\amp 0 \\
0 \amp 1 \amp 1\\
-1 \amp 1 \amp 3
\end{array}\right]
</me>
</p>
</statement>
<solution>
<p>
<md>
<mrow>x+4y\amp= 1</mrow>
<mrow>3x-2y\amp=0</mrow>
<mrow>y\amp=1</mrow>
<mrow>-x+y\amp=3</mrow>
</md>
</p>
</solution>
</exercise>
<exercise>
<statement>
<p>
There is a special matrix <m>I_n</m> called the identity
matrix. It has <m>n</m> rows and <m>n</m> columns. The entries <m>a_{i,j}</m>
of the matrix satisfy
<me>
a_{i,j}=
\begin{cases}
1 \amp \text{if } i=j\\
0 \amp \text{if } i\not=j\\
\end{cases}
</me>
<ol>
<li><p>
Show the the matrix <m>I_n</m> has the value <m>1</m> along the (main) diagonal going from the upper
left corner to the lower right corner of the matrix, and has the value <m>0</m> elsewhere.
</p></li>
<li><p>Suppose that a system of linear equations has an augmented matrix of the form
<me>
\left[ I_n \mid B \right]
</me>
where
<me>
B= \begin{bmatrix}
b_1\\b_2\\ \vdots\\b_n
\end{bmatrix}
</me>
What does the say about the number of variables (unknowns)
for the corresponding system of linear equations, and
what does it say about the solutions to the system?
</p>
</li>
</ol>
</p>
</statement>
<solution>
<p>
<ol>
<li>
<p>
When <m>i=j</m>, the row number and column number are identical, and so the entry
<m>a_{i.j}</m> is on the diagonal. This implies that
<me>
a_{i,j}=
\begin{cases}
1 \amp \text{ for entries on the main diagonal}\\
0 \amp \text{ for entries not on the main diagonal} \\
\end{cases}
</me>
</p>
</li>
<li>
<p>
The number of unknowns is <m>n</m>, the number of columns in the matrix.
We may call them <m>x_1, x_2,\dots,x_n</m>.
The augmented matrix now says that
<md>
<mrow>x_1\amp =b_1</mrow>
<mrow>x_2\amp =b_2</mrow>
<mrow>\amp \vdots</mrow>
<mrow>x_n\amp =b_n</mrow>
</md>
</p>
</li>
</ol>
</p>
</solution>
</exercise>
<!-- </exercises> -->
</subsection>
</section>
<section><title>Elementary row operations</title>
<introduction>
<p>
Gaussian elimination, which we shall describe in detail
presently, is an algorithm (a well-defined procedure for computation
that eventually completes) that finds all solutions to any <m>m\times n</m> system
of linear equations. It is defined via certain operations carried out
on the augmented matrix. These operations change the matrix (and hence
the system of linear equations associated with it), <em>but they leave the
set of solutions unchanged</em>. There are three of them, which we now describe.
</p></introduction>
<subsection><title>Interchanging two rows</title>
<p>
Exchanging two rows in the augmented matrix is the same as writing the the equations
in a different order. The equations themselves are unchanged, as is the set of all
solutions. When we interchange row <m>i</m> and row <m>j</m>, we denote it by
<m>R_i\leftrightarrow R_j</m>.
</p>
<example><title>Augmented matrix change (interchange rows)</title>
<p>The system of equations
<me>
\begin{array}{rl}
2x+3y-z \amp = 2\\
-x+y+z \amp =4\\
3x-y-z \amp = 3
\end{array}
</me>
corresponds to the augmented matrix
<me>
\left[\begin{array}{ccc|c}
2 \amp 3 \amp -1 \amp 2\\
-1 \amp 1 \amp 1 \amp 4\\
3 \amp -1 \amp -1 \amp 3
\end{array}\right]
</me>
Now we interchange rows 1 and 3 (<m>R_1\leftrightarrow R_3</m>) to get
the matrix
<me>
\left[\begin{array}{ccc|c}
3 \amp -1 \amp -1 \amp 3\\
-1 \amp 1 \amp 1 \amp 4\\
2 \amp 3 \amp -1 \amp 2
\end{array}\right]
</me>
which corresponds to the equations
<me>
\begin{array}{rl}
3x-y-z \amp = 3\\
-x+y+z \amp =4\\
2x+3y-z \amp = 2
\end{array}
</me>
</p>
</example>
</subsection>
<subsection><title>Multiplying a row by a nonzero constant</title>
<p>
If we have a linear equation and multiply both sides of the equation by a nonzero
constant <m>\lambda</m> (the Greek letter lambda (<m>\lambda</m>)
is the traditional name for the constant) then the linear equation
<me>
a_1x_1 + a_2x_2 +a_3x_3 + \cdots + a_nx_n =b
</me>
becomes
<me>
\lambda(a_1x_1 + a_2x_2 +a_3x_3 + \cdots + a_nx_n) =\lambda b
</me>
and so
<me> \lambda a_1x_1 + \lambda a_2x_2 +\lambda a_3x_3 + \cdots +\lambda a_nx_n =\lambda b.
</me>
This would apply to any equation in a system, of course,
and so when we apply this operation to row <m>i</m> we denote it by
<m>R_i \gets \lambda R_i</m> (The symbol <m>\gets</m> means <em>is replaced by</em>).
<em>As long as <m>\lambda</m> is nonzero</em>, this operation leaves the set of solutions unchanged.
</p>
<example><title>Augmented matrix change (multiply row by <m>\lambda</m>)</title>
<p>The system of equations
<me>
\begin{array}{rl}
2x+3y-z \amp = 2\\
-x+y+z \amp =4\\
3x-y-z \amp = 3
\end{array}
</me>
corresponds to the augmented matrix
<me>
\begin{bmatrix}
2 \amp 3 \amp -1 \amp 2\\
-1 \amp 1 \amp 1 \amp 4\\
3 \amp -1 \amp -1 \amp 3
\end{bmatrix}
</me>
Now we multiply row <m>2</m> by <m>\lambda=-3</m> (<m>R_2\gets -3R_2</m>) to get
the matrix
<me>
\begin{bmatrix}
2 \amp 3 \amp -1 \amp 2\\
3 \amp -3 \amp -3 \amp -12\\
3 \amp -1 \amp -1 \amp 3
\end{bmatrix}
</me>
which corresponds to the system of equations
<me>
\begin{array}{rl}
2x+3y-z \amp = 2\\
3x-3y-3z \amp =-12\\
3x-y-z \amp = 3
\end{array}
</me>
</p>
</example>
</subsection>
<subsection><title>Adding a multiple of one row to another</title>
<p>Recall that one of our basic techniques for solving a
system of equations is to pick a variable,
make the coefficients of that variable equal in two equations
and then take the difference of the equations
to create a new one with the variable eliminated. In terms of
the associated augmented matrix, this means we get a new row
formed by subtracting the corresponding entries in the rows of
the two equations. In other words, we replace one row by the
difference of two rows. We use the notation <m>R_i\gets R_i-R_j</m>
to indicate that row <m>i</m> is replaced by the difference of
row <m>i</m> and row <m>j</m>. The set of solutions is unchanged. We
have already seen that multiplying a row by a nonzero constants
leaves the set of solutions unchanged; it is often convenient to
combine these two steps as one: <m>R_i\gets R_i+\lambda R_j.</m>
Note that <m>\lambda=-1</m> is the case of subtracting one row
from another.</p>
<example><title>Augmented matrix change (add multiple of one
row to another)</title>
<p>Eliminating <m>x</m> from the second
equation:
<me>
\begin{array}{rl}
-x+y+z \amp =4\\
2x+3y-z \amp = 2\\
3x-y-z \amp = 3
\end{array}
</me>
corresponds to the
augmented matrix
<me>
\begin{bmatrix}
-1 \amp 1 \amp 1 \amp 4\\
2 \amp 3 \amp -1 \amp 2\\
3 \amp -1 \amp -1 \amp 3
\end{bmatrix}
</me>
Now we replace row 2 by the sum of row 2 and twice row 1
<m>(R_2\gets R_2+2R_1)</m> to get the matrix
<me>
\begin{bmatrix}
-1 \amp 1 \amp 1 \amp 4\\
0 \amp 5 \amp 1 \amp 10\\
3 \amp -1 \amp -1 \amp 3
\end{bmatrix}
</me>
which corresponds to the system of linear equations
<me>
\begin{array}{rl} -
x+y+z
\amp =4\\