The online bluster adds up to what sociologists call a sense of aggrieved entitlement, and like virtually all mass murders, Mr. Bourque’s alleged actions — he now faces three first-degree murder charges, and two of attempted murder — sought to ease it by indulging in a brutal revenge.

“That’s part of a much larger trend that has been noted by the FBI in the United States and seems to have cross-cut the borders between the United States and Canada. There are larger numbers of organized groups, but each of them is very small in size, consisting of typically a few friends. And in addition there are more lone wolves. This makes it very difficult for federal agents to infiltrate,” said Jack Levin, professor of sociology and criminology at Northeastern University in Boston, and author of Extreme Killing: Understanding Serial and Mass Murder.