Row vectors, column vectors, and matrices

We define an (\(n\)-dimensional) (row) vector to be an element of \(\mathbb{R}^n\) endowed with addition and scalar multiplication



So, a row vector is something like \((x_1, x_2, \cdots, x_n)\). We may omit the commas as in \((x_1~ x_2 ~ \cdots ~ x_n)\). But vectors are not just elements of \(\mathbb{R}^n\). We define addition between row vectors by

\[(x_1, \cdots, x_n) + (y_1, \cdots, y_n) = (x_1+y_1, \cdots, x_n + y_n).\tag{eq:vadd}\]

We also define multiplication by a real number \(\lambda\in\mathbb{R}\) by

\[\lambda\cdot(x_1,\cdots, x_n) = (\lambda x_1, \cdots, \lambda x_n).\tag{eq:svmul}\]

In this context, the real numbers are called scalars because it scales the vector.

In summary, vectors are elements of \(\mathbb{R}^n\) where addition and scalar multiplications are defined. We will give more characterization of vectors in later posts.

Example. \((1, 2), (-5, 3) \in \mathbb{R}^2\) are 2-dimensional row vectors. We can add them as

\[(1, 2) + (-5, 3) = (1-5, 2+3) = (-4, 5).\]

We can multiply them by scalars (real numbers):

\[\begin{eqnarray*} \pi\cdot(1, 2) &=& (\pi, 2\pi),\\ -1\cdot(-5, 3) &=& (5, -3). \end{eqnarray*}\]

Instead of writing \(n\) real numbers in a row like \((x_1, \cdots, x_n)\), we could write them in a column like

\[\begin{pmatrix}x_1\\\vdots\\x_n\end{pmatrix}\]

which we call a column vector. Addition and scalar multiplication can be defined similarly to row vectors.


If \(n\) is not prime, we can write a point in \(\mathbb{R}^n\) in multiple rows and columns. For example, a point in \(\mathbb{R}^6\) may be written as

\[(x_1, x_2, x_3, x_4, x_5, x_6)\]

or

\[\begin{pmatrix}x_1\\ x_2\\ x_3\\x_4\\ x_5\\ x_6\end{pmatrix}\]

or

\[\begin{pmatrix}x_1 & x_2 & x_3\\x_4 & x_5 & x_6\end{pmatrix}\]

or

\[\begin{pmatrix}x_1 & x_2\\x_3 & x_4\\x_5 & x_6\end{pmatrix}.\]

Such a rectangular array of numbers is called a matrix. If there are \(m\) rows and \(n\) columns in a matrix, we call it an \(m\times n\) matrix and regard it as a member of the set \(\mathbb{R}^{m\times n}\). We can also define element-wise addition and scalar multiplication for matrices. Now we can see that an \(n\)-dimensional row vector is really a \(1\times n\) matrix, and an \(n\)-dimensional column vector is an \(n \times 1\) matrix. Accordingly, we can define addition and scalar multiplication of matrices in the same way as vectors.

Example

\[\begin{pmatrix} 1 & 2 & 3\\ 4 & 5 & 6 \end{pmatrix} + \begin{pmatrix} -3 & -1 & 2\\ 1 & -2 & 3 \end{pmatrix} = \begin{pmatrix} -2 & 1 & 5\\ 5 & 3 & 9 \end{pmatrix},\]

\[5\cdot\begin{pmatrix} 1 & 2 & 3\\ 4 & 5 & 6 \end{pmatrix} = \begin{pmatrix} 5 & 10 & 15\\ 20 & 25 & 30 \end{pmatrix}.\]

Note that two matrices can be added if and only if they have the same shape. □

Remark. So far, we have worked with \(\mathbb{R}^n\) to define vectors (including matrices). We can similarly define vectors and matrices on \(\mathbb{C}^n\) or \(\mathbb{Q}^n\) where scalars are complex or rational numbers, respectively. Note that \(\mathbb{R}\), \(\mathbb{C}\) and \(\mathbb{Q}\) are fields. In fact, we may define vectors and matrices over any field. □

Definition (Linear combination)

Let \(\mathbf{v}_1, \mathbf{v}_2, \cdots, \mathbf{v}_n\) be vectors and \(\lambda_1, \lambda_2, \cdots, \lambda_n\) be scalars. The expression of the form

\[\lambda_1\mathbf{v}_1 + \lambda_2\mathbf{v}_2 + \cdots + \lambda_n\mathbf{v}_n\]

is called the linear combination of the vectors \(\mathbf{v}_1, \mathbf{v}_2, \cdots, \mathbf{v}_n\) with the coefficients \(\lambda_1, \lambda_2, \cdots, \lambda_n\).


Example

\[(5, -9) = 3(1, -1) + 2(1, -3).\]

Thus, \((5, -9)\) can be represented as a linear combination of \((1,-1)\) and \((1, -3)\) with coefficients 3 and 2, respectively. □


Comments

Popular posts from this blog

Open sets and closed sets in \(\mathbb{R}^n\)

Euclidean spaces

Newton's method