1. Two views of a vector
Ask a physicist what a vector is and you'll hear "an arrow with magnitude and direction." Ask a programmer and you'll hear "a list of numbers." Both are right, and the secret to linear algebra is that they describe the same thing.
Geometric: a directed segment in space — an arrow — characterized by how long it is and which way it points. Where the arrow starts doesn't matter; only its length and direction do.
Algebraic: an ordered tuple of numbers, written $\vec{v} = (v_1, v_2, \ldots, v_n)$. Each number is a component. The number of components is the vector's dimension.
To translate between the views, plant the tail of the arrow at the origin. The coordinates of its tip are the components. So the vector $\vec{v} = (3, 4)$ is the arrow that runs from $(0, 0)$ to the point $(3, 4)$; the vector $\vec{u} = (1, 2, 3)$ runs from the origin out to the point $(1, 2, 3)$ in 3-D space.
Vectors are written several ways: $\vec{v}$, $\mathbf{v}$ (bold), or simply $v$ when context is clear. Components are listed as $(v_1, v_2, \ldots)$ in a row, or stacked in a column $\begin{pmatrix} v_1 \\ v_2 \end{pmatrix}$. The column form will become important once matrices arrive.
2. Vector addition
Two vectors can be added, and the result is another vector. Both views give the same answer — they just describe the operation differently.
Geometric (tip-to-tail). Draw the first vector. Pick up the second and slide it (without rotating) so its tail sits on the tip of the first. The sum is the new arrow that runs from the original tail to the final tip.
Algebraic (component-wise). Add the matching components.
$$ (a, b) + (c, d) = (a + c,\; b + d) $$For example, $(1, 2) + (3, 1) = (4, 3)$. Plot all three and the rule becomes visually obvious: the second arrow, starting where the first one ended, lands at exactly the spot the sum points to.
Sliding v over by u shifts each of its coordinates by the matching coordinate of u — which is exactly what component-wise addition does. The geometry isn't a separate fact about vectors; it's the same fact, drawn.
Vector addition is commutative ($\vec{u} + \vec{v} = \vec{v} + \vec{u}$) and associative ($(\vec{u} + \vec{v}) + \vec{w} = \vec{u} + (\vec{v} + \vec{w})$). Both are obvious from the algebra — addition of real numbers is commutative and associative — and almost as obvious from the picture once you draw the parallelogram.
The tip-to-tail picture has a twin: draw both $\vec{u}$ and $\vec{v}$ from the same tail, complete the parallelogram they span, and the diagonal from that shared tail is the sum $\vec{u} + \vec{v}$. It's the same fact as tip-to-tail seen from a different angle — and it makes commutativity visually obvious, since the diagonal doesn't care which side of the parallelogram you walked first.
A free vector has no fixed location — the same arrow drawn anywhere on the page represents the same vector. A position vector is a free vector with its tail conventionally pinned to the origin, so its tip identifies a specific point. The vector $\vec{v} = (3, 4)$ is free; calling it "the position vector of the point $(3, 4)$" just commits to drawing it from the origin.
3. Scalar multiplication
Multiplying a vector by an ordinary number — called a scalar in this context — scales its length. If the scalar is negative, it also flips the direction.
$$ c \cdot (v_1, v_2, \ldots, v_n) = (c\,v_1,\; c\,v_2,\; \ldots,\; c\,v_n) $$Every component is multiplied by the same number $c$. Geometrically:
- $c = 2$ doubles the arrow's length, same direction.
- $c = \tfrac{1}{2}$ halves it.
- $c = -1$ flips it — same length, opposite direction.
- $c = 0$ collapses it to the zero vector $(0, 0, \ldots, 0)$.
For example, if $\vec{v} = (3, 4)$, then $2\vec{v} = (6, 8)$ and $-\tfrac{1}{2}\vec{v} = (-1.5, -2)$. The arrow points the same way (or the exact opposite way), only stretched.
The word scalar just means "a number that scales." In the basic setting that's a real number; later, when we work over the complex numbers, scalars can be complex. The distinction matters because vectors and scalars live in different worlds — vectors stack into lists, scalars are single numbers.
Combining addition and scalar multiplication lets you write linear combinations like $3\vec{u} - 2\vec{v}$, which are the bread and butter of the rest of linear algebra. A linear combination of vectors $\vec{v}_1, \vec{v}_2, \ldots, \vec{v}_k$ is any expression of the form $c_1 \vec{v}_1 + c_2 \vec{v}_2 + \cdots + c_k \vec{v}_k$ where the $c_i$ are scalars. Every vector in $\mathbb{R}^2$, for instance, can be written as a linear combination of $(1, 0)$ and $(0, 1)$ — that's what "coordinates" really are.
In $\mathbb{R}^n$, the standard basis is the collection of unit vectors that have a $1$ in one slot and $0$ everywhere else: $\vec{e}_1 = (1, 0, \ldots, 0)$, $\vec{e}_2 = (0, 1, 0, \ldots, 0)$, up to $\vec{e}_n = (0, 0, \ldots, 1)$. In $\mathbb{R}^2$ and $\mathbb{R}^3$, these are often written $\hat{i}, \hat{j}, \hat{k}$.
Any vector decomposes as a linear combination of them: $(3, 4) = 3\hat{i} + 4\hat{j} = 3\vec{e}_1 + 4\vec{e}_2$. The components are the coefficients in this combination.
4. Magnitude and unit vectors
The magnitude (or length, or norm) of a vector is exactly what it sounds like: how long the arrow is. For a 2-D vector, draw the right triangle whose legs are the two components and apply the Pythagorean theorem:
$$ \|\vec{v}\| = \sqrt{v_1^2 + v_2^2} $$So $\|(3, 4)\| = \sqrt{9 + 16} = \sqrt{25} = 5$. The same idea generalizes: in $\mathbb{R}^n$, square each component, add, take the square root.
$$ \|\vec{v}\| = \sqrt{v_1^2 + v_2^2 + \cdots + v_n^2} $$Magnitude is always non-negative. It equals zero only for the zero vector — the one vector with no direction at all.
A vector of magnitude exactly $1$. Unit vectors are useful because they isolate direction from length.
To turn any non-zero vector into a unit vector pointing the same way — a process called normalizing — divide it by its own magnitude:
$$ \hat{v} = \frac{\vec{v}}{\|\vec{v}\|} $$The hat $\hat{v}$ is the standard notation for "this is a unit vector." For $\vec{v} = (3, 4)$ with magnitude $5$, the unit vector is $\hat{v} = (3/5, 4/5) = (0.6, 0.8)$. Check: $0.6^2 + 0.8^2 = 0.36 + 0.64 = 1$, so its length is indeed $\sqrt{1} = 1$.
You can normalize any non-zero vector, but $\vec{0}$ has no direction at all — and dividing by $\|\vec{0}\| = 0$ is undefined. There is no "unit zero vector."
5. Where vectors live: $\mathbb{R}^n$
The set of all ordered pairs of real numbers — every $(x, y)$ in the plane — is called $\mathbb{R}^2$. The set of all ordered triples $(x, y, z)$ is $\mathbb{R}^3$. The pattern is general: $\mathbb{R}^n$ is the set of all ordered $n$-tuples of real numbers, and an element of $\mathbb{R}^n$ is an $n$-dimensional vector.
| Space | A typical element | How to picture it |
|---|---|---|
| $\mathbb{R}^1$ | $(7)$ | A point — or signed length — on the number line |
| $\mathbb{R}^2$ | $(3, 4)$ | An arrow in the plane |
| $\mathbb{R}^3$ | $(1, 2, 3)$ | An arrow in 3-D space |
| $\mathbb{R}^n$, $n \geq 4$ | $(v_1, \ldots, v_n)$ | You can't picture it — but the algebra still works exactly |
Here is the punchline of the whole subject: the rules you just learned — add component-wise, scale every component, take the square root of the sum of squares for the length — work in every dimension. Nothing about the algebra cares whether $n$ is $2$, $3$, or $10\,000$. Most theorems of linear algebra are proven once, dimension-agnostically, and apply everywhere.
Linear algebra is the study of vectors in $\mathbb{R}^n$ and the operations that respect their structure. The fact that we can't visualize $\mathbb{R}^{10}$ doesn't matter; the algebra is the visualization.
This is why a 768-dimensional word embedding, a 12-megapixel image flattened into a vector of $3.6 \times 10^7$ pixel values, and the arrow on a 2-D blackboard are all the same kind of object. Once you trust the algebra, the geometry of low dimensions is just a useful sketch.
In this topic, the dimension of a vector is the number of components — straightforward. Later, "dimension" will be redefined for whole vector spaces in terms of how many independent vectors you need to span them. The two notions will turn out to agree for $\mathbb{R}^n$, but they're not literally the same definition.