This repository has been archived by the owner on Aug 6, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 172
/
subspaces.xml
619 lines (545 loc) · 29.8 KB
/
subspaces.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
<?xml version="1.0" encoding="UTF-8"?>
<!--********************************************************************
Copyright 2017 Georgia Institute of Technology
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.3 or
any later version published by the Free Software Foundation. A copy of
the license is included in gfdl.xml.
*********************************************************************-->
<section xml:id="subspaces">
<title>Subspaces</title>
<objectives>
<ol>
<li>Learn the definition of a subspace.</li>
<li>Learn to determine whether or not a subset is a subspace.</li>
<li>Learn the most important examples of subspaces.</li>
<li>Learn to write a given subspace as a column space or null space.</li>
<li><em>Recipe:</em> compute a spanning set for a null space.</li>
<li><em>Picture:</em> whether a subset of <m>\R^2</m> or <m>\R^3</m> is a subspace or not.</li>
<li><em>Vocabulary words:</em> <term>subspace</term>, <term>column space</term>, <term>null space</term>.</li>
</ol>
</objectives>
<introduction>
<p>
In this section we discuss <em>subspaces</em> of <m>\R^n</m>. A subspace turns out to be exactly the same thing as a span, except we don<rsq/>t have a particular set of spanning vectors in mind. This change in perspective is quite useful, as it is easy to produce subspaces that are not obviously spans. For example, the solution set of the equation <m>x + 3y + z = 0</m> is a span because the equation is homogeneous, but we would have to compute the parametric vector form in order to write it as a span.
<latex-code>
<![CDATA[
\begin{tikzpicture}[myxyz, z={(0cm,0.8cm)}, scale=.75]
\def\v{(2,-1,1)}
\def\w{(1,0,-1)}
\node[coordinate] (X) at \v {};
\node[coordinate] (Y) at \w {};
\begin{scope}[x=(X), y=(Y), transformxy]
\fill[seq4!30, nearly opaque] (-1,-1.5) rectangle (1,1.5);
\draw[step=.5cm, seq4!50, very thin] (-1,-1.5) grid (1,1.5);
\end{scope}
\node[seq4, resetxy, right] at (3.5, 0) {$x+3y+z=0$};
\point at (0,0,0);
\end{tikzpicture}
]]>
</latex-code>
(A subspace also turns out to be the same thing as the solution set of a homogeneous system of equations.)
</p>
</introduction>
<subsection>
<title>Subspaces: Definition and Examples</title>
<definition>
<idx><h>Subset</h><h>definition of</h></idx>
<statement>
<p>A <term>subset</term> of <m>\R^n</m> is any collection of points of <m>\R^n</m>.</p>
</statement>
</definition>
<p>
For instance, the unit circle
<me>C = \bigl\{ (x,y)\text{ in }\R^2 \bigm| x^2 + y^2 = 1 \bigr\}</me>
is a subset of <m>\R^2</m>.
</p>
<p>
Above we expressed <m>C</m> in <xref ref="set-builder-notation" text="title">set builder notation</xref>: in English, it reads <q><m>C</m> is the set of all ordered pairs <m>(x,y)</m> in <m>\R^2</m> such that <m>x^2+y^2=1</m>.</q>
</p>
<definition xml:id="subspaces-defn-of">
<idx><h>Subspace</h><h>definition of</h></idx>
<statement>
<p>
A <term>subspace</term> of <m>\R^n</m> is a subset <m>V</m> of <m>\R^n</m> satisfying:
<ol>
<li><alert>Non-emptiness:</alert> The zero vector is in <m>V</m>.</li>
<li><alert>Closure under addition:</alert> If <m>u</m> and <m>v</m> are in <m>V</m>, then <m>u+v</m> is also in <m>V</m>.</li>
<li><alert>Closure under scalar multiplication:</alert> If <m>v</m> is in <m>V</m> and <m>c</m> is in <m>\R</m>, then <m>cv</m> is also in <m>V</m>.</li>
</ol>
</p>
</statement>
</definition>
<p>As a consequence of these properties, we see:
<ul>
<li>If <m>v</m> is a vector in <m>V</m>, then all scalar multiples of <m>v</m> are in <m>V</m> by the third property. In other words the line through any nonzero vector in <m>V</m> is also contained in <m>V</m>.</li>
<li>If <m>u,v</m> are vectors in <m>V</m> and <m>c,d</m> are scalars, then <m>cu,dv</m> are also in <m>V</m> by the third property, so <m>cu+dv</m> is in <m>V</m> by the second property. Therefore, all of <m>\Span\{u,v\}</m> is contained in <m>V</m></li>
<li>Similarly, if <m>v_1,v_2,\ldots,v_n</m> are all in <m>V</m>, then <m>\Span\{v_1,v_2,\ldots,v_n\}</m> is contained in <m>V</m>. In other words, <em>a subspace contains the span of any vectors in it.</em></li>
</ul>
If you choose enough vectors, then eventually their span will fill up <m>V</m>, so we already see that a <em>subspace is a span</em>. See this <xref ref="subspaces-spans-are-subspaces"/> below for a precise statement.
</p>
<remark>
<p>Suppose that <m>V</m> is a non-empty subset of <m>\R^n</m> that satisfies properties 2 and 3. Let <m>v</m> be any vector in <m>V</m>. Then <m>0v = 0</m> is in <m>V</m> by the third property, so <m>V</m> automatically satisfies property 1. It follows that the only subset of <m>\R^n</m> that satisfies properties 2 and 3 but <em>not</em> property 1 is the empty subset <m>\{\}</m>. This is why we call the first property <q>non-emptiness</q>.
</p>
</remark>
<specialcase>
<idx><h>Real <m>n</m>-space</h><h>as a subspace of itself</h></idx>
<idx><h>Subspace</h><h>real <m>n</m>-space</h></idx>
<p>The set <m>\R^n</m> is a subspace of itself: indeed, it contains zero, and is closed under addition and scalar multiplication.</p>
</specialcase>
<specialcase>
<idx><h>Subspace</h><h>zero</h></idx>
<p>The set <m>\{0\}</m> containing only the zero vector is a subspace of <m>\R^n</m>: it contains zero, and if you add zero to itself or multiply it by a scalar, you always get zero.</p>
</specialcase>
<example>
<title>A line through the origin</title>
<p>A line <m>L</m> through the origin is a subspace.
<latex-code>
\begin{tikzpicture}
\draw[seq4] (-3,-1) -- (3,1);
\draw[vector] (0,0) -- (1,1/3);
\point at (0,0);
\node[seq4] at (0,.5) {$L$};
\end{tikzpicture}
</latex-code>
Indeed, <m>L</m> contains zero, and is easily seen to be closed under addition and scalar multiplication.
</p>
</example>
<example>
<title>A plane through the origin</title>
<p>A plane <m>P</m> through the origin is a subspace.
<latex-code>
\begin{tikzpicture}[myxyz]
\def\v{(-1,2,1)}
\def\w{(0,1,-1)}
\node[coordinate] (X) at \v {};
\node[coordinate] (Y) at \w {};
\begin{scope}[x=(X), y=(Y), transformxy]
\fill[seq4!30, nearly opaque] (-1,-1) rectangle (1,1);
\draw[step=.5cm, seq4!50, very thin] (-1,-1) grid (1,1);
\end{scope}
\draw[vector] (0,0,0) -- ($.5*(X)$);
\draw[vector] (0,0,0) -- ($.5*(Y)$);
\point at (0,0,0);
\node[x=(X),y=(Y),seq4] at (.2,-1.4) {$P$};
\end{tikzpicture}
</latex-code>
Indeed, <m>P</m> contains zero; the sum of two vectors in <m>P</m> is also in <m>P</m>; and any scalar multiple of a vector in <m>P</m> is also in <m>P</m>.
</p>
</example>
<example hide-type="true">
<title>Non-example (A line not containing the origin)</title>
<p>A line <m>L</m> (or any other subset) that does not contain the origin is not a subspace. It fails the first defining property: <em>every subspace contains the origin</em> by definition.
<latex-code>
\begin{tikzpicture}
\draw[seq4] (-3,-1) -- (3,1);
\point at (0,-.5);
\point[red] at (0,-.5);
\end{tikzpicture}
</latex-code>
</p>
</example>
<example hide-type="true">
<title>Non-example (A circle)</title>
<p>The unit circle <m>C</m> is not a subspace. It fails all three defining properties: it does not contain the origin, it is not closed under addition, and it is not closed under scalar multiplication. In the picture, one red vector is the sum of the two black vectors (which are contained in <m>C</m>), and the other is a scalar multiple of a black vector.
<latex-code>
\begin{tikzpicture}
\draw[seq4] (0,0) circle [radius=2cm];
\draw[vector,red] (0,0) -- (2.5,0);
\draw[vector] (0,0) -- (0,2);
\draw[vector] (0,0) -- (2,0);
\draw[vector,red] (0,0) -- (2,2);
\point at (0,0);
\point[red] at (0,0);
\end{tikzpicture}
</latex-code>
</p>
</example>
<example hide-type="true">
<title>Non-example (The first quadrant)</title>
<p>The first quadrant in <m>\R^2</m> is not a subspace. It contains the origin and is closed under addition, but it is not closed under scalar multiplication (by negative numbers).
<latex-code>
\begin{tikzpicture}
\fill[seq4!20] (0,0) rectangle (2,2);
\draw[->] (-2,0) -- (2,0);
\draw[->] (0,-2) -- (0,2);
\draw[vector] (0,0) -- (1,1);
\draw[vector,red] (0,0) -- (-1,-1);
\point at (0,0);
\end{tikzpicture}
</latex-code>
</p>
</example>
<example hide-type="true">
<title>Non-example (A line union a plane)</title>
<p>The union of a line and a plane in <m>\R^3</m> is not a subspace. It contains the origin and is closed under scalar multiplication, but it is not closed under addition: the sum of a vector on the line and a vector on the plane is not contained in the line or in the plane.
<latex-code>
\begin{tikzpicture}[myxyz]
\path[clip, resetxy] (-4,-2) rectangle (4,2);
\draw[seq4] (-2,-1,-4) -- (0,0,0);
\begin{scope}[transformxy]
\fill[seq4!20, semitransparent] (-1.5,-1.5) rectangle (1.5,1.5);
\draw[step=.5cm, grid lines] (-1.5,-1.5) grid (1.5,1.5);
\end{scope}
\draw[seq4] (2,1,4) -- (0,0,0);
\draw[vector] (0,0,0) -- (.6,.3,1.2);
\draw[vector] (0,0,0) -- (0,1,0);
\draw[vector,red] (0,0,0) -- (.6,1.3,1.2);
\point at (0,0,0);
\end{tikzpicture}
</latex-code>
</p>
</example>
<bluebox>
<title>Subsets versus Subspaces</title>
<idx><h>Subspace</h><h>versus subset</h></idx>
<idx><h>Subset</h><h>versus subspace</h></idx>
<p>
A sub<em>set</em> of <m>\R^n</m> is any collection of vectors whatsoever. For instance, the unit circle
<me>C = \bigl\{ (x,y)\text{ in }\R^2 \bigm| x^2 + y^2 = 1 \bigr\}</me>
is a subset of <m>\R^2</m>, but it is not a subspace. In fact, all of the non-examples above are still subsets of <m>\R^n</m>. A subspace is a subset that happens to satisfy the three additional defining properties.
</p>
</bluebox>
<p>
In order to verify that a subset of <m>\R^n</m> is in fact a subspace, one has to check the three defining properties. That is, unless the subset has already been verified to be a subspace: see this <xref ref="subspace-is-col-or-nul"/> below.
</p>
<example xml:id="subspaces-eg-byhand">
<title>Verifying that a subset is a subspace</title>
<statement>
<p>
Let
<me> V = \left\{ \vec{a b} \text{ in } \R^2 \bigm| 2a = 3b\right\}.</me>
Verify that <m>V</m> is a subspace.
</p>
</statement>
<solution>
<p>
First we point out that the condition <q><m>2a = 3b</m></q> defines whether or not a vector is in <m>V</m>: that is, to say <m>{a\choose b}</m> is in <m>V</m> <em>means</em> that <m>2a = 3b</m>. In other words, a vector is in <m>V</m> if twice its first coordinate equals three times its second coordinate. So for instance, <m>{3\choose 2}</m> and <m>{1/2\choose 1/3}</m> are in <m>V</m>, but <m>{2\choose 3}</m> is not because <m>2\cdot 2\neq 3\cdot 3</m>.
</p>
<p>
Let us check the first property. The subset <m>V</m> does contain the zero vector <m>{0\choose 0}</m>, because <m>2\cdot 0 = 3\cdot 0</m>.
</p>
<p>
Next we check the second property. To show that <m>V</m> is closed under addition, we have to check that for <em>any</em> vectors <m>u = {a\choose b}</m> and <m>v = {c\choose d}</m> in <m>V</m>, the sum <m>u+v</m> is in <m>V</m>. Since we cannot assume anything else about <m>u</m> and <m>v</m>, we must treat them as <em>unknowns</em>.
</p>
<p>
We have
<me>\vec{a b} + \vec{c d} = \vec{a+c b+d}.</me>
To say that <m>a+c\choose b+d</m> is contained in <m>V</m> means that <m>2(a+c) = 3(b+d)</m>, or <m>2a + 2c = 3b + 3d</m>. The one thing we are allowed to assume about <m>u</m> and <m>v</m> is that <m>2a = 3b</m> and <m>2c = 3d</m>, so we see that <m>u+v</m> is indeed contained in <m>V</m>.
</p>
<p>
Next we check the third property. To show that <m>V</m> is closed under scalar multiplication, we have to check that for any vector <m>v = {a\choose b}</m> in <m>V</m> and any scalar <m>c</m> in <m>\R</m>, the product <m>cv</m> is in <m>V</m>. Again, we must treat <m>v</m> and <m>c</m> as unknowns. We have
<me>c\vec{a b} = \vec{ca cb}.</me>
To say that <m>ca\choose cb</m> is contained in <m>V</m> means that <m>2(ca) = 3(cb)</m>, i.e., that <m>c\cdot 2a = c\cdot 3b</m>. The one thing we are allowed to assume about <m>v</m> is that <m>2a = 3b</m>, so <m>cv</m> is indeed contained in <m>V</m>.
</p>
<p>
Since <m>V</m> satisfies all three defining properties, it is a subspace.
In fact, it is the line through the origin with slope <m>2/3</m>.
<latex-code>
\begin{tikzpicture}
\draw[help lines] (-3, -3) grid (3, 3);
\draw[seq4] (-3,-2) -- (3,2);
\point at (0,0);
\node[seq4] at (1.5,.7) {$V$};
\end{tikzpicture}
</latex-code>
</p>
</solution>
</example>
<example>
<title>Showing that a subset is not a subspace</title>
<statement>
<p>
Let
<me>V = \left\{ \vec{a b} \text{ in } \R^2\bigm| ab=0 \right\}.</me>
Is <m>V</m> a subspace?
</p>
</statement>
<solution>
<p>
First we point out that the condition <q><m>ab=0</m></q> defines whether or not a vector is in <m>V</m>: that is, to say <m>{a\choose b}</m> is in <m>V</m> <em>means</em> that <m>ab=0</m>. In other words, a vector is in <m>V</m> if the product of its coordinates is zero, i.e., if one (or both) of its coordinates are zero. So for instance, <m>{1\choose 0}</m> and <m>{0\choose 2}</m> are in <m>V</m>, but <m>{1\choose 1}</m> is not because <m>1\cdot 1\neq 0</m>.
</p>
<p>
Let us check the first property. The subset <m>V</m> does contain the zero vector <m>{0\choose 0}</m>, because <m>0\cdot 0=0</m>.
</p>
<p>
Next we check the third property. To show that <m>V</m> is closed under scalar multiplication, we have to check that for <em>any</em> vector <m>v = {a\choose b}</m> in <m>V</m> and <em>any</em> scalar <m>c</m> in <m>\R</m>, the product <m>cv</m> is in <m>V</m>. Since we cannot assume anything else about <m>v</m> and <m>c</m>, we must treat them as <em>unknowns</em>.
</p>
<p>
We have
<me>c\vec{a b} = \vec{ca cb}.</me>
To say that <m>ca\choose cb</m> is contained in <m>V</m> means that <m>(ca)(cb)=0</m>. Rewriting, this means <m>c^2(ab)=0</m>. The one thing we are allowed to assume about <m>v</m> is that <m>ab=0</m>, so we see that <m>cv</m> is indeed contained in <m>V</m>.
</p>
<p>
Next we check the second property. It turns out that <m>V</m> is not closed under addition; to verify this, we must show that there exists <em>some</em> vectors <m>u,v</m> in <m>V</m> such that <m>u+v</m> is not contained in <m>V</m>. The easiest way to do so is to produce examples of such vectors. We can take <m>u={1\choose 0}</m> and <m>v={0\choose 1}</m>; these are contained in <m>V</m> because the products of their coordinates are zero, but
<me>\vec{1 0} + \vec{0 1} = \vec{1 1}</me>
is not contained in <m>V</m> because <m>1\cdot 1\neq 0</m>.
</p>
<p>
Since <m>V</m> does not satisfy the second property (it is not closed under addition), we conclude that <m>V</m> is <em>not</em> a subspace. Indeed, it is the union of the two coordinate axes, which is not a span.
<latex-code>
\begin{tikzpicture}[scale=3]
\draw[grid lines, step=.25] (-1,-1) grid (1,1);
\draw[seq4, <->, thick] (-1,0) -- (1,0);
\draw[seq4, <->, thick] (0,-1) -- (0,1);
\node[seq4] at (.25,.25) {$V$};
\end{tikzpicture}
</latex-code>
</p>
</solution>
</example>
</subsection>
<subsection>
<title>Common Types of Subspaces</title>
<theorem xml:id="subspaces-spans-are-subspaces">
<title>Spans are Subspaces and Subspaces are Spans</title>
<idx><h>Subspace</h><h>and spans</h></idx>
<idx><h>Span</h><h>is a subspace</h></idx>
<idx><h>Subspace</h><h>is a span</h></idx>
<statement>
<p>
If <m>v_1,v_2,\ldots,v_p</m> are any vectors in <m>\R^n</m>, then <m>\Span\{v_1,v_2,\ldots,v_p\}</m> is a subspace of <m>\R^n</m>. Moreover, any subspace of <m>\R^n</m> can be written as a span of a set of <m>p</m> linearly independent vectors in <m>\R^n</m> for <m>p\leq n</m>.
</p>
</statement>
<proof>
<p>To show that <m>\Span\{v_1,v_2,\ldots,v_p\}</m> is a subspace, we have to verify the three defining properties.
<ol>
<li>The zero vector <m>0 = 0v_1 + 0v_2 + \cdots + 0v_p</m> is in the span.</li>
<li>
If <m>u = a_1v_1 + a_2v_2 + \cdots + a_pv_p</m> and
<m>v = b_1v_1 + b_2v_2 + \cdots + b_pv_p</m> are in <m>\Span\{v_1,v_2,\ldots,v_p\}</m>, then
<me>u + v = (a_1+b_1)v_1 + (a_2+b_2)v_2 + \cdots + (a_p+b_p)v_p</me>
is also in <m>\Span\{v_1,v_2,\ldots,v_p\}</m>.
</li>
<li>
If <m>v = a_1v_1 + a_2v_2 + \cdots + a_pv_p</m> is in <m>\Span\{v_1,v_2,\ldots,v_p\}</m> and <m>c</m> is a scalar, then
<me>cv = ca_1v_1 + ca_2v_2 + \cdots + ca_pv_p</me>
is also in <m>\Span\{v_1,v_2,\ldots,v_p\}</m>.
</li>
</ol>
Since <m>\Span\{v_1,v_2,\ldots,v_p\}</m> satisfies the three defining properties of a subspace, it is a subspace.
</p>
<p>
Now let <m>V</m> be a subspace of <m>\R^n</m>. If <m>V</m> is the zero subspace, then it is the span of the empty set, so we may assume <m>V</m> is nonzero. Choose a nonzero vector <m>v_1</m> in <m>V</m>. If <m>V = \Span\{v_1\}</m>, then we are done. Otherwise, there exists a vector <m>v_2</m> that is in <m>V</m> but not in <m>\Span\{v_1\}</m>. Then <m>\Span\{v_1,v_2\}</m> is contained in <m>V</m>, and by the <xref ref="linindep-increasing-span">increasing span criterion</xref>, the set <m>\{v_1,v_2\}</m> is linearly independent. If <m>V = \Span\{v_1,v_2\}</m> then we are done. Otherwise, we continue in this fashion until we have written <m>V = \Span\{v_1,v_2,\ldots,v_p\}</m> for some linearly independent set <m>\{v_1,v_2,\ldots,v_p\}</m>. This process terminates after at most <m>n</m> steps by this <xref ref="linindep-wide-matrix"/>.
</p>
</proof>
</theorem>
<p>If <m>V = \Span\{v_1,v_2,\ldots,v_p\}</m>, we say that <m>V</m> is the subspace <term>spanned by</term> or <term>generated by</term> the vectors <m>v_1,v_2,\ldots,v_p</m>. We call <m>\{v_1,v_2,\ldots,v_p\}</m> a <term>spanning set</term> for <m>V</m>.</p>
<p>Any matrix naturally gives rise to <em>two</em> subspaces.</p>
<definition>
<idx><h>Column space</h><h>definition of</h></idx>
<idx><h>Null space</h><h>definition of</h></idx>
<notation><usage>\Col(A)</usage><description>Column space</description></notation>
<notation><usage>\Nul(A)</usage><description>Null space</description></notation>
<statement>
<p>Let <m>A</m> be an <m>m\times n</m> matrix.
<ul>
<li>
The <term>column space</term> of <m>A</m> is the subspace of <m>\R^m</m> spanned by the columns of <m>A</m>. It is written <m>\Col(A)</m>.
</li>
<li>
The <term>null space</term> of <m>A</m> is the subspace of <m>\R^n</m> consisting of all solutions of the homogeneous equation <m>Ax=0</m>:
<me>\Nul(A) = \bigl\{ x \text{ in } \R^n\bigm| Ax=0 \bigr\}.</me>
</li>
</ul>
</p>
</statement>
</definition>
<p>
<idx><h>Column space</h><h>is a subspace</h></idx>
The column space is defined to be a span, so it is a subspace by the above <xref ref="subspaces-spans-are-subspaces"/>. We need to verify that the null space is really a subspace. In <xref ref="solution-sets"/> we already saw that the set of solutions of <m>Ax=0</m> is always a span, so the fact that the null spaces is a subspace should not come as a surprise.
</p>
<proof>
<idx><h>Null space</h><h>is a subspace</h></idx>
<p>
We have to verify the three defining properties. To say that a vector <m>v</m> is in <m>\Nul(A)</m> <em>means</em> that <m>Av = 0</m>.
<ol>
<li>
The zero vector is in <m>\Nul(A)</m> because <m>A0=0</m>.
</li>
<li>
Suppose that <m>u,v</m> are in <m>\Nul(A)</m>. This means that
<m>Au=0</m> and <m>Av=0</m>. Hence
<me> A(u+v) = Au + Av = 0 + 0 = 0 </me>
by the <xref ref="matrix-linearity">linearity of the matrix-vector product</xref>. Therefore, <m>u+v</m> is in <m>\Nul(A)</m>.
</li>
<li>
Suppose that <m>v</m> is in <m>\Nul(A)</m> and <m>c</m> is a scalar. Then
<me>A(cv) = cAv = c\cdot 0 = 0</me>
by the <xref ref="matrix-linearity">linearity of the matrix-vector product</xref>, so <m>cv</m> is also in <m>\Nul(A)</m>.
</li>
</ol>
Since <m>\Nul(A)</m> satisfies the three defining properties of a subspace, it is a subspace.
</p>
</proof>
<example xml:id="subspaces-col-nul-1">
<statement>
<p>Describe the column space and the null space of<me>A = \mat{1 1; 1 1; 1 1}</me>.</p>
</statement>
<solution>
<p>
The column space is the span of the columns of <m>A</m>:
<me>\Col(A) = \Span\left\{\vec{1 1 1},\;\vec{1 1 1}\right\}
= \Span\left\{\vec{1 1 1}\right\}.
</me>
This is a line in <m>\R^3</m>.
<latex-code>
\begin{tikzpicture}[myxyz, x={(-.3cm,-.4cm)}, z={(0cm,1cm)}]
\path[clip, resetxy] (-4,-2) rectangle (4,2);
\draw[seq4] (-4,-4,-4) -- (0,0,0);
\begin{scope}[transformxy]
\fill[white, semitransparent] (-1.5,-1.5) rectangle (1.5,1.5);
\draw[step=1cm, grid lines] (-1.5,-1.5) grid (1.5,1.5);
\end{scope}
\draw[seq4] (4,4,4) -- (0,0,0);
\draw[vector] (0,0,0) -- (1,1,1);
\draw[densely dotted] (1,1,0) -- (1,1,1);
\node[resetxy,seq4,below right] at (1.5,1.5) {$\Col(A)$};
\point at (0,0,0);
\end{tikzpicture}
</latex-code>
</p>
<p>
The null space is the solution set of the homogeneous system <m>Ax=0</m>. To compute this, we need to row reduce <m>A</m>. Its reduced row echelon form is
<me>\mat{1 1; 0 0; 0 0}.</me>
This gives the equation <m>x+y=0</m>, or
<me>\syseq{x = -y; y = y}
\quad\xrightarrow{\text{parametric vector form}}\quad
\vec{x y} = y\vec{-1 1}.
</me>
Hence the null space is <m>\Span\bigl\{{-1\choose 1}\bigr\}</m>, which is a line in <m>\R^2</m>.
<latex-code>
\begin{tikzpicture}
\draw[grid lines] (-3,-3) grid (3,3);
\draw[seq4] (3,-3) -- (-3,3);
\draw[vector] (0,0) -- (-1,1);
\point at (0,0);
\node[seq4,fill=white, inner sep=1pt] at (-.7,2) {$\Nul(A)$};
\end{tikzpicture}
</latex-code>
</p>
<p>
Notice that the column space is a subspace of <m>\R^3</m>, whereas the null space is a subspace of <m>\R^2</m>. This is because <m>A</m> has three rows and two columns.
</p>
</solution>
</example>
<p>
The column space and the null space of a matrix are both subspaces, so they are both spans. The column space of a matrix <m>A</m> is defined to be the span of the columns of <m>A</m>. The null space is defined to be the solution set of <m>Ax=0</m>, so this is a good example of a kind of subspace that we can define <em>without any spanning set in mind.</em> In other words, it is easier to show that the null space is a subspace than to show it is a span<mdash/>see the proof above. In order to do computations, however, it is usually necessary to find a spanning set.
</p>
<specialcase hide-type="true">
<title>Null Spaces are Solution Sets</title>
<p>
<idx><h>Null space</h><h>is a solution set</h></idx>
<idx><h>Solution set</h><h>of a homogeneous system is a null space</h></idx>
The null space of a matrix is the solution set of a homogeneous system of equations. For example, the null space of the matrix
<me>
A = \mat{1 7 2; -2 1 3; 4 -2 -3}
</me>
is the solution set of <m>Ax=0</m>, i.e., the solution set of the system of equations
<me>
\syseq{
x + 7y + 2z = 0;
-2x + y + 3z = 0;
4x - 2y - 3z = 0\rlap.
}
</me>
Conversely, the solution set of any homogeneous system of equations is precisely the null space of the corresponding coefficient matrix.
</p>
</specialcase>
<p>
To find a spanning set for the null space, one has to solve a system of homogeneous equations.
</p>
<bluebox xml:id="subspaces-span-nullspace">
<title>Recipe: Compute a spanning set for a null space</title>
<idx><h>Null space</h><h>computing</h></idx>
<p>
To find a spanning set for <m>\Nul(A)</m>, compute the parametric vector form of the solutions to the homogeneous equation <m>Ax=0</m>. The vectors attached to the free variables form a spanning set for <m>\Nul(A)</m>.
</p>
</bluebox>
<example>
<title>Two free variables</title>
<statement>
<p>Find a spanning set for the null space of the matrix
<me>A = \mat{2 3 -8 -5; -1 2 -3 -8}.</me>
</p>
</statement>
<solution>
<p>
We compute the parametric vector form of the solutions of <m>Ax=0</m>. The reduced row echelon form of <m>A</m> is
<me>\mat{1 0 -1 2; 0 1 -2 -3}.</me>
The free variables are <m>x_3</m> and <m>x_4</m>; the parametric form of the solution set is
<me>
\syseq{x_1 = x_3 - 2x_4; x_2 = 2x_3 + 3x_4; x_3 = x_3; x_4 = \. \+ x_4}
\quad\xrightarrow[\text{vector form}]{\text{parametric}}\quad
\vec{x_1 x_2 x_3 x_4} = x_3\vec{1 2 1 0} + x_4\vec{-2 3 0 1}.
</me>
Therefore,
<me>\Nul(A) = \Span\left\{\vec{1 2 1 0},\;\vec{-2 3 0 1}\right\}.</me>
</p>
</solution>
</example>
<example>
<title>No free variables</title>
<statement>
<p>Find a spanning set for the null space of the matrix
<me>A = \mat{1 3; 2 4}.</me>
</p>
</statement>
<solution>
<p>
We compute the parametric vector form of the solutions of <m>Ax=0</m>. The reduced row echelon form of <m>A</m> is
<me>\mat{1 0; 0 1}.</me>
There are no free variables; hence the only solution of <m>Ax=0</m> is the trivial solution. In other words,
<me>\Nul(A) = \{0\} = \Span\{0\}.</me>
It is natural to define <m>\Span\{\} = \{0\}</m>, so that we can take our spanning set to be empty. This is consistent with the <xref ref="dimension-defn-dimension">definition of dimension</xref>.
</p>
</solution>
</example>
<paragraphs>
<title>Writing a subspace as a column space or a null space</title>
<idx><h>Subspace</h><h>writing as column or null space</h></idx>
<p>
A subspace can be given to you in many different forms. In practice, computations involving subspaces are much easier if your subspace is the column space or null space of a matrix. The simplest example of such a computation is finding a spanning set: a column space is by definition the span of the columns of a matrix, and we showed above how to compute a spanning set for a null space using parametric vector form. For this reason, it is useful to rewrite a subspace as a column space or a null space before trying to answer questions about it.
</p>
<bluebox xml:id="subspace-is-col-or-nul">
<p>
When asking questions about a subspace, it is usually best to rewrite the subspace as a column space or a null space.
</p>
</bluebox>
<p>
This also applies to the question <q>is my subset a subspace?</q> If your subset is a column space or null space of a matrix, then the answer is yes.
</p>
<specialcase>
<p>
Let
<me> V = \left\{ \vec{a b} \text{ in } \R^2 \bigm| 2a = 3b\right\}</me>
be the subset of a previous <xref ref="subspaces-eg-byhand"/>. The subset <m>V</m> is exactly the solution set of the homogeneous equation <m>2x - 3y = 0</m>.
Therefore,
<me>V = \Nul\mat{2 -3}.</me>
In particular, it is a subspace. The reduced row echelon form of <m>\mat{2 -3}</m> is <m>\mat{1 -3/2}</m>, so the parametric form of <m>V</m> is <m>x = 3/2y</m>, so the parametric vector form is <m>{x\choose y} = y{3/2\choose 1},</m> and hence <m>\bigl\{{3/2\choose 1}\bigr\}</m> spans <m>V</m>.
</p>
</specialcase>
<example>
<statement>
<p>
Let <m>V</m> be the plane in <m>\R^3</m> defined by
<me>
V = \left\{\vec{2x+y x-y 3x-2y}\bigm| x,y \text{ are in } \R \right\}.
</me>
Write <m>V</m> as the column space of a matrix.
</p>
</statement>
<solution>
<p>
Since
<me>\vec{2x+y x-y 3x-2y} = x\vec{2 1 3} + y\vec{1 -1 -2},</me>
we notice that <m>V</m> is exactly the span of the vectors
<me>\vec{2 1 3} \sptxt{and} \vec{1 -1 -2}.</me>
Hence
<me>V = \Col\mat{2 1; 1 -1; 3 -2}.</me>
</p>
</solution>
</example>
</paragraphs>
</subsection>
</section>