Linear Combinations

Mix two parts blue paint with one part yellow and you get a specific, repeatable green — not "some greenish colour," but exactly the same green every time you use those proportions. Change the proportions — three parts blue, one part yellow — and you get a different, equally specific colour. Every shade you can mix from a small shelf of paint tins is reachable this way: scale each tin by some amount and pour them together.

Vectors work the same way. Put our two moves together — if you can scale vectors and add them, you can build a linear combination: pick some "ingredient" vectors, multiply each by a scalar, and add up the results.

a\,\vec{u} + b\,\vec{v}.

The scalars a and b are the weights — exactly like "two parts" and "one part" in the paint recipe. Different weights reach different vectors. This one little expression is, no exaggeration, the central idea of the whole subject — almost everything ahead, from span to eigenvectors, is a question about linear combinations in disguise.

You've been doing this outside of maths class your whole life without a name for it. A recipe that calls for "two cups of flour plus half a cup of sugar" is a linear combination of a flour-vector and a sugar-vector. A DJ fading between two tracks is combining a "track A" signal and a "track B" signal with weights that slide from (1, 0) to (0, 1) and everywhere between. Once you see the pattern — scale some ingredients, add them up — you start noticing it everywhere.

Worked example: the easy case

Start with the simplest possible ingredients: \vec{u} = (1, 0) (a unit step right) and \vec{v} = (0, 1) (a unit step up). How do we build the vector (7, 4) out of them?

We just need 7 copies of \vec{u} and 4 copies of \vec{v}:

7(1, 0) + 4(0, 1) = (7, 0) + (0, 4) = (7, 4).

That looks almost too easy — because it is. With these particular ingredients, the weights you need are just the vector's own components. That's not a coincidence: it's the reason (1,0) and (0,1) are called the standard basis — every vector in the plane names its own recipe against them. The interesting question is what happens with ingredients that aren't so convenient.

Mixing two vectors

Below, \vec{u} and \vec{v} are fixed. Turn the two weight dials and watch a\,\vec{u} + b\,\vec{v} roam the plane. The faint guides show the scaled pieces a\,\vec{u} and b\,\vec{v} laid tip-to-tail, exactly like pouring one paint tin after the other; the bold arrow is their sum — the mixed colour.

Notice that dragging a weight past zero doesn't break anything — the guide just flips to point the other way. A negative weight is a perfectly normal ingredient amount here, even though "minus one part yellow" would be nonsense at the paint counter. And the extreme settings are worth a look too: set b = 0 and the sum collapses onto pure a\,\vec{u} — you've switched off the second ingredient entirely. Set both weights to 0 and, no matter what \vec{u} and \vec{v} are, you land exactly on the origin — the "zero" linear combination always gives the zero vector.

Worked example: solving for the weights

Building a combination from given weights is easy — the harder, more useful question runs backwards: given a target vector, what weights hit it? Let the ingredients be \vec{u} = (1, 1) and \vec{v} = (1, -1), and the target be (5, 1). We want

a(1, 1) + b(1, -1) = (5, 1).

Matching components gives two ordinary equations in a and b:

a + b = 5, \qquad a - b = 1.

Add the equations: 2a = 6, so a = 3. Then b = 5 - a = 2. Check it:

3(1, 1) + 2(1, -1) = (3, 3) + (2, -2) = (5, 1). \checkmark

A linear combination problem is always secretly a small system of equations wearing a vector costume — a fact that becomes the entire engine room once matrices arrive. Notice, too, why the word "linear" is in the name: each ingredient only ever gets scaled and added, never squared, multiplied by another ingredient, or fed through some curved function. That restriction to straight-line operations is exactly what keeps the algebra this simple — swap in a squared weight or a product of two ingredients and you've left linear algebra behind entirely.

Worked example: too many ingredients, many recipes

What happens with three ingredient vectors instead of two? Take \vec{u} = (1, 0), \vec{v} = (0, 1), and a third one, \vec{w} = (1, 1), and aim for the target (5, 3) again. Using only \vec{u} and \vec{v}, the recipe is the obvious one:

5\vec{u} + 3\vec{v} + 0\vec{w} = (5, 0) + (0, 3) + (0, 0) = (5, 3).

But bring \vec{w} properly into the mix and a completely different recipe works just as well:

4\vec{u} + 2\vec{v} + 1\vec{w} = (4, 0) + (0, 2) + (1, 1) = (5, 3).

Two genuinely different sets of weights, same target vector — and in fact there are infinitely many more, one for every value you choose for the weight on \vec{w}. That's the opposite problem from the parallel-vector case below: instead of not enough reach, we now have too many ingredients, so the recipe stops being unique. A third vector in the plane is always "redundant" in this sense — it can always be built from the other two, which is precisely what makes it possible to swap weights around and still land on the same point.

Where can you reach?

Try to land the bold arrow on a few different points in the box above. With these two \vec{u} and \vec{v} you can reach every point in the plane — there's exactly one pair of weights for each target. That "reach" has a name, span, and it's the gateway to the next stage.

But that "reach everything" outcome isn't automatic — it depends on the ingredients you're given. Suppose instead your two vectors were \vec{u} = (2, 4) and \vec{v} = (1, 2). Look closely: \vec{v} is just half of \vec{u} — they point along the same line through the origin. Can any weights reach the target (5, 1)?

a(2, 4) + b(1, 2) = (2a + b,\ 4a + 2b) = (2a + b,\ 2(2a + b)).

Whatever a and b are, the second component is always exactly twice the first. For (5, 1) we'd need 1 = 2 \times 5, which is false — no weights exist. Two parallel ingredients can only ever pour you back onto their shared line, no matter how you scale them. That gap between "sometimes you can reach everywhere" and "sometimes you're trapped on a line" is exactly what linear independence is built to explain, and what makes a basis a basis.

The same question gets richer once you step up a dimension. Two non-parallel vectors in the flat plane can already reach every point in that plane — two ingredients are enough. But two non-parallel vectors sitting inside three-dimensional space can only ever reach the single flat sheet that contains them both; reaching every point in 3D space needs a third ingredient that isn't a combination of the first two. How many ingredients you need to reach "everywhere" turns out to be one of the deepest questions in the subject — it's called the dimension of the space you're trying to fill.

The paint analogy is useful, but it can quietly mislead you: nobody at a paint counter asks for "negative one part red." A linear combination, though, allows any real number as a weight — positive, negative, zero, or a fraction like \tfrac{1}{2}. -3\vec{u} + 0.7\vec{v} is just as legitimate a linear combination as 2\vec{u} + 5\vec{v}. A negative weight simply flips the ingredient vector around before adding it in.

The second trap is the parallel-vector case above: two vectors that point the same way (or exactly opposite ways) can never escape their shared line, no matter how large or small, positive or negative the weights get. "I can use any real numbers" does not mean "I can reach any point" — it depends entirely on which ingredients you started with.

A third, smaller trap: don't assume more ingredients always means more reach. As the "too many ingredients" example above shows, a third vector in the plane doesn't unlock any new territory at all — it just gives you extra, equally valid recipes for points you could already reach.

A useful sanity check for any of these traps: plug your weights back into a\,\vec{u} + b\,\vec{v} and add the components by hand, the way the worked examples above do. If the arithmetic doesn't land back on your target, no amount of clever reasoning about the picture will save a wrong pair of weights.

Every colour on the screen in front of you is a linear combination in disguise. Each pixel has three tiny lights — red, green, and blue — and the colour you see is

r\,(1,0,0) + g\,(0,1,0) + b\,(0,0,1),

where (1,0,0), (0,1,0) and (0,0,1) are the three "pure" ingredient colours and r, g, b are brightness weights between 0 and 255. Pure yellow on your screen isn't a yellow light at all — it's the linear combination (255, 255, 0), full red plus full green with no blue, and your eye blends the mix into a colour that isn't in the original three tins at all. Every photo, video, and web page you've ever looked at has been billions of linear combinations, computed sixty times a second.

The same three-ingredient idea runs the speakers next to your screen too: a stereo mix is a linear combination of every individual instrument's track, weighted by its volume fader — turn a fader up and you're just increasing that instrument's weight in the sum.

A GPS receiver doesn't magically know where it is — it works entirely by linear combinations. Each orbiting satellite tells your phone, in effect, "you are somewhere on a sphere of this exact radius, centred on me." Your phone combines the position vectors of several satellites, weighted by how far each signal had to travel, and solves for the one point consistent with all of them — the same "solve for the weights" move as the paint-mixing worked example above, just running in three dimensions with four or more ingredient vectors instead of two.

Miss a satellite or two and the combination becomes under-determined, exactly like being stuck with only parallel ingredients — there are suddenly many points consistent with the data instead of one, and your blue dot on the map starts wobbling.

See it explained