red and blue city map (John David Bigl III/

Open-source tool helps spot gerrymandered districts

To help ensure voting districts are equitably redrawn after the 2020 census, researchers have developed an open-source tool that can help congressional redistricting observers spot unusual configurations.

GerryChain uses mathematical and computational models to generate a representative collection of maps that would meet legal voting rules and priorities for new districts. It can be used as a baseline for comparison in the evaluation of newly proposed plans and can indicate outlier configurations that may be the result of partisan goals.

The software was first developed by a team led by Daryl DeFord, an assistant mathematics professor at Washington State University (WSU), as a part of the 2018 Voting Rights Data Institute. In 2018, GerryChain was used in Virginia to analyze maps proposed to remedy House of Delegates districts that a federal court ruled were unconstitutional racial gerrymanders.

It has already been downloaded 20,000 times, and the updated version will likely play a role in the upcoming redistricting based on 2020 census data.

“We wanted to build an open-source software tool and make that available to people interested in reform, especially in states where there are skewed baselines,” DeFord told WSU News.

A new paper, authored by DeFord along with Moon Duchin of Tufts University and Justin Solomon of MIT, describes how GerryChain’s models can be used to put proposed redistricting plans into context by creating large samples of alternative, but still legally valid maps for comparison.

Many states have hundreds of thousands of census blocks as well as rules and goals for how voting districts should be structured. Districts, for example, should be compact, geographically contiguous and leave counties and cities intact. Additionally, many states also like to protect “communities of interest,” which is often interpreted to mean areas with minority voters, while attempting to achieve political neutrality.

Even with all these rules, voting maps can still be drawn in billions of ways.

“There are more feasible plans in a lot of states than there are molecules in the universe,” DeFord said. “That’s why you want this kind of mathematical tool” that can produce an array of representative maps.

GerryChain uses a method called a spanning tree recombination or “ReCom” for short. It involves taking two districts, merging them together before splitting them apart again in a different way. This creates a greater change with multiple voting blocks changing at a time, WSU News explained.

The software can create alternative voting maps within a matter of hours, but the researchers stressed that GerryChain is a tool for analyzing baselines and evaluating alternatives and shouldn’t be relied on to create the voting plan that is ultimately adopted.

“This is not some sort of magic black box where you push the button, and you get a collection of perfect plans,” DeFord said. “It really requires serious engagement with social scientists and legal scholars. Because the rules are written and implemented by people, this is a fundamentally human process.”

GerryChain is freely available for use by voting reform groups or anyone who has knowledge of Python, the data software behind it.

About the Author

Susan Miller is executive editor at GCN.

Over a career spent in tech media, Miller has worked in editorial, print production and online, starting on the copy desk at IDG’s ComputerWorld, moving to print production for Federal Computer Week and later helping launch websites and email newsletter delivery for FCW. After a turn at Virginia’s Center for Innovative Technology, where she worked to promote technology-based economic development, she rejoined what was to become 1105 Media in 2004, eventually managing content and production for all the company's government-focused websites. Miller shifted back to editorial in 2012, when she began working with GCN.

Miller has a BA and MA from West Chester University and did Ph.D. work in English at the University of Delaware.

Connect with Susan at [email protected] or @sjaymiller.


  • Records management: Look beyond the NARA mandates

    Pandemic tests electronic records management

    Between the rush enable more virtual collaboration, stalled digitization of archived records and managing records that reside in datasets, records management executives are sorting through new challenges.

  • boy learning at home (Travelpixs/

    Tucson’s community wireless bridges the digital divide

    The city built cell sites at government-owned facilities such as fire departments and libraries that were already connected to Tucson’s existing fiber backbone.

Stay Connected