About 11,000 Americans die each year from firearm-related homicides. Monday’s shooting at Washington, D.C.’s Navy Yard that killed 12 victims and the gunman is sure to spawn debates about gun rights, gun control and how to reduce those deaths. All too often, these discussions are not based on logic and science, as with other public health problems, but are awash in heated emotions and void of substance.

As we saw with the horrendous Newtown, Conn. shooting that killed 20 elementary school children and six faculty members last December, debates over gun violence often devolve to senseless shouting matches.

Let’s consider one of the most central questions in the gun debate: Do more deaths occur because guns are easily available to all? Or can guns actually protect citizens and reduce deaths?

These are hard questions to answer, in no small part because there is little research that has attempted it. In a major reversal for scientists working in the field of injury prevention, President Obama recently labeled firearm-induced deaths a public health crisis and ended a longstanding funding freeze for research in this critical area.

Past studies have compared how many gun deaths occur in different places with different gun availabilities to people. Such work, however, is very difficult to interpret because there are also other factors that hide the correct trends, such as social and economic differences.

Diseases such as AIDS that lead to similar numbers of deaths per year, are approached very differently. There is more than one opinion on how HIV infection should be managed and treated. These opinions are voiced at scientific discussions, and the arguments are based on data and logical reasoning, with the goal to arrive at the best possible treatment strategy.

To study the “epidemiology” of gun-related murders, we designed a new scientific approach in a study recently published in PLOS one. We explore the effect of different gun policies virtually in the computer, and predict what types of policies minimize deaths.

Because funding from the government was previously unavailable for research into gun violence, only limited amounts of data exist that can be fed into our computations. With the available data, however, we found that gun-induced murders would be minimized if private possession of firearms was banned, much like blanket bans in Britain and Australia. If such a ban is not feasible, as likely is the case here in the U.S., the computations suggest that a partial reduction in gun availability might decrease the number of firearm-induced murders, although this needs to be confirmed by future work.

Our calculations work in some sense like a navigation app on a smartphone. Let’s say we would like to drive from our work place, Irvine, Calif., to downtown Los Angeles. Several different routes can be taken. Which one is the fastest? As anybody who has driven in this area can confirm, this is very hard to figure out. Different routes have different distances, speed limits, and different amounts of traffic congestion and road work. If we simply try out a certain route based on our gut feelings, we might get severely delayed. A navigation app uses available data on distances, speed limits, and current traffic and suggests the fastest route to the destination, hopefully without getting stuck.

Similar to the navigation apps, our computer tool uses available data — not distances, speed limits, or traffic, but data on gun usage. For instance, we use the fraction of the general population who owns guns and carries them around, the likelihood of illegal gun possession by criminals and the amount of protection offered by a gun when you are attacked. Our computer app reads in these data and calculates the gun policy that minimizes murders.

As many people who have used navigation apps can confirm, they can sometimes lead you in the wrong direction, especially when the app is relatively new and requires further data to be more accurate. This also applies to our computations. This is the first time that such a tool has been developed, and further work certainly will lead to improvements.

The availability of more data will lead to greater accuracy in the future, and we hope that our work will motivate the collection of this information. For example, current data suggest that guns do not offer much, if any, protection for the life of a person who is being attacked with a firearm. This certainly has an important influence on the result of our computations. It is, however, possible that in cases where guns do save lives during attacks, this is not reported to authorities and is not recorded in data. Careful field studies will have to be conducted to assess this and other issues.

While our computer tool is still, so to say, in “beta version,” one thing is a hundred percent certain: The development of such scientific approaches is vital. It is always a better idea to follow paths that have been paved by data and logic than to blindly follow roads without guidance and direction.

Wodarz and Komarova are professors of ecology and evolutionary biology and mathematics at the University of California Irvine.