Row Vector – Explanation & Examples

Row VectorA row vector is a matrix with 1 row. It is also known as a row matrix. Let’s start with a formal definition of a row vector.

A row vector is a $ 1 \times n $ matrix consisting of a single row with n elements.

In this article, we will look at what a row vector is,  some examples, and matrix operations with row vectors.

What is a Row Vector?

A row vector, also known as a row matrix, is a type of matrix with only $ 1 $ row.  There can be $ 1 $ column, $ 2 $ columns, $ 3 $ columns, or $ n $ columns. But the number of row is always $ 1 $! Generally, a row vector is:

What is a Row Vector?

This shows a row vector, $ B $, with $ 1 $ row and $ n $ columns. The first element of the matrix is $ b_1 $, the second element is $ b_2 $, and so on until the last element, $ b_n $. 

Let’s look at some common row vectors below:

$ 1 \times 1 $ row vector:

$ \begin{bmatrix} d \end {bmatrix} $

This is the simplest row vector with $ 1 $ row and $ 1 $ column. The only element in this matrix is $ d $.

$ 1 \times 2 $ row vector:

$ \begin{bmatrix} { – 3 }  & { 6 }  \end {bmatrix} $

This is a $ 1 \times 2 $ matrix. There is $ 1 $ row and $ 2 $ columns.

$ 1 \times 3 $ row vector:

$ \begin{bmatrix} { – 2 }  & { – 4 } & { – 2 }  \end {bmatrix} $

This is a $ 1 \times 3 $ matrix. There is $ 1 $ row and $ 3 $ columns.

Theoretically, there can be as many columns as we want, but there needs to be only $ 1 $ row. This is what makes a matrix a row vector!

Transpose of a Row Vector

Recall that taking the transpose of a matrix means to interchange the rows with columns. The rows become columns and the columns become rows.

What happens when we take the transpose of a row vector?

Since there is only $ 1 $ row, transposing a row vector makes it a column vector!

Suppose we have a row vector $ A $:

$ A = \begin{bmatrix} { – 21 }  & { – 15 } & 6 & 2  \end {bmatrix} $

If we transpose it, we will get a column vector, shown below (let’s call it matrix $ B $):

$ B = \begin{bmatrix} { – 21 }  \\ { – 15 } \\ 6 \\ 2  \end {bmatrix} $Transpose of a Row Vector

To read more about column vectors, please go here.

How to find a Row Vector

Just like with matrices, we can perform the arithmetic operations on row vectors as well. We will look at addition, subtraction, and scalar multiplication.

Addition

Before adding $ 2 $ row vectors, we have to check whether they are of the same dimensions or not. If they aren’t, we can’t add them. If they are of the same order, we just add the corresponding elements of each row vector.

Consider matrices $ A $ and $ B $ shown below:

$ A = \begin{bmatrix} { – 4 }  & 4 & { – 2 }  \end {bmatrix} $

$ B = \begin{bmatrix} { – 2 }  & 4 & 6  \end {bmatrix} $

Matrices $ A $ and $ B $ are both $ 1 \times 3 $ matrices. We add the two row vectors by adding the corresponding entries. Shown below:

$ A + B = \begin{bmatrix} { (- 4 + – 2) }  & { (4 + 4) } & { (-2 + 6) }  \end {bmatrix} $

$ A + B = \begin{bmatrix} {-6 }  & { 8 } & { 4 }  \end {bmatrix} $

Subtraction

Subtraction is very similar to addition. We just subtract each corresponding entries instead of adding (as in matrix addition).

Consider matrices $ N $ and $ M $ shown below:

$ N = \begin{bmatrix} { – 1 }  &  1  \end {bmatrix} $

$ M = \begin{bmatrix} { 3 }  & { – 10 }  \end {bmatrix} $

Matrices $ N $ and $ M $ are both $ 1 \times 2 $ matrices. We subtract the two row vectors by subtracting the corresponding entries in each row matrix. Shown below:

$ N – M = \begin{bmatrix} { (- 1  – 3) }  & { 1 – ( – 10 ) }  \end {bmatrix} $

$ N – M = \begin{bmatrix} { – 4 }  & { 11 }  \end {bmatrix} $

Scalar Multiplication

When we want to multiply a row vector by a scalar, we simply multiply each element of the row matrix by the scalar. Consider matrix $ B $ shown below:

$ B = \begin{bmatrix} { – 12 }  & { – 1 } & { 4 } & 8  \end {bmatrix} $

If we want to multiply this column matrix by the scalar $ \frac{1}{12} $, we will do so by multiplying each of its elements by $ \frac{1}{12} $. The process is shown below:

$ \frac{1}{12} B = \frac{1}{12} \times \begin{bmatrix} { – 12 }  & { – 1 } & { 4 } & 8  \end {bmatrix} $

$  = \begin{bmatrix} {(\frac{1}{12} \times – 12) }  &  {(\frac{1}{12} \times -1)} & {(\frac{1}{12} \times 4)} & {(\frac{1}{12} \times 8)}  \end {bmatrix} $

$ = \begin{bmatrix} {-1 }  &  {-\frac{1}{12}} & {  \frac{1}{3} } & {\frac{2}{3}}  \end {bmatrix} $

Below, we show some examples to enhance our understanding of row vectors.

 

Example 1

Out of the $ 4 $ matrices shown below, identify which of them are row vectors.

$ A = \begin{bmatrix} { 4 }  &  6 & {  -3 }  \end {bmatrix} $

$ B = \begin{bmatrix} { 1 }  &  1 & { 1 } & 1   \end {bmatrix} $

$ C = \begin{bmatrix} { -1 } \\ { – 6 } \end {bmatrix} $

$ D = \begin{bmatrix} { 14 }  \end {bmatrix} $

Solution

  • Matrix $ A $ is a $ 1 \times 3 $ matrix. It has $ 1 $ row and $ 3 $ columns. Thus, it is a row vector.
  • Matrix $ B $ is s $ 1 \times 4 $ matrix. It has $ 1 $ row and $ 4 $ columns. All the entries are ones, but that doesn’t really matter. Since it has a single row, it is a row vector.
  • Matrix $ C $  is a $ 2 \times 1 $ matrix. It has $ 2 $ rows and $ 1 $ column. It is not a row vector, rather a column vector.
  • Matrix $ D $ is a $ 1 \times 1 $ matrix. It is the simplest form of a matrix. It has $ 1 $ row and $ 1 $ column. It is the simplest row matrix. It is a row vector.

Example 2

What is the transpose of the following row vector?

$  \begin{bmatrix} f & g & h & i & j   \end {bmatrix} $

Solution

Recall that the transpose of a row vector is a column vector. We just write the same entries as a “column” instead of a row. Thus, the transpose is:

$  \begin{bmatrix} f \\ g \\ h \\ i \\ j   \end {bmatrix} $

 

Example 3

Subtract matrix $ G $ from matrix $ F $.

$  F = \begin{bmatrix} 1 & 0 & 3 & 7  \end {bmatrix} $

$ G = \begin{bmatrix} -2 & 1 & 0 & -1 \end {bmatrix} $

Solution

Matrices $ F $ and $ G $ are both $ 1 \times 4 $ matrix. They have the same dimension. Thus, they can be subtracted by subtracting the corresponding elements of each matrix. The process is shown below:

$ F – G = \begin{bmatrix} (1 – – 2) & (0 – 1) & (3 – 0) & (7 – – 1) \end {bmatrix} $

$ F – G = \begin{bmatrix} 3 & { – 1 } & 3 & 8 \end {bmatrix} $

Practice Questions

  1. Find the transpose of:
    1. $ \begin{pmatrix} t & b & x & e \end {pmatrix} $
    2. $ \begin{pmatrix} { – 13 } \end{pmatrix} $
  2. Perform the indicated operation for the matrices shown below:

    $ P = \begin{pmatrix} { -1 }  &  { 0 }  & { – 1 } &  { 0 } \end {pmatrix} $

    $ Q = \begin{pmatrix} 10  & { 20 }  &  {- 30 } \end {pmatrix} $

    $ R = \begin{pmatrix} { – 7 }  &  { 1 }  & { 0 } \end {pmatrix} $

    $ S = \begin{pmatrix} { – 2 } &  { 3 }  & { – 2 } &  16 \end {pmatrix} $

    1. $ – \frac{1}{10} Q $
    2. $ P + S $
    3. $ Q – P $

Answers

  1. To find the transpose of a row vector, write the row as a column, that’s it!
    1. $ \begin{pmatrix} t \\ b \\ x \\ e \end {pmatrix} $
    2. $ \begin{pmatrix} { – 13 } \end{pmatrix} $
      Note, the transpose of a $ 1 \times 1 $ matrix is the matrix itself!
  2. Part (a) is scalar multiplication. We multiply each entry of matrix $ Q $ by the scalar, $ { – \frac{1}{10} } $.

    Part (b) is addition. Both matrix $ P $ and $ S $ are $ 1 \times 4 $ matrices. Thus, addition can be performed. 

    Part (c) is subtraction. Since the dimension of matrix $ Q $ is not the same as matrix $ P $, we can’t perform the subtraction.

    All of the answers are shown below:

    1. $ – \frac{1}{10} Q = { – \frac{1}{10} } \times  \begin{pmatrix} 10  & { 20 }  &  {- 30 } \end {pmatrix} $
      $ = \begin{pmatrix} (- \frac{1}{10} \times 10)  & (- \frac{1}{10} \times 20)  &  (- \frac{1}{10} \times {-30}) \end {pmatrix} $
      $ = \begin{pmatrix} { – 1 } & { – 2 } & 3 \end{pmatrix} $
    2. $ P + S = \begin{pmatrix} { -1 }  &  { 0 }  & { – 1 } &  { 0 } \end {pmatrix} + \begin{pmatrix} { – 2 } &  { 3 }  & { – 2 } &  16 \end {pmatrix} $
      $ P + S = \begin{pmatrix} { (-1+-2) } &  { (0 + 3) }  & { (-1 + -2) } &  (0 + 16) \end {pmatrix}  $
      $ P + S = \begin{pmatrix} { – 3 } & 3 & { – 3 } & { 16 } \end{pmatrix} $
    3. Subtraction not possible due to matrix $ Q $ and matrix $ P $ having different dimensions.

Previous Lesson | Main Page | Next Lesson