David Niven, a professor of political science at the University of Cincinnati, holds a map showing a gerrymandered district in Ohio. (John Minchillo/AP)

Note: This is an update to a story that was originally published in 2015.

The U.S. Supreme Court ruled Thursday that the federal courts have no rule to play in adjudicating questions of partisan gerrymandering, essentially letting individual states decide how best to deal with the question.

In most states, the drawing of congressional and legislative districts is handled by state legislatures. That creates a strong incentive for partisan lawmakers to draw districts in a way that benefits their own party. Here’s how it works.

Suppose we have a very small state with just 50 people. Thirty of them belong to the Blue Party while the rest align with the Red Party. For the purposes of our illustration, they happen to live in a nice orderly grid, with Blues on one side of the state and Reds on the other.

Now, let’s say the mapmaker is tasked with drawing five equal population districts. The voters in each district will send one representative to the U.S. House of Representatives. The simplest way to do this would be to draw nice long districts, as in Option 1 above. That creates three Blue-only districts and two that are all Red. The state ends up sending two Red Party and three Blue Party representatives to the House, perfectly representing the state’s partisan split.

But let’s say the mapmaker is a member of the Blue Party and realizes that all five districts can be drawn in a way that gives Blue voters the majority in each one. The Election Day plays out as one might expect, leaving the state without a single Red representative. Option 2 shows how a majority party can use gerrymandering to dilute the political power of the minority.

But what if the mapmaker is a member of the Red Party? With some creative geometry, the line drawer can create three districts with a majority of Red voters, and two that are mostly Blues. That gives us Option 3, showing how a minority party can actually give itself a majority of seats if it controls the redistricting process.

Most of the gerrymandering that people get upset about is of the Option 3 variety. Much of it was done by Republicans after the 2010 Census in the last redistricting cycle. In some states, like Pennsylvania and North Carolina, Republicans were able to draw districts that gave them majorities in their statehouses and congressional delegations, despite winning only a minority of votes statewide.

In 2012 in Pennsylvania, for instance, Republicans garnered only 49 percent of the votes statewide in U.S. House races but captured 13 of the 18 House seats.

There’s less information about Democratic gerrymandering simply because Democrats were in control of fewer statehouses after 2010 and, hence, had less ability to redraw districts to their liking. But Maryland stands out as a prime example of Democratic gerrymandering. In 2016, Republicans won 37 percent of the statewide House popular vote, which translated into just one of the state’s eight House seats.

As in Option 3 above, one classic tell of gerrymandering is the convoluted district borders, which happen when lawmakers attempt to grab one group of voters from far away or exclude a different group that’s nearby. But even compact boundaries, as in Option 2 above, can be unfair. Ultimately gerrymandering comes down to a question of intent: Were the people in charge of the boundaries deliberately trying to advantage one party or another?

To reduce or eliminate the temptation to use redistricting as a political weapon, a number of states have taken steps to remove lawmakers from the process completely. From a practical standpoint, that usually means putting mapmaking authority into the hands of a bipartisan independent commission, although states that have done this differ in how much influence the legislature has in creating these commissions.

The Supreme Court ruling means opponents of flagrantly partisan gerrymandering done by either party will not be able to turn to the federal courts for relief. However, much of the action around gerrymandering in recent years has happened at the state level. In Pennsylvania, for instance, the state Supreme Court overturned the Republican-drawn lines.

In other states, meanwhile, voters recently approved ballot measures to let independent commissions draw legislative districts. Redistricting reformers are vowing to carry on the fight at the state level in the wake of the Supreme Court’s decision. But the court’s decision nonetheless means that we’re likely to see a wave of unprecedented partisan gerrymandering in the wake of the 2020 Census, particularly in states where politicians are still allowed to draw their own districts.