A man suspected of killing six people, including a prominent forensic psychiatrist, in the Phoenix suburb of Scottsdale, Arizona, fatally shot himself as police closed in Monday, ending a days-long manhunt that has rattled many in the legal and mental-health communities.

Police on Monday afternoon identified Dwight Lamon Jones, a 56-year-old man who had been arrested for domestic violence in 2009 and had been living in hotels in the nine years since, as the gunman who shot the forensic psychiatrist, a psychologist and two paralegals. Each of those victims was loosely connected to his divorce proceedings, Scottsdale Assistant Chief of Police Richard Slavin said. Police also suspect Jones murdered a man and woman in a home in Fountain Hills, Arizona, before killing himself.

Slavin said ballistic evidence connected the killings of Steven Pitts, Veleria Sharp, Laura Anderson and Marshall Levine. On Sunday morning, police had identified Jones as the suspect and had taken a DNA sample from family members that they believed linked him to the crimes. Shortly after police began surveillance Sunday afternoon, they witnessed Jones dispose of a pistol; that was not the gun used in the crimes, police say, but they determined it belonged to the male victim from Fountain Hills.

Officers with the Scottsdale and Phoenix police departments tracked down the suspect at an Extended Stay hotel in Scottsdale on Monday morning. Sgt. Vince Lewis, a spokesman for the Phoenix Police Department, told reporters that Jones fired multiple gunshots from inside his room as tactical team members were evacuating the hotel. They later found Jones with a self-inflicted gunshot wound, Lewis said, adding that the officers did not fire their weapons.

The victims in the days-long killing spree worked in related fields, a fact that had raised fears that the suspect might be indiscriminately attacking people who worked in the criminal justice or court system in the Phoenix area.

The first victim was a prominent forensic psychiatrist who had consulted in high-profile murder cases, including the 1996 killing of child beauty-pageant star JonBenét Ramsey. Police said Pitt, 59, was shot Thursday afternoon outside his office on the outskirts of Scottsdale.

As part of Jones’ divorce proceedings, Slavin said, Jones had been required to see Pitt.

Less than 24 hours later after Pitt was found, about 2 p.m. Friday, two paralegals were shot at a law firm in downtown Scottsdale, across the street from government offices. Police said one of the women, who had been shot in the head, was able to get out of the building and flag a bus driver for help before she died. Police followed her blood trail and found the other victim.

Sharp, 48, and Anderson, 49, were paralegals for the family law firm Burt, Feldman, Grenier. Jones’ ex-wife, Connie Jones, had retained Elizabeth Feldman as her divorce lawyer, Slavin said.

The fourth victim was found dead just after midnight Saturday. Police said an acquaintance found Marshall Levine, 72, a psychologist and counselor, dead of a gunshot wound in his office, about halfway between the sites of the previous shootings.

Slavin said Jones’ son, as part of the divorce proceedings, was required to see a psychiatrist who occupied the office space that Levine is now in.

“He was a very emotionally disturbed person, as the court records will confirm,” Connie Jones said in a statement published by The Arizona Republic. “Personally, I have feared for my safety for the past nine years. I cannot express the emotions I feel for the innocent families touched by this.”

Police had initially said little about the suspect, other than that he was an adult male. Earlier, Phoenix police released a sketch of what appeared to be an older white man wearing a hat. On Monday afternoon, they released a photo of Jones, who is black.

Slavin said he couldn’t speak to Jones’ motivations, but evidence suggested he was angry about the divorce. Police said Dwight Jones had lived in various Extended Stay hotels for nine years. Connie Jones filed for divorce in 2009, but News 12, the local NBC affiliate, obtained records that showed the case was not resolved until 2017.

Enzo Yaksic, a criminal profiler and founder of Atypical Homicide Research Group at Northeastern University in Boston, said serial murderers are generally motivated by a desire for revenge — “angry and resentful individuals who believe they are settling a grievance for perceived or actual wrongs and blame others and the systems they represent for their problems.”

The suspect in the Phoenix-area killings fits that description, Yaksic hypothesized, based on information published about the deaths.

“This offender espoused the methodical calculation of the serial killer, the vengeful nature of the mass murderer and the swiftness and exigency of the spree killer,” Yaksic said. “Few offenders are adept at cycling from one typology to the next in quick succession as was done here.”

Before police identified Jones, some speculated that Pitt, the first victim, might have been killed because of his profession, a line of work that required him to study the minds of criminals.

“When Dr. Pitt was shot, it was speculated among a good number of people that it could be tied to a case,” said Justin Yentes, a private investigator in Phoenix who works with criminal defense attorneys in the area. “We work around these types of situations. There’s always a risk that you’ve upset the wrong person, I suppose. The general belief was that there was an upset party in a case that was potentially seeking revenge.”

Yentes said he knows of several law Phoenix-area law firms that did not open Monday because of fears of being targeted, and some have talked about having uniformed officers in their lobbies.

Steve Silverman, an insurance-claim lawyer, does not know any of the victims, but he has been on edge for a few days. Levine, the psychologist, was shot and killed across the street from Silverman’s house. And the hotel where Jones is said to have killed himself is right next to his office in Scottsdale’s Agua Caliente shopping center.

That the suspect killed the victims in their workplaces, and that he was unidentified for days, only raised fears for Silverman that he might run into the killer. Before news broke Monday morning that the suspect is dead, Silverman had contemplated not coming to work at all. The day before, he had planned to come to the office to do some work but decided to stay home.

“To me, it drives home the importance of maintaining a sense of awareness or vigilance. I feel absolutely awful for the family members of the victims,” Silverman said.

That paralegals were attacked also struck a nerve with him.

“None of these things are rational, but it seems particularly irrational to attack paralegals. That was just beyond the pale,” Silverman said. “That was a degree of recklessness and anger and rage that was beyond what I might have expected.”

The Washington Post was unable to reach the law firm where the paralegals worked. In a statement to the Arizona Republic, the firm said both Sharp and Anderson were dedicated and treasured members of its staff. Both were wives and mothers.

Pitt, a clinical associate professor of psychiatry at the University of Arizona College of Medicine in Phoenix, was known for his role in the investigation into the death of JonBenét Ramsey, a child beauty-pageant star who made national headlines in 1996 when she was found dead in her family’s home in Boulder, Colorado.

Pitt also helped police as they tried to solve a string of crimes that terrorized Phoenix in 2006. Mark Goudeau, nicknamed the “Baseline Rapist” and later the “Baseline Killer” because the crimes first happened along Phoenix’s Baseline Road, was convicted of more than five dozen charges, including several counts of murder, rape and kidnapping.

A biography on Pitt’s website says he also consulted and advised prosecutors in the Colorado rape case against Kobe Bryant and in the Columbine High School shooting investigation.

Levine, the fourth victim, owned a clinic called Peak Life Solutions and was a “life coach hypnotherapist,” according to his profile on Psychology Today.

“I coach because serving, fostering & supporting my clients in reaching their goals & overcoming their challenges gives purpose to my life,” Levine’s profile reads. “My clients’ fulfillment is my joy.”

There have been several serial murderers in the Phoenix area over the years, said Yaksic, whose organization maintains a database on 2,700 serial killers nationwide. Most recently, a man named Cleophus Cooksey Jr. was accused of fatally shooting nine people in Phoenix, including his mother and her boyfriend, in November and December.