1導入
この講義で重要なのは、行列には行数と列数があり、演算はサイズ条件を満たすときだけ定義されるということである。
行列をいきなり線型写像として解釈すると、初学者は計算規則で混乱しやすい。まず数を長方形に並べた対象として確認し、足し算・スカラー倍・サイズ条件を固定する。
1Introduction
A matrix has a number of rows and a number of columns. Matrix operations are defined only when their size conditions are satisfied. This size discipline comes before interpreting matrices as linear maps.
2用語ようごと定義ていぎ
行列ぎょうれつMatrix とは、数かずを行ぎょうrowと列れつcolumnに並ならべた対象たいしょうである。m 行ぎょうrow n 列れつcolumnの行列ぎょうれつmatrixを m\times n 行列ぎょうれつmatrixという。
A=\begin{pmatrix}
a_{11}&a_{12}\\
a_{21}&a_{22}\\
a_{31}&a_{32}
\end{pmatrix}
は 3\times2 行列ぎょうれつmatrixである。
行ぎょうベクトルRow vector は 1 行ぎょうrowの行列ぎょうれつmatrixであり、列れつベクトルColumn vector は 1 列れつcolumnの行列ぎょうれつmatrixである。
2Terms and definitions
A matrix is a rectangular array of numbers arranged in rows行ぎょう and columns列れつ. A matrix with m rows and n columns is an m\times n matrix.
For example,
A=\begin{pmatrix}
a_{11}&a_{12}\\
a_{21}&a_{22}\\
a_{31}&a_{32}
\end{pmatrix}
is a 3\times2 matrix. A row vector行ぎょうベクトル is a matrix with one row, and a column vector列れつベクトル is a matrix with one column.
3方針ほうしん
行列ぎょうれつmatrixの演算えんざんでは、まずサイズを確認かくにんする。和わと差さは同おなじサイズでだけ定義ていぎされ、スカラー倍ばいは任意にんいのサイズで定義ていぎされる。
data/lecture/math/linear-algebra/vector-operations.lecture.n.md
4直感的ちょっかんてきな説明せつめい
行列ぎょうれつmatrixの和わは、同おなじ位置いちにある成分せいぶんcomponentどうしを加くわえる操作そうさoperationである。座席表ざせきひょうの同おなじ席せきを対応たいおうさせるように、行番号ぎょうばんごうと列番号れつばんごうが一致いっちする成分せいぶんcomponentだけを組くみ合あわせる。
したがって、サイズが異ことなる行列ぎょうれつmatrixは同おなじ位置いちどうしの対応たいおうが成立せいりつしない。演算えんざんが定義ていぎされない理由りゆうはここにある。
5厳密げんみつな説明せつめい
A=(a_{ij})、B=(b_{ij}) を同おなじ m\times n 行列ぎょうれつmatrixとする。このとき
A+B=(a_{ij}+b_{ij})
で定義ていぎする。また
A-B=(a_{ij}-b_{ij})
である。スカラー c に対たいして
cA=(ca_{ij})
と定義ていぎする。行列ぎょうれつmatrixが等ひとしいとは、サイズが同一どういつで、すべての対応たいおうする成分せいぶんcomponentが等ひとしいことである。
3Strategy
For matrix operations, first check the size. Sums and differences are defined only for matrices of the same size, while scalar multiplication is defined for matrices of any size.
data/lecture/math/linear-algebra/vector-operations.lecture.n.md
4Intuitive explanation
Adding matrices means adding entries in the same position. Like matching the same seat in two seating charts, only entries with the same row number and column number are paired.
Therefore matrices of different sizes do not have matching positions everywhere. This is why the operation is not defined.
5Addition and scalar multiplication
Let A=(a_{ij}) and B=(b_{ij}) be matrices of the same size m\times n. Then
A+B=(a_{ij}+b_{ij}),
\qquad
A-B=(a_{ij}-b_{ij}).
For a scalar c,
cA=(ca_{ij}).
Two matrices are equal only when they have the same size and all corresponding entries are equal.
6具体例ぐたいれい
A=\begin{pmatrix}1&2\\3&4\end{pmatrix},\qquad
B=\begin{pmatrix}5&0\\-1&2\end{pmatrix}
なら
A+B=\begin{pmatrix}6&2\\2&6\end{pmatrix},\qquad
2A=\begin{pmatrix}2&4\\6&8\end{pmatrix}
である。一方いっぽう、2\times2 行列ぎょうれつmatrixと 2\times3 行列ぎょうれつmatrixの和わは定義ていぎされない。
6Worked example
Let
A=\begin{pmatrix}1&2\\3&4\end{pmatrix},\qquad
B=\begin{pmatrix}5&0\\-1&2\end{pmatrix}.
Then
A+B=\begin{pmatrix}6&2\\2&6\end{pmatrix},\qquad
2A=\begin{pmatrix}2&4\\6&8\end{pmatrix}.
A 2\times2 matrix and a 2\times3 matrix cannot be added because their positions do not correspond.
7証明しょうめい・確認かくにん:なぜ同おなじサイズが必要ひつようか
(A+B)_{ij} は、A の (i,j) 成分せいぶんcomponentと B の (i,j) 成分せいぶんcomponentを対応たいおうさせて定義ていぎする。どちらかの行列ぎょうれつmatrixにその位置いちが存在そんざいしなければ、規則きそくは値あたいを割わり当あてられない。したがって同おなじサイズという制限せいげんは見みかけの約束やくそくではなく、定義ていぎそのものである。
8よくある誤解ごかい
- サイズが異ことなる行列ぎょうれつmatrixを成分せいぶんcomponentが似にているという理由りゆうで加算かさんしてはならない。
- 行ぎょうベクトルrow vectorと列れつベクトルcolumn vectorは成分数せいぶんすうが同一どういつであってもサイズが異ことなる。
- 正方行列せいほうぎょうれつsquare matrixだけが行列ぎょうれつmatrixではない。長方行列ちょうほうぎょうれつも線型代数せんけいだいすうの主要対象しゅようたいしょうである。
7Proof checkpoint: why same size is required
The entry (A+B)_{ij} is defined by pairing the (i,j) entry of A with the (i,j) entry of B. If one matrix lacks that position, the rule has no value to assign. The restriction is therefore part of the definition, not a cosmetic convention.
8Common misunderstandings
- Do not add matrices of different sizes because their entries look similar.
- A row vector行ぎょうベクトル and a column vector列れつベクトル with the same number of components still have different sizes.
- Square matrices are not the only matrices used in linear algebra; rectangular matrices are central for maps K^n\to K^m.
10最終形さいしゅうけい
\boxed{A+B=(a_{ij}+b_{ij})\quad\text{同じサイズのとき}}
\boxed{cA=(ca_{ij})}
\boxed{\text{行列演算では最初にサイズを確認する}}
10Final forms
\boxed{A+B=(a_{ij}+b_{ij})\quad\text{when sizes match}}
\boxed{cA=(ca_{ij})}
\boxed{\text{Always check matrix sizes first.}}