If you're seeing this message, it means we're having trouble loading external resources on our website.

If you're behind a web filter, please make sure that the domains *.kastatic.org and *.kasandbox.org are unblocked.

Main content

Vectors and notation

Learn about what vectors are, how we can visualize them, and how we can combine them.
Vectors are the building blocks of everything multivariable. We use them when we want to represent a coordinate in higher-dimensional space or, more generally, to write a list of anything. In this article, we'll cover what vectors are, different ways to write them, and the three basic vector operations.

What is a vector?

Most generally, a vector is a list of things. In multivariable calculus, "thing" typically ends up meaning "number," but not always. For example, we'll see a vector made up of derivative operators when we talk about multivariable derivatives. This generality is super useful down the line.

Vectors and points in space

When a vector is just a list of numbers, we can visualize it as an arrow in space. For example, we visualize the vector (4,2) as an arrow whose tail is at the origin and whose tip is at the point (4,2). For this reason, we don't usually distinguish between points and vectors in multivariable calculus.
However, sometimes we draw a vector with the tail away from the origin. This changes nothing about the vector, only where we draw it. For example, we can also draw the vector (4,2) starting at (0,2). Both arrows correspond to the vector (4,2), even though one of them doesn't end at the point (4,2).
This is why it can sometimes be confusing to write vectors exactly like points in space. For this reason, people have come up with other notations for vectors.

Notation

There are lots of ways to write vectors. Here are the three we'll use most in this course. The little arrow on top of v is a convention that indicates that v refers to a vector.
v=(1,2,3)=[123]=1ı^+2ȷ^+3k^
The first notation is what we discussed earlier. Technically it refers to a point, but we use it interchangeably to refer to a vector. This notation extends to any number of dimensions.
The second notation is matrix notation, which we can also extend to as many dimensions as we want. Matrix notation is particularly useful when we think about vectors interacting with matrices. We'll discuss matrices and how to visualize them in coming articles.
The third notation, unlike the previous ones, only works in 2D and 3D. The symbol ı^ (pronounced "i hat") is the unit x vector, so ı^=(1,0,0). Similarly, ȷ^=(0,1,0) and k^=(0,0,1). This notation might make more sense once we cover vector addition.
In this course, we almost always use the (1,2,3) notation in exercises, because it saves space when we need to define multiple variables. The videos use a mix of matrix notation and the 1ı^+2ȷ^+3k^ notation.

Addition

One of the basic vector operations is addition. In general, whenever we add two vectors, we add their corresponding components:
(a,b,c)+(A,B,C)=(a+A,b+B,c+C)
This works in any number of dimensions, not just three. We can visualize the sum a+b as sliding the tail of b to the tip of a. Here's an example of that in 2D.
Let's try a practice question.
Problem 1
(3,2)+(1,4)=
(
  • Your answer should be
  • an integer, like 6
  • a simplified proper fraction, like 3/5
  • a simplified improper fraction, like 7/4
  • a mixed number, like 1 3/4
  • an exact decimal, like 0.75
  • a multiple of pi, like 12 pi or 2/3 pi
,
  • Your answer should be
  • an integer, like 6
  • a simplified proper fraction, like 3/5
  • a simplified improper fraction, like 7/4
  • a mixed number, like 1 3/4
  • an exact decimal, like 0.75
  • a multiple of pi, like 12 pi or 2/3 pi
)

If you want to go deeper, learn about how to understand vector addition visually with this video, and get practice with this exercise.

Scalar multiplication

The second basic vector operation is scalar multiplication, which is when we stretch or shrink a vector. Scalar is just a fancy word for number (same root as the word scaling). Here's an example of how it works:
b=(1,2,3)2b=(2,4,6)0.5b=(0.5,1,1.5)b=(1,2,3)
In general, scaling a vector by a number means multiplying each of the vector's components by that number. That means
xa=x(a,b,c)=(xa,xb,xc)
Let's try an example.
Problem 2
If a=(2,1),
then 3a=(
  • Your answer should be
  • an integer, like 6
  • a simplified proper fraction, like 3/5
  • a simplified improper fraction, like 7/4
  • a mixed number, like 1 3/4
  • an exact decimal, like 0.75
  • a multiple of pi, like 12 pi or 2/3 pi
,
  • Your answer should be
  • an integer, like 6
  • a simplified proper fraction, like 3/5
  • a simplified improper fraction, like 7/4
  • a mixed number, like 1 3/4
  • an exact decimal, like 0.75
  • a multiple of pi, like 12 pi or 2/3 pi
).

The intuitive meaning of scaling a vector by a factor of 2 is that we are making the vector twice as long. Here's what that looks like:
Scaling by a factor of 0.5 makes a vector half as long. This would look like the above vector (2,4) becoming (1,2), instead of the other way around.
Scaling by a factor of 1 means flipping the direction of a vector, because each of its components becomes the opposite of what it used to be. Here's an example of what that looks like:
If you want to go deeper, check out this video, and get practice with this exercise.

Magnitude

When we visualize vectors as arrows, a natural question to ask might be, "How long is it?" The magnitude of a vector answers this question. We write the magnitude of a vector with double bars on both sides, or sometimes with just single bars: a or |a|.
We calculate the magnitude with the Pythagorean theorem, because we can think of a vector as the hypotenuse of a triangle. This is equivalent to using the distance formula, so the magnitude of the vector (a,b) is a2+b2.
Let's try an example.
Problem 3
If a=(2,5), then a=

Magnitude works the same in 3D and in higher dimensions.
Problem 4
If b=(2,3,1), then b=

If you want to go deeper, check out this video, and get practice with this exercise

What's next

Beyond addition, scalar multiplication, and magnitude, there are two more important operations between vectors. These are the dot product and the cross product, and we will cover them in the next two articles.

Want to join the conversation?

  • cacteye blue style avatar for user Yatish Juneja
    Why can't we use the i-hat notation for vectors in higher dimensions? Is it because we can't imagine vectors in >3 dimensions using orthogonal unit vectors? If this is the case then how can the notion of using Pythagorean theorem to calculate the magnitude of a vector be extended to higher dimensions (>3)?
    (5 votes)
    Default Khan Academy avatar avatar for user
    • blobby green style avatar for user lakern
      Hi Yatish, good question. The reason we can't use i-hat notation beyond three dimensions is just that we only have so many letters available: i-hat, j-hat, k-hat. You could of course define further basis vectors with other letters. For >3 dimensions, we typically number these vectors in the subscript, for instance e_1, e_2, ..., e_9. The Pythagorean Theorem is true in all dimensions.
      (18 votes)
  • blobby green style avatar for user Even
    So far vectors seem simple (for me at least) but still don't understand how a vector can be 3D
    (3 votes)
    Default Khan Academy avatar avatar for user
  • starky ultimate style avatar for user borg972
    "We calculate the magnitude with the Pythagorean theorem, because we can think of a vector as the hypotenuse of a triangle."
    But the angle between two vectors can be any angle, so why does this work even if the 3 vectors (a, b, a+b) do not form a right angle triangle?
    (3 votes)
    Default Khan Academy avatar avatar for user
    • blobby green style avatar for user Deny C
      Vectors a and b are always right angles to each other, so you can use the Pythagorean theorem to determine the magnitude (or length) of a+b. It is true that the angles between a and a+b or b and a+b can be any angle between (but not including) 0 and 90 degrees, but that doesn't matter when calculating the Pythagorean theorem.
      (2 votes)
  • aqualine ultimate style avatar for user Liang
    any more explanations regarding “Magnitude works the same in 3D and in higher dimensions”? I understand how it works in 2D.

    e.g., sqrt{(-2)^2 + 3^2 + 1^2} = sqrt14

    thx
    (1 vote)
    Default Khan Academy avatar avatar for user
    • primosaur seed style avatar for user Ian Pulizzotto
      The formula for the magnitude of a vector (Pythagorean theorem) naturally extends to any number of dimensions. The magnitude of an n dimensional vector is the square root of the sum of the squares of its n components.
      In symbols,

      |<x_1, x_2,…, x_n>|
      = sqrt(x_1^2 + x_2^2 +…+ x_n^2).

      Have a blessed, wonderful Thanksgiving!
      (2 votes)