0

i started to study linear algebra, and also searched a lot about the differences between Row vector and Column vector,
I know this quistion asked a lot here, and i read that somtimes this is all about notation and row vector and Column vector are the same thing(or maybe i dont understand well).

So if to my understanding Row vector and Column vector can represent the same thing,
lets say A=(1x3) row vector is a Transposed column vector B=(3x1)
why when we multiply AB we get (1x1) mean scalar, but when we multiply BA we get (3x3) matrix.

i understand that the order matter, but the question is Why we got different results when row vector and column vector are the same thing?
I just started to study linear algebra, so i probably wrong about this. I just try to understand the difference between a row vector and a column vector.

thanks

  • 2
    Short version: just how matrix multiplication works. Don't get hung up on row vs. column vector. – Sean Roberson Oct 25 '22 at 15:08
  • 3
    "when row vector and column vector are the same thing?" They aren't though. They can both be used to convey information, but the physical objects themselves are not the same. – JMoravitz Oct 25 '22 at 15:17
  • 1
    Does this answer your question? Row vector vs. Column vector – JMoravitz Oct 25 '22 at 15:17
  • 1
    We can write them all as column vectors and just the use the transpose to differentiate between these cases. So $x^Ty$ is a scalar but $xy^T$ is a matrix. The first is an inner product, the latter is called an outer product and they're both useful when studying linear systems. For example orthogonal projection matrices will be of the form $P=uu^T$ with $\vert u \vert =1$. – CyclotomicField Oct 25 '22 at 15:27
  • i can't answer with mention both 3 users. so i split my comment @JMoravitz Thanks for the source, I came across this but couldn't figure out the difference through it yet. – Basecode Oct 26 '22 at 11:09
  • @CyclotomicField i still not in this level of understanding, maybe inner product and outer product will give me an answer my question. – Basecode Oct 26 '22 at 11:10
  • @SeanRoberson sure but i am trying to understand the reason why there is row vector and column vector. maybe my search for understanding come from lack of understanding, i dont know yet – Basecode Oct 26 '22 at 11:10
  • 1
    "but couldn't figure out the difference through it yet" That is like not being able to tell the difference between three short bushes and one tall tree. Yes, they both may have the same total amount of plant-matter, but the one is better at lining a house and the other is better at providing shade. The one is wide, the other is tall. They are physically different. Now... granted... if the only thing I wanted to convey is "here is a list of three numbers" then I could have done so with either row or column, but it is a choice which I use and depending on the choice... – JMoravitz Oct 26 '22 at 12:05
  • 1
    ...the ways in which I interact with them will be different. Note also that if I am in a situation where I have a matrix $A$ and a column vector $x$ in an equation such as $Ax=b$ so we have a matrix followed by a column vector, then there is the related equation where I just transpose both sides: $(Ax)^T=(b)^T$ which can be simplified as $x^TA^T=b^T$ which you will see is a row vector followed by a matrix. Yes... they are related. Yes, both can be used... but you have to be consistent how you use them and understand that as objects their shape and orientation matters. – JMoravitz Oct 26 '22 at 12:08
  • 1
    "Why there is row vector and column vector" Why don't we just have the one object? Because they are both being described as matrices... and matrices have a specific number of rows and a specific number of columns, and the orientation of the matrix matters. An $m$-row $n$-column matrix can be thought of as representing a linear operator mapping an element of $\Bbb R^n$ to an element of $\Bbb R^m$. Why do we have a choice? Because some authors prefer the one over the other. Not really any other reason. I prefer writing $Ax=b$ rather than $yC=d$. Others may disagree. – JMoravitz Oct 26 '22 at 12:16
  • Thanks for the help @JMoravitz , I thought that a column vector and a row vector indicated something specific and not subject to interpretation. as i wrote to other answer, i think my association of linear algebra with geometry is what limits me in a way of thinking, the geometric interpretation of the row vector and column vector makes me wonder what they represent... – Basecode Oct 26 '22 at 12:56
  • ...If we speak Geometry, can i say row vector and column vector are the same point, tuple in F^n?

    i asked my teacher if i can treat a row matrix as a point in a F^n? he told me that i can see a row matrix as vector in F^n. So as i know vector are usually represented in a column. so this is when I started to get confused. so in some cases they are the same and in some cases row vector and column vector are different, everything is how i chose to use them? @JMoravitz

    – Basecode Oct 26 '22 at 12:56
  • 1
    If we are just talking about $\Bbb F^n$, the elements in that are "vectors" but there is no distinction yet between "row" versus "column". At that point, we may as well be using parentheses and not square brackets. It isn't until we start to use matrices to represent them that the distinction becomes important. It should be clear that $\Bbb F^n$ is similar in nearly every way that matters to $\Bbb F^{1\times n}$ and also in nearly every way to $\Bbb F^{n\times 1}$, so much so that we might gloss over the fact that they are actually different. – JMoravitz Oct 26 '22 at 13:00
  • 1
    "We can see as a..." in the same way we can see the natural number $1$ as "being the same" as the integer $1$ or as the real number $1$ despite these all being fundamentally different objects as sets when considered formally. The exact mechanics of how multiplication works for each are different and far more complicated as we get deeper. Despite that, we know what "one-ness" is and the shared properties they all have and can talk about "$1$" without specifying or caring which until it becomes relevant and important. Same here with your vectors. – JMoravitz Oct 26 '22 at 13:04
  • You have brought me closer to a better understanding, greatly appreciate your help! Thank you @JMoravitz – Basecode Oct 26 '22 at 13:22

1 Answers1

2

Actually, row vector and column vector aren't the same thing. As a beginner think of 1x3 matrix as three one-dimensional vectors and 3x1 matrix as one three-dimensional vector.

In order to understand the difference between the products, consider these examples for (1x3) row matrix * (3x1) column matrix and (3x1) column matrix * (1x3) row matrix, respectively:

  1. A restaurant offered three types of meal with given amount and price: $$\begin{array}{|c|c|c|} \hline & \text{Amount} & \text{Price} \\ \hline \text{Meal 1} & 5 & \text{12\$} \\ \hline \text{Meal 2} & 8 & \text{10\$} \\ \hline \text{Meal 3} & 10 & \text{15\$} \\ \hline \end{array}$$

You can find total revenue by matrix multiplication: $$ \begin{bmatrix} 5 & 8 & 10 \end{bmatrix} \times \begin{bmatrix} 12\\ 10\\ 15\\ \end{bmatrix} = \begin{bmatrix} 290 \end{bmatrix} $$ So, as you can see, first matrix has three one-dimensional vectors (as I mentioned before) which represents amount of each meal, whereas second matrix has one tree-dimensional matrix representing prices.

  1. You want to hire an employee for 3-day work and you want to know how much salary should you pay for three days (with different working hours) for three different salaries:

$$\begin{array}{|c|c|c|} \hline \text{Day} & \text{Hours} & \text{Salary} \\ \hline 1 & 5 & \text{12\$} \\ \hline 2 & 8 & \text{10\$} \\ \hline 3 & 10 & \text{15\$} \\ \hline \end{array}$$

Again you can use matrix multiplication: $$ \begin{bmatrix} 5\\ 8\\ 10 \end{bmatrix} \times \begin{bmatrix} 12 & 10 & 15\\ \end{bmatrix} = \begin{bmatrix} 60 & 50 & 75\\ 96 & 80 & 120\\ 120 & 100 & 150 \end{bmatrix} $$

Here first matrix represents working hours of three days and second matrix represents three different salaries. Finally, you get a matrix which has three columns representing cost for three different salaries and has three rows representing three days. For example, element at second row, second column represents the cost for second day, 10$ salary.

  • Thanks for a detailed answer with a good real life example, sometimes it sheds light from different perspective on this subject and it really helps. I think my association of linear algebra with geometry is what limits me in a way of thinking, the geometric interpretation of the row vector and column vector makes me wonder what they represent.. – Basecode Oct 26 '22 at 12:05
  • 1
    Did you learn what are basis, linear transformations? If not, it will be clear for you when you reach to these topics – Şirin Əhmədov Oct 27 '22 at 12:50