There appears to be a triad of factors that sets these killers apart. The first is that they are generally struggling with mental health problems that have produced their desire to die. The specific psychiatric diagnoses vary widely, and include everything from clinical depression and post-traumatic stress disorder to schizophrenia and others forms of psychosis. The suicide rate was 12.4 per 100,000 people in the United States in 2010 (the highest in 15 years). Suicide is relatively rare, but it is rarer still in most Muslim countries. This is a very limited pool from which most suicide terrorists and rampage shooters come.

The second factor is a deep sense of victimization and belief that the killer’s life has been ruined by someone else, who has bullied, oppressed or persecuted him. Not surprisingly, the presence of mental illness can inflame these beliefs, leading perpetrators to have irrational and exaggerated perceptions of their own victimization. It makes little difference whether the perceived victimizer is an enemy government (in the case of suicide terrorists) or their boss, co-workers, fellow students or family members (in the case of rampage shooters).

The key is that the aggrieved individual feels that he has been terribly mistreated and that violent vengeance is justified. In many cases, the target for revenge becomes broader and more symbolic than a single person, so that an entire type or category of people is deemed responsible for the attacker’s pain and suffering. Then, the urge to commit suicide becomes a desire for murder-suicide, which is even rarer; a recent meta-analysis of 16 studies suggests that only two to three of every one million Americans commit murder-suicide each year.

The third factor is the desire to acquire fame and glory through killing. More than 70 percent of murder-suicides are between spouses or romantic or sexual partners, and these crimes usually take place at home. Attackers who commit murder-suicide in public are far more brazen and unusual. Most suicide terrorists believe they will be honored and celebrated as “martyrs” after their deaths and, sure enough, terrorist organizations produce martyrdom videos and memorabilia so that other desperate souls will volunteer to blow themselves up.

Similarly, rampage shooters have often been captivated by the idea that they will become posthumously famous. “Isn’t it fun to get the respect that we’re going to deserve?” the Columbine shooter Eric Harris remarked. He had fantasized with his fellow attacker, Dylan Klebold, that the filmmakers Steven Spielberg and Quentin Tarantino would fight over the rights to their life story.