We all know how the Democratic nomination contest works, right? Well, we think we do.

People go and vote in primaries or caucuses in their states. The votes are counted and we see who wins. And then those votes get translated ... somehow ... into how many delegates each candidate gets.

Even many hardened political obsessives tend to fast-forward through that last bit: the delegate math. It’s complicated and confusing, so why bother?

But the delegate math is incredibly important: It determines who wins. A candidate needs a majority of delegates to get the nomination at the Democratic National Convention. (Bernie Sanders has recently argued that delegates should just give the nomination to whoever wins a plurality, but the current rules do not require that.)

So how do you get delegates? In the Democratic contest, it’s not just about winning states, it’s about how much you win by and how much of the vote you get in both states and congressional districts. There are no winner-take-all states; instead, all delegates are awarded proportionally.

What makes things especially tricky this year is, for the first time in nearly three decades, the Democratic field won’t just be a two-candidate contest on Super Tuesday, March 3. Because of that, small changes in the vote count — and particularly in who manages to top the 15 percent threshold necessary to get any delegates — can shape the delegate totals in surprising ways.

For instance, if the leading candidate gets 30 percent of the vote somewhere, they could end up getting around one-third of delegates at stake. But with the exact same vote share, they could also end up with two-thirds of delegates — a dramatic difference, particularly since a majority is necessary to win.

The difference depends entirely on how many other candidates top 15 percent and on how far above it they are. Voters may not realize that if they cast their ballot for a candidate who ends up falling below that threshold, they could be supercharging the leading candidate’s delegate haul.

So it’s very much worth understanding what happens when votes get converted into delegates. And happily, Democrats do at least use the same delegate allocation formula everywhere — meaning, once you learn how it works in one state, you’ll understand how it works everywhere. Let’s walk through it.

Four steps to get from votes to delegates

The best way to explain how this will all work is to walk you through a sample scenario based on the candidates currently in the race. Though these numbers are made up, remember that the examples below are all completely plausible outcomes on Super Tuesday. (Note: Former South Bend, Indiana, Mayor Pete Buttigieg and Sen. Amy Klobuchar dropped out of the race just before Super Tuesday.)

Step 1 — Meeting the threshold: Once the votes somewhere (either in a state or in a congressional district) have come in, the first crucial number in the delegate math is the 15 percent threshold.

As you probably know, candidates need 15 percent or more of the vote somewhere to be eligible to get any delegates there. If a candidate is below that, they’re out of luck.

But another crucial step here is that the votes for any candidates getting below 15 percent are then excluded from the count for the purposes of delegate allocation.

Delegates are actual people and can’t be split into fractions. So we need to end up with whole numbers here.

The way Democrats ensure this is they start with just the whole numbers (avoiding the decimals for now) — so Sanders gets 3, Biden 2, Warren 2, and Buttigieg 1.

That means eight of the 10 delegates have been awarded, and there are two left over. You look at the part of the number after the decimal point to determine who gets those. Biden’s 0.777 is the highest, so he gets one, and Buttigieg’s 0.666 is second highest, so he gets the other one.

The final delegate tally here, then, is:

Sanders 3

Biden 3

Warren 2

Buttigieg 2

So though Sanders got the most votes, he ended up tying Biden in delegates due to rounding, because Biden was close enough on his heels and rounding happened to work in his favor.

That’s how the delegate allocation formula works. You can apply it to the vote total in any state or congressional district with a primary to walk through how the delegates get divvied up.

How this math can produce quirky results with such a crowded field

In a two-candidate race like the ones Democrats had in 2008 and 2016, this isn’t all that tricky. Both candidates almost always top 15 percent, and there are just a small number of votes for anyone else. So their percentage of delegates ends up closely matching their percentage of votes.

But when the vote is split among multiple candidates, things can get messier because of that crucial 15 percent threshold.

As an example, let’s say the vote breakdown is only slightly different from the one above, with Bernie Sanders getting the exact same percentage of overall votes but the rest of the field shaking out differently:

Applying those percentages to 10 delegates means no rounding is necessary — the final delegate tally would be:

Let’s pause on this. Sanders here ended up with 60 percent of the delegates at stake, but in the earlier example he ended up at 30 percent (the same as Biden) after rounding. And he got the exact same number of votes and percentage of the statewide total in both examples.

It’s a dramatic difference — particularly when you keep in mind that you need an outright majority of delegates (not just a plurality) to be assured of the nomination. For any one candidate to get on track for that, they need to win majorities of delegates in a lot of places. So when it comes to big statewide delegate hauls like those in California and Texas, the difference between the winner getting 30 percent or 60 percent of those delegates is massive.

It could get even more dramatic. If one candidate is the only person to clear 15 percent, they get all of the delegates at stake. And in a contest where delegates are allotted proportionally, it’s a huge win for any candidate to be able to scoop up 100 percent of them somewhere.

So in a messy race like this, it’s not just about who wins. It’s about how much that person wins by and how many other people manage to top 15 percent of the vote.

Most delegates are allotted based on congressional district results

There’s one other important-but-confusing part of Democrats’ delegate rules: that delegates are awarded in different batches in each state.

First off, around 65 percent of delegates across the country are actually awarded according to the results in individual districts — not states. The above formula (from the 15 percent threshold to rounding) gets applied in every district. Most states use congressional districts, though Texas uses state senate districts instead.

So if you miss 15 percent statewide but get there in one or more congressional districts, you will pick up delegates in that state (as Pete Buttigieg did in Nevada). Conversely, if you top 15 percent statewide but miss that threshold in several districts (because your support is concentrated in one or a few districts), you’ll lose out on a bunch of delegates.

Second, there’s even some confusion with the statewide delegates, because most states award them in two separate batches. There are the ordinary “at large” statewide delegates, and then there are the PLEOs, or “party leaders and elected officials.” (These aren’t the infamous “superdelegates” who can support whomever they want; pledged PLEO delegates are pledged to back a certain candidate based on the results in the contest.)

Using the same statewide results, the delegate allocation formula is applied separately to both the at-large delegate batch and the PLEO delegate batch. The proportional results will be similar, but due to the rounding step, there can be differences in how the delegates end up in each batch.

As an example, here’s how Arkansas (a Super Tuesday state) allocates its delegates in six batches.

Statewide at-large: 7 delegates

Statewide PLEOs: 4 delegates

First Congressional District: 4 delegates

Second Congressional District: 6 delegates

Third Congressional District: 5 delegates

Fourth Congressional District: 5 delegates

So you see here that most of Arkansas’s delegates are given out according to the congressional district results. That’s the case in every state (except for those small states with just one congressional district, where this is irrelevant).

The big picture for the 2020 Democratic contest

So, yes, that was a lot. But here’s a brief summary cheat sheet to tie it all together:

The basic math: For delegate allocation, all votes for candidates who have not reached 15 percent support are excluded. Each candidate’s percentage of what’s left over determines what percentage of delegates they get. Rounding also comes into play.

For delegate allocation, all votes for candidates who have not reached 15 percent support are excluded. Each candidate’s percentage of what’s left over determines what percentage of delegates they get. Rounding also comes into play. The math’s implications: That 15 percent threshold can make the delegate results swing wildly depending on how many candidates meet it and how much support those candidates get. If almost all of the vote is cast for candidates meeting the threshold, the results will look proportional. But if there are lots of votes “wasted” on candidates below 15 percent, the candidates who do meet the threshold can reap big delegate gains.

That 15 percent threshold can make the delegate results swing wildly depending on how many candidates meet it and how much support those candidates get. If almost all of the vote is cast for candidates meeting the threshold, the results will look proportional. But if there are lots of votes “wasted” on candidates below 15 percent, the candidates who do meet the threshold can reap big delegate gains. The many delegate batches: Statewide results are important, but more delegates are actually awarded based on the results in hundreds of congressional districts across the country. The delegate allocation math, the 15 percent threshold, and rounding apply individually to the results in all these districts. Fun!

Statewide results are important, but more delegates are actually awarded based on the results in hundreds of congressional districts across the country. The delegate allocation math, the 15 percent threshold, and rounding apply individually to the results in all these districts. Fun! Majorities matter: Whether you get the most delegates isn’t all that matters; whether you’re on track for a majority of delegates is also quite important. If the “winner” on Super Tuesday gets half or more of the delegates, they’d be in a commanding position. If they’re far short of that, their position will be more tenuous.

Got all that? Good. Now you’re ready to make sense of Super Tuesday’s results.