owned this note
owned this note
Published
Linked with GitHub
# $\mathbb{R}^n$ 中的子空間

This work by Jephian Lin is licensed under a [Creative Commons Attribution 4.0 International License](http://creativecommons.org/licenses/by/4.0/).
{%hackmd 5xqeIJ7VRCGBfLtfMi0_IQ %}
```python
from lingeo import random_int_list, draw_span
```
## Main idea
Let $S$ be a set of (possibily infinitely many) vectors in $\mathbb{R}^n$.
A **linear combination** of $S$ is a vector of the form
$$c_1{\bf u}_1 + \cdots + c_k{\bf u}_k,$$
for some vectors ${\bf u}_1,\ldots, {\bf u}_k\in S$ and
some scalars $c_1,\ldots,c_k\in\mathbb{R}$.
_Although $S$ can have infinitely many vectors, a linear combination only uses finitely many vectors in $S$._
The **span** of $S$ is the set of all linear combination of $S$,
denoted by $\operatorname{span}(S)$.
(We vacuously define $\operatorname{span}(\emptyset) = \{{\bf 0}\}$.)
Let $V$ be a subset of $\mathbb{R}^n$. Then the following two conditions are equivalent.
1. $V = \operatorname{span}(S)$ for some vectors $S$.
2. $V$ is a nonempty subset that is closed under scalar multiplication and vector addition. That is,
1. $V \neq \emptyset$.
2. For any scalar $k$ and vector ${\bf v}\in V$, $k{\bf v}\in V$. (closed under scalr multiplication)
3. For any two vectors ${\bf u},{\bf v}\in V$, ${\bf u} + {\bf v}\in V$. (closed under vector addition)
If either one of the two conditions holds, then $V$ is called a **subspace** of $\mathbb{R}^n$.
A **system of linear equations** has the form
$$\left[\begin{array}{ccccccc}
a_{11}x_1 & + & \cdots & + & a_{1n}x_n & = & b_1 \\
\vdots & ~ & ~ & ~ & \vdots & = & \vdots \\
a_{m1}x_1 & + & \cdots & + & a_{mn}x_n & = & b_m \\
\end{array}\right]$$
for some variables $x_1,\ldots,x_n$, and some numbers $a_{ij}$'s and $b_1,\ldots,b_m$.
When $b_1 = \cdots = b_m = 0$, it is a **homogeneous** system of linear equations.
An $m\times n$ **matrix** $A$ over $\mathbb{R}$ is array
$$\begin{bmatrix}
a_{11} & \cdots & a_{1n} \\
\vdots & ~ & \vdots \\
a_{m1} & \cdots & a_{mn} \\
\end{bmatrix}$$
for some numbers $a_{ij}$'s.
##### Matrix-vector multiplication (by entry)
Let $A = \begin{bmatrix} a_{ij}\end{bmatrix}$ be an $m\times n$ matrix and ${\bf v} = (v_1,\ldots,v_n)$ a vector in $\mathbb{R}^n$.
Then $A{\bf v}$ is a vector in $\mathbb{R}^m$ whose $i$-th entry is
$$\sum_{k=1}^n a_{ik}v_k.
$$
Thus, every system of linear equation can be written as $A{\bf x} = {\bf b}$, while
it is homogeneous when ${\bf b} = {\bf 0}$.
The solution set of $A{\bf v} = {\bf 0}$ is called the **kernel** of $A$, denoted as $\operatorname{ker}(A)$.
That is, $\ker(A) = \{{\bf v}\in\mathbb{R}^n : A{\bf v} = {\bf 0}\}$.
The kernel of an $m\times n$ matrix is a subspace in $\mathbb{R}^n$.
## Side stories
- set equal
## Experiments
##### Exercise 1
執行下方程式碼。
原點為橘色點、
從原點延伸出去的紅色向量和淡藍色向量分別為 ${\bf u}_1$ 和 ${\bf u}_2$。
黑色向量為 ${\bf b}$。
問 ${\bf b}$ 是否是 $\{{\bf u}_1, {\bf u}_2\}$ 的線性組合?
若是﹐求 $c_1,c_2$ 使得 ${\bf b} = c_1{\bf u}_1 + c_2{\bf u}_2$。
```python
### code
set_random_seed(0)
print_ans = False
while True:
l = random_int_list(9)
A = matrix(3, l)
if A.det() != 0:
break
u1 = vector(A[0])
u2 = vector(A[1])
u3 = vector(A[2])
inside = choice([0,1,1])
coefs = random_int_list(2, 2)
if inside:
b = coefs[0]*u1 + coefs[1]*u2
else:
b = coefs[0]*u1 + coefs[1]*u2 + 3*u3
print("u1 =", u1)
print("u2 =", u2)
print("b =", b)
pic = draw_span([u1,u2])
pic += arrow((0,0,0), b, width=5, color="black")
show(pic)
if print_ans:
if inside:
print("b is on Col(A) since b = %s u1 + %s u2."%(coefs[0], coefs[1]))
else:
print("b is not on Col(A).")
```
:::warning
- [ ] 第一題雖然有答案,但要把題目給的數字附上來,然後說明怎麼求得答案。
:::
答:**[由林子翔同學提供]**
當 `seed = 0` 時,題目給的數字為
$\bb = (2,16,10)$,
${\bf u}_1= (-4,3,5)$,
${\bf u}_2=(-5,-5,0)$。
再把 ${\bf b} = c_1{\bf u}_1 + c_2{\bf u}_2$ 寫成
$$
\begin{bmatrix}2\\16\\10\end{bmatrix}=
c_1\begin{bmatrix}-4\\3\\5\end{bmatrix}+
c_2\begin{bmatrix}-5\\-5\\0\end{bmatrix},
$$
可推得
$$
\left\{\begin{aligned}
-4c_1-5c_2 &= 2, \\
3c_1-5c_2 &= 16, \\
5c_1+0c_2 &= 10.
\end{aligned}\right.
$$
因此 $c_1 = 2$, $c_2 = -2$。
帶回原式 ${\bf b} = c_1{\bf u}_1 + c_2{\bf u}_2$,
可推得 ${\bf b} = 2{\bf u}_1 + -2{\bf u}_2$,
故 ${\bf b}$ 是 $\{{\bf u}_1, {\bf u}_2\}$ 的線性組合。
## Exercises
##### Exercise 2(a)
令
$${\bf e}_1 = \begin{bmatrix}1\\0\\0\end{bmatrix},
{\bf e}_2 = \begin{bmatrix}0\\1\\0\end{bmatrix},
{\bf e}_3 = \begin{bmatrix}0\\0\\1\end{bmatrix}.
$$
說明 $\mathbb{R}^3 = \operatorname{span}(\{{\bf e}_1, {\bf e}_2, {\bf e}_3\})$﹐
因此它是
個子空間。
(要說明每一個 $\mathbb{R}^3$ 中的向量都可以寫成 $c_1{\bf e}_1 + c_2{\bf e}_2 + c_3{\bf e}_3$ 的形式。)
:::warning
- [x] 純量 $a,c$ 不要粗體
- [x] "$\mathbb{R}^3$," --> "$\mathbb{R}^3$. We may solve ..."
- [x] "so," --> "and get ..." 最後加句點
- [x] 最後加 "Therefore, every vector in $\mathbb{R}^3$ can be written as a linear combination of $\{\be_1,\be_2,\be_3\}$."
- [x] 第二段是幹麻的?第一段就證明了 $\mathbb{R}^3 = \vspan(...)$ 所以它就已經是子空間了。不用再用第二種方式驗證。
:::
Let
$$\begin{bmatrix}a_1\\a_2\\a_3\end{bmatrix}\in \mathbb{R}^3.$$
We may solve$$c_1 \begin{bmatrix}1\\0\\0\end{bmatrix}+
c_2 \begin{bmatrix}0\\1\\0\end{bmatrix}+
c_3 \begin{bmatrix}0\\0\\1\end{bmatrix}= \begin{bmatrix}a_1\\a_2\\a_3\end{bmatrix}$$
and get $$ c_1=a_1 ,c_2=a_2,c_3=a_3.
$$
Therefore, every vector in $\mathbb{R}^3$ can be written as a linear combination of $\{\be_1,\be_2,\be_3\}$.
##### Exercise 2(b)
令
$${\bf b} = \begin{bmatrix}1\\2\\-3\end{bmatrix},
{\bf u}_1 = \begin{bmatrix}-1\\1\\0\end{bmatrix},
{\bf u}_2 = \begin{bmatrix}0\\-1\\1\end{bmatrix}.
$$
說明 ${\bf b}\in\operatorname{span}(\{{\bf u}_1, {\bf u}_2\})$。
:::warning
- [x] 句子不清楚:"Consider the equation ..., which is equivalent to ... ."
- [x] 學一下排版
$$
\left\{\begin{aligned}
-c_1+0 &= 1 \\
c_1-c_2 &= 2 \\
0+c_2 &= -3
\end{aligned}\right.
$$.
- [x] "then" --> "Then"
- [x] 向量 $u$ 粗體
- [x] "so we get" --> ". Therefore, "
- [x] 句點
- [x] 下一題用同樣標準修改
:::
Consider the equation
$$
\begin{bmatrix}1\\2\\-3\end{bmatrix}=
c_1\begin{bmatrix}-1\\1\\0\end{bmatrix}+
c_2\begin{bmatrix}0\\-1\\1\end{bmatrix}
$$
, which is equivalent to
$$
\left\{\begin{aligned}
-c_1+0 &= 1, \\
c_1-c_2 &= 2, \\
0+c_2 &= -3.
\end{aligned}\right.
$$
Then
$$
c_1=-1,c_2=-3.
$$
Therefore,
$$
{\bf b}=(-1)u_1+(-3)u_2
$$
and
$$
{\bf b}\in\operatorname{span}(\{{\bf u}_1,{\bf u}_2\})
.$$
##### Exercise 2(c)
令
$${\bf b} = \begin{bmatrix}1\\1\\1\end{bmatrix},
{\bf u}_1 = \begin{bmatrix}-1\\1\\0\end{bmatrix},
{\bf u}_2 = \begin{bmatrix}0\\-1\\1\end{bmatrix}.
$$
說明
${\bf b}\notin\operatorname{span}(\{{\bf u}_1, {\bf u}_2\})$。
Consider the equation
$$
\begin{bmatrix}1\\1\\1\end{bmatrix}=
c_1\begin{bmatrix}-1\\1\\0\end{bmatrix}+
c_2\begin{bmatrix}0\\-1\\1\end{bmatrix},
$$
which is equivalent to
$$
\left\{\begin{aligned}
-c_1+0 &= 1, \\
c_1 - c_2 &= 1, \\
0+c_2 &= 1,
\end{aligned}\right.
$$
which implies
$$
\left\{\begin{aligned}
c_1 &= -1, \\
c_2 &= -2, \\
c_2 &= 1.
\end{aligned}\right.
$$
However, $c_2$ cannot be both $-2$ and $1$.
Since $\bb$ cannot be expressed as $c_1 \bu_1 +c_2 \bu_2$ , ${\bf b}\notin\operatorname{span}(\{{\bf u}_1,{\bf u}_2\})$.
##### Exercise 2(d)
令
$${\bf b} = \begin{bmatrix}1\\2\\-3\end{bmatrix},
{\bf u}_1 = \begin{bmatrix}-1\\1\\0\end{bmatrix},
{\bf u}_2 = \begin{bmatrix}0\\-1\\1\end{bmatrix},
{\bf u}_3 = \begin{bmatrix}-1\\0\\1\end{bmatrix}.
$$
找出至少兩組 $c_1, c_2, c_3$ 使得 ${\bf b} = c_1{\bf u}_1 + c_2{\bf u}_2 + c_3{\bf u}_3$。
這說明了線性組合的表示法不見得唯一。
:::warning
- [x] 把句子寫完整
- [x] We may solve the equation ... and get two solutions ... .
:::
We may solve the equation
$$
\left\{\begin{aligned}
-c_1-c_3 &=1,\\
c_1-c_2 &=2,\\
c_2+c_3 &=3.
\end{aligned}\right.
$$
And get two solutions
$$
c_1=1,c_2=-1,c_3=-2,\\
c_1=-1,c_2=-3,c_3=0.
$$
##### Exercise 3
依照各小題的步驟來證明子空間的兩個條件等價。
1. $V = \operatorname{span}(S)$ for some vectors $S$.
2. $V$ is a nonempty subset that is closed under scalar multiplication and vector addition.
並用這些條件來判斷一個集合是否為子空間。
##### Exercise 3(a)
證明若條件 1 成立則條件 2 成立。
:::warning
- [x] 句點
- [x] "Then ${\bf v}_1 + {\bf v}_2$" --> "Thus, ${\bf v}_1 + {\bf v}_2$"
:::
Suppose $V = \operatorname{span}(S)$ for some $S\subseteq\mathbb{R}^n$.
We verify each of the requirements in condition 2.
**nonempty**
Since $\operatorname{span}(S)$ always contains zero vector, $V$ is nonempty.
**closed under scalar multiplication**
Suppose ${\bf v}\in V$ and $k$ a scalar.
Then ${\bf v}$ can be written as $c_1{\bf u}_1 + \cdots + c_k{\bf u}_k$ for some vectors ${\bf u}_i\in S$ and scalars $c_i$.
Then $k{\bf v}=kc_1{\bf u}_1 + \cdots + kc_k{\bf u}_k=d_1{\bf u}_1 + \cdots + d_k{\bf u}_k$ for scalars $kc_i=d_i$.
So $k{\bf v}\in\operatorname{span}(S) = V$.
**closed under vector addition**
Suppose ${\bf v}_1,{\bf v}_2\in V$.
Then ${\bf v}_1$ can be written as $a_1{\bf u}_1 + \cdots + a_k{\bf u}_k$ for some vectors ${\bf u}_i\in S$ and scalars $a_i$,
and ${\bf v}_2$ can be written as $b_1{\bf u}_1 + \cdots + b_k{\bf u}_k$ for some vectors ${\bf u}_i\in S$ and scalars $b_i$.
Thus, ${\bf v}_1 + {\bf v}_2=(a_1+b_1){\bf u}_1 + \cdots + (a_k+b_k){\bf u}_k=c_1{\bf u}_1 + \cdots + c_k{\bf u}_k$ for scalars $a_i+b_i=c_i$.
So ${\bf v}_1 + {\bf v}_2 \in\operatorname{span}(S) = V$.
##### Exercise 3(b)
證明若條件 2 成立則條件 1 成立。
:::warning
- [x] "$V$ can be spanned by itself" --> "each element in $V$ is a linear combination of $V$ and is in $\vspan(V)$"
- [x] 句點
- [ ] "Therefore, " --> ", so"
:::
Suppose $V$ is a nonempty subset of $\mathbb{R}^n$ and is closed under scalar multiplication and vector addition.
It is enough to show that $V = \operatorname{span}(V)$.
**$V\subseteq\operatorname{span}(V)$**
Clearly, each element in $V$ is a linear combination of $V$ and is in $\vspan(V)$.
**$\operatorname{span}(V)\subseteq V$**
Let ${\bf u}$ be an element of $\operatorname{span}(V)$.
Then ${\bf u}$ can be written as $c_1{\bf u}_1 + \cdots + c_k{\bf u}_k$ for some vectors ${\bf u}_i\in V$ and scalars $c_i$.
From the assumption, $V$ is closed under scalar multiplication and vector addition, so ${\bf u}\in V$.
##### Exercise 3(c)
判斷 $\emptyset$ 是否為一子空間。
:::warning
- [x] V --> $V$
- [x] ",so" --> ", so"
- [x] 句點
:::
Because $\emptyset$ not conform with "$V$
is a nonempty subset" in condition2, so $\emptyset$ is not a subspace.
##### Exercise 3(d)
判斷 $\{{\bf 0}\}$ 是否為一子空間。
:::warning
- [x] ",so" --> ", so"
- [x] 句點
:::
Because we vacuously define $\operatorname{span}(\emptyset) = \{{\bf 0}\}$, so $\{{\bf 0}\}$ is a subspace.
##### Exercise 3(e)
判斷 $\left\{\begin{bmatrix}1\\1\\1\end{bmatrix}\right\}$ 是否為一子空間。
:::warning
- [x] 觀察 ... 。
- [x] 中文用全型標點
:::
觀察$\begin{bmatrix}1\\1\\1\end{bmatrix} +\begin{bmatrix}1\\1\\1\end{bmatrix} = \begin{bmatrix}2\\2\\2\end{bmatrix}$,發現集合中的兩向量相加會得到一個集合外的向量。
因為加法沒有封閉性,所以 $\left\{\begin{bmatrix}1\\1\\1\end{bmatrix}\right\}$ 不為一子空間。
##### Exercise 3(f)
判斷 $\left\{t\begin{bmatrix}1\\1\\1\end{bmatrix} : t\in\mathbb{R}\right\}$ 是否為一子空間。
:::warning
- [x] (1) 後留空格
- [x] V --> $V$
- [x] (2): Let ... 句點 Then $\bv_1$... for some $t_1$... 句點
- [x] Then $\bv_1 +$ ... , so ... is a subspace.
- [ ] 中英混雜
- [x] 下一題類似
:::
(1) $V$ 通過原點。
(2) Let ${\bf v}_1,{\bf v}_2\in \left\{t\begin{bmatrix}1\\1\\1\end{bmatrix} :t\in\mathbb{R}\right\}.$
Then
$$
{\bf v}_1 = t_1\begin{bmatrix}1\\1\\1\end{bmatrix},
{\bf v}_2 = t_2\begin{bmatrix}1\\1\\1\end{bmatrix}
$$
for some $t_1,t_2\in\mathbb{R}$.
Then
$$
{\bf v}_1 + {\bf v}_2 = \begin{bmatrix}t_1\\t_1\\t_1\end{bmatrix} +\begin{bmatrix}t_2\\t_2\\t_2\end{bmatrix} = \begin{bmatrix}t_1 + t_2\\t_1 + t_2\\t_1 + t_2\end{bmatrix} = t_1 + t_2\begin{bmatrix}1\\1\\1\end{bmatrix}\in\left\{t\begin{bmatrix}1\\1\\1\end{bmatrix} :t\in\mathbb{R}\right\}
$$
so, $\left\{t\begin{bmatrix}1\\1\\1\end{bmatrix} : t\in\mathbb{R}\right\}$ is a subspace.
##### Exercise 3(g)
判斷 $\left\{\begin{bmatrix}x\\y\\z\end{bmatrix} : x^2 + y^2 + z^2 = 1\right\}$ 是否為一子空間。
Let
$$
{\bf v}_1 = \begin{bmatrix}1\\0\\0\end{bmatrix},
{\bf v}_2 = \begin{bmatrix}0\\1\\0\end{bmatrix}.
$$
Then
${\bf v}_1,{\bf v}_2\in \left\{\begin{bmatrix}x\\y\\z\end{bmatrix} : x^2 + y^2 + z^2 = 1\right\}$.
But ${\bf v}_1+{\bf v}_2\notin \left\{\begin{bmatrix}x\\y\\z\end{bmatrix} : x^2 + y^2 + z^2 = 1\right\}$.
So $\left\{\begin{bmatrix}x\\y\\z\end{bmatrix} : x^2 + y^2 + z^2 = 1\right\}$ is not a subspace.
##### Exercise 3(h)
判斷 $\left\{\begin{bmatrix}x\\y\\z\end{bmatrix} : x^2 + y^2 + z^2 \geq 1\right\}$ 是否為一子空間。
:::success
這題完全沒問題喔!
:::
$\left\{\begin{bmatrix}x\\y\\z\end{bmatrix} : x^2 + y^2 + z^2 \geq 1\right\}$不通過原點,因此不為子空間。
##### Exercise 3(i)
判斷 $\left\{\begin{bmatrix}x\\y\\z\end{bmatrix} : x \geq 0\right\}$ 是否為一子空間。
**[由林暐智同學提供]**
Let $\bv_1 = \begin{bmatrix}1\\0\\0\end{bmatrix}$ and $k=-100$.
Then $\bv_1 \in \left\{\begin{bmatrix}x\\y\\z\end{bmatrix} : x \geq 0\right\}$, but $k{\bf v}_1\notin \left\{\begin{bmatrix}x\\y\\z\end{bmatrix} : x \geq 0\right\}$.
So $\left\{\begin{bmatrix}x\\y\\z\end{bmatrix} : x \geq 0\right\}$ is not a subspace.
##### Exercise 3(j)
判斷 $\left\{\begin{bmatrix}x\\y\\z\end{bmatrix} : x + y + z = 0\right\}$ 是否為一子空間。
:::warning
- [x] 中英之間空格
- [x] = V --> $= V$
- [x] V --> $V$
- [x] 純量不用粗體
- [x] 句點
- [x] $x,y$ 是變數 不要拿來當係數
- [x] 3(l) 一樣
:::
令$\left\{\begin{bmatrix}x\\y\\z\end{bmatrix} : x + y + z = 0\right\} = V$。
(1) $V$ 通過原點。
(2) 令
$${\bf v}_1 = \begin{bmatrix}a_1\\b_1\\c_1\end{bmatrix}\in\ V,
{\bf v}_2 = \begin{bmatrix}a_2\\b_2\\c_2\end{bmatrix}\in\ V,p, q\in\mathbb{R}.
$$
然後把兩者相加得到 $p{\bf v}_1 + q{\bf v}_2 = \begin{bmatrix}pa_1 + qa_2\\pb_1 + qb_2 \\pc_1 + qc_1\end{bmatrix}$。
將其帶入 $x + y + z$ 中,發現
$$
(pa_1 + qa_2) + (pb_1 + qb_2) + (pc_1 + qc_2) = p(a_1 + b_1 + c_1) + q( a_2 + b_2 + c_2) = 0
$$
符合條件,因此 $\left\{\begin{bmatrix}x\\y\\z\end{bmatrix} : x + y + z = 0\right\}$ 為子空間。
##### Exercise 3(k)
判斷 $\left\{\begin{bmatrix}x\\y\\z\end{bmatrix} : x + y + z = 1\right\}$ 是否為一子空間。
$\left\{\begin{bmatrix}x\\y\\z\end{bmatrix} : x + y + z = 1\right\}$ 不通過原點,因此不為子空間。
##### Exercise 3(l)
判斷 $\left\{\begin{bmatrix}x\\y\\z\end{bmatrix} :
\begin{aligned}
x + y + z &= 0 \\
x + 2y + 3z &= 0
\end{aligned}
\right\}$ 是否為一子空間。
令 $\left\{\begin{bmatrix}x\\y\\z\end{bmatrix} :
\begin{aligned}
x + y + z &= 0 \\
x + 2y + 3z &= 0
\end{aligned}
\right\} = V$。
(1) $V$ 通過原點。
(2) 令
$${\bf v}_1 = \begin{bmatrix}a_1\\b_1\\c_1\end{bmatrix}\in\ V,
{\bf v}_2 = \begin{bmatrix}a_2\\b_2\\c_2\end{bmatrix}\in\ V,p,q \in\mathbb{R}.
$$
然後把兩者相加,$p{\bf v}_1 + q{\bf v}_2 = \begin{bmatrix}pa_1 + qa_2\\pb_1 + qb_2 \\pc_1 + qc_1\end{bmatrix}$, 帶入$x + y + z$中,
$(pa_1 + qa_2) + (pb_1 + qb_2) + (pc_1 + qc_2) = p(a_1 + b_1 + c_1) + q(a_2 + b_2 + c_2) = 0.$
接著,帶入$x + 2y + 3z$,$(pa_1 + qa_2) + 2(pb_1 + qb_2) + 3(pc_1 + qc_2) = p(a_1 + 2b_1 + 3c_1) + q(a_2 + 2b_2 + 3c_2) = 0$
符合兩條件,因此 $\left\{\begin{bmatrix}x\\y\\z\end{bmatrix} :
\begin{aligned}
x + y + z &= 0 \\
x + 2y + 3z &= 0
\end{aligned}
\right\}$ 為子空間
##### Exercise 4(a)
證明對任何 $S\subseteq\mathbb{R}^n$ 都有 $\operatorname{span}(\operatorname{span}(S)) = \operatorname{span}(S)$。
:::warning
- [x] Then, $\bv=c_1{\bf u}_1 + \cdots + c_k{\bf u}_k$, for some vectors ${\bf u}_1,\ldots, {\bf u}_k\in \operatorname{span}(S)$ for some scalars $c_1,\ldots, c_k\in\mathbb{R}$.
- [x] ${\bf u_i}$ --> $\bu_i$
- [x] $c_{ij}$ --> $d_{ij}$?
- [x] 句點
:::
First, we clearly know that $\operatorname{span}(S)$ can be spanned by itself.
Then, we have $\operatorname{span}(S)\subseteq\operatorname{span}(\operatorname{span}(S))$.
Next, let $\bv\in\operatorname{span}(\operatorname{span}(S))$.
Then, $\bv=c_1{\bf u}_1 + \cdots + c_k{\bf u}_k$, for some vectors ${\bf u}_1,\ldots, {\bf u}_k\in \operatorname{span}(S)$ for some scalars $c_1,\ldots, c_k\in\mathbb{R}$.
So, ${\bf u}_i$ can be written as $d_{i1}{\bf s}_1 + \cdots + d_{ik}{\bf s}_k$ for some vectors ${\bf s}_i\in S$ and scalars $d_{ij}$.
In other words, $\bv=(\sum_{i=1}^k c_{i}d_{i1}){\bf s}_1 + \cdots + (\sum_{i=1}^k c_{i}d_{ik}){\bf s}_k\in\operatorname{span}(S)$.
Therefore, $\operatorname{span}(\operatorname{span}(S))\subseteq\operatorname{span}(S)$.
Finally, we can conclude $\operatorname{span}(\operatorname{span}(S)) = \operatorname{span}(S)$.
##### Exercise 4(b)
令 $S\subseteq\mathbb{R}^n$。
證明以下敘述等價:
1. ${\bf w}\in\operatorname{span}(S)$.
2. $\operatorname{span}(S\cup\{{\bf w}\}) = \operatorname{span}(S)$.
:::warning
- [x] 句點
- [x] Let ... . Then ... .
- [x] **From 2. to 1.**: 這個論證有問題 $c_{k+1} = 0$ 怎辦?
:::
**From 1. to 2.**
Assume ${\bf w}\in\operatorname{span}(S)$.
Clearly, $\operatorname{span}(S)\subseteq \operatorname{span}(S\cup\{{\bf w}\})$.
Let ${\bf v}\in\operatorname{span}(S\cup\{{\bf w}\})$.
Then ${\bf v}$ can be written as $c_1{\bf u}_1 + \cdots + c_k{\bf u}_k+c_{k+1}{\bf w}$ for some vectors ${\bf u}_i\in S$ and scalars $c_i$.
From the assumption, ${\bf w}\in\operatorname{span}(S)$,
we have ${\bf v}\in\operatorname{span}(S)$.
Then, we get $\operatorname{span}(S\cup\{{\bf w}\}) \subseteq \operatorname{span}(S)$.
So, $\operatorname{span}(S\cup\{{\bf w}\}) = \operatorname{span}(S)$.
**From 2. to 1.**
Assume $\operatorname{span}(S\cup\{{\bf w}\}) = \operatorname{span}(S)$.
Since $\bw\in S\cup\{\bw\}$, $\bw\in\vspan(S\cup\{\bw\})$.
:::info
格式可改進
數學除了最後一題都正確
目前分數:4.5/5
:::
<!--
Let $$\begin{bmatrix}a_1'\\a_2'\\a_3'\end{bmatrix}\in \mathbb{R}^3
.c_1' \begin{bmatrix}1\\0\\0\end{bmatrix}+
c_2' \begin{bmatrix}0\\1\\0\end{bmatrix}+
c_3' \begin{bmatrix}0\\0\\1\end{bmatrix}= \begin{bmatrix}a_1'\\a_2'\\a_3'\end{bmatrix}
$$
so,
$$ c_1'=a_1',c_2'=a_2',c_3'=a_3'
$$
then
$$
\begin{bmatrix}
a_1\\a_2\\a_3\end{bmatrix}+
\begin{bmatrix}
a_1'\\a_2'\\a_3'\end{bmatrix}=
c_1 \begin{bmatrix}1\\0\\0\end{bmatrix}+
c_2 \begin{bmatrix}0\\1\\0\end{bmatrix}+
c_3 \begin{bmatrix}0\\0\\1\end{bmatrix}+
c_1'\begin{bmatrix}1\\0\\0\end{bmatrix}+
c_2'\begin{bmatrix}0\\1\\0\end{bmatrix}+
c_3'\begin{bmatrix}0\\0\\1\end{bmatrix}$$
$$=
(c_1+c_1')\begin{bmatrix}1\\0\\0\end{bmatrix}+
(c_2+c_2')\begin{bmatrix}0\\1\\0\end{bmatrix}
(c_3+c_3')\begin{bmatrix}0\\0\\1\end{bmatrix}
$$
For any scalar k,
$$ k\begin{bmatrix}
a_1\\a_2\\a_3\end{bmatrix}=
kc_1\begin{bmatrix}1\\0\\0\end{bmatrix}+
kc_2\begin{bmatrix}0\\1\\0\end{bmatrix}+
kc_3\begin{bmatrix}0\\0\\1\end{bmatrix}
$$
$$=
(kc_1)\begin{bmatrix}1\\0\\0\end{bmatrix}+
(kc_2)\begin{bmatrix}0\\1\\0\end{bmatrix}+
(kc_3)\begin{bmatrix}0\\0\\1\end{bmatrix}
$$
so,
$\mathbb{R}^3 = \operatorname{span}(\{{\bf e}_1, {\bf e}_2, {\bf e}_3\})$,also a subspace.
Therefore,every vector in $\mathbb{R}^3$can be written as a linear combination as$\operatorname{span}(\{{\bf e}_1,{\bf e}_2,{\bf e}_3\})$.
-->