In my linear algebra course I keep seeing something like this:

a = {1, 3, 5}

Then in formulas I see this:


What does this mean, what is the absolute value of a vector? Wouldn't just be {1,3,5}?


2 Answers 2


Keep in mind that absolute value is distance from zero. So you can use the distance formula to find the absolute value:

$$ \sqrt{x^2+y^2+z^2} $$

  • 4
    $\begingroup$ It wouldn't happen to be coincidence that this also equals the sqrt of a dot producted with itself would it? Is there any significance there $\endgroup$
    – Ogen
    Commented Mar 11, 2014 at 10:49
  • 2
    $\begingroup$ Yep, it is exactly the same thing. For a dot product, you multiply corresponding elements: here, we multiply the x, y, and z values. $\endgroup$
    – baum
    Commented Mar 11, 2014 at 10:59
  • $\begingroup$ Shouldn't that result in the authors question's answer being 5 since the sum of those squares leads to 25 and thus the square root of 25 being 5 and thus the answer too. Also, is this generally accepted as the way to calculate the value of a given vector when given e.g. |v|? $\endgroup$
    – user784446
    Commented Jul 4, 2020 at 13:38
  • $\begingroup$ @user784446 - The sum of squares is $35$, not $25$. $\endgroup$
    – mr_e_man
    Commented May 4, 2022 at 17:48

Absolute value of a vector means taking second norm of the vector i.e. $\|x\|$. That means the same thing as $\sqrt{x_1^2 +x_2^2+...+x_n^2}$. I don't understand why some top researchers in computer science abuse the notation where $|x|$ is widely used for absolute value of scalars in math.

I have also seen papers using $|x|$ to mean absolute value of each component of the vector $x$. In summary, meaning will depends upon the context and author.

  • $\begingroup$ This is not helpful at all...... $\endgroup$
    – user99914
    Commented Jul 2, 2015 at 9:44
  • $\begingroup$ @JohnMa, can you explain me how? or if you know what does $|x|$ exactly mean, where x is a vector? $\endgroup$
    – CKM
    Commented Jul 2, 2015 at 10:00
  • $\begingroup$ If the OP knows what is a norm, probably (s)he won't ask this question. Moreover, you are just changing the notation from $|x|$ to $\|x\|$. How is that helpful? Will the OP get the definition after seeing your answer? $\endgroup$
    – user99914
    Commented Jul 2, 2015 at 10:04
  • $\begingroup$ @JohnMa. Thanks. I should have taken Ogen knowledge level into account. $\endgroup$
    – CKM
    Commented Jul 2, 2015 at 10:15

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .