PALO ALTO — The fatal confrontation between 31-year-old William David Raff and three police officers outside a residential treatment center for the mentally ill on Christmas night took just 19 seconds from start to finish, police said in a statement Tuesday.

Raff was armed with a metal knife and ignored repeated commands to drop it, according to the statement. Police described the knife as 9 inches long, with “one lightly serrated edge and a tapered, slightly rounded tip.”

The officers also retreated into the street, called for emergency backup and tried to summon an additional “less-lethal tool” before opening fire on Raff, according to the statement.

“But the suspect ignored commands to drop the knife and suddenly charged them,” police said in the statement.

One officer shot Raff with a Taser and two others opened fire with their pistols. It remained unclear Tuesday how many times Raff was shot, but police said nine bullet casings were recovered at the scene.

Police identified the officers who fired their pistols as Nicholas Enberg and Zachary Wicht. The officer who fired the Taser was not identified.

According to the statement, Enberg has five years of law enforcement experience and Wicht 1 years. Both have been placed on paid administrative leave, which is standard procedure in officer-involved shootings.

The encounter was captured in its entirety from multiple angles on audio and video recording systems in several patrol cars, according to the statement. Police declined to release the footage Tuesday.

Police said three independent witnesses who were walking in the neighborhood at the time of the shooting and watched what happened have also provided statements to investigators.

The fatal confrontation began around 9:16 p.m. on Christmas Day, when Raff called 911 and told dispatchers that someone at Momentum for Mental Health on the 600 block of Forest Avenue wanted to harm a person at the facility, according to the statement.

Police said there was no mention of a weapon during the 911 call, but Raff provided the name of the alleged aggressor, according to the statement. However, no one by that name was present.

As officers arrived at the residential treatment center and began walking toward the front lawn, Raff emerged from the shadows, “brandishing a knife in his hand and jumping around erratically,” according to the statement.

The officers called for backup and retreated toward their patrol cars, repeatedly ordering Raff to drop the knife as they did so, according to the statement. One of the officers also asked for a unit equipped with a less-lethal weapon that fires a rubber round to respond to the scene.

Raff, meanwhile, moved to the middle of the street and continued jumping around erratically, according to the statement.

“Officers continued to repeat their commands to drop the knife, but the suspect ignored them,” police said in the statement. “The suspect then suddenly sprinted directly at the officers while screaming and waving the knife.”

Raff got close enough to Enberg that he had to move to avoid being struck by Raff as he fell after being shot, according to the statement.

The officers provided first aid to Raff until paramedics arrived and took him to a hospital, where he later died. No officers were injured.

Footage of the encounter, along with all other evidence and investigative reports, will be turned over to the Santa Clara County District Attorney’s Office once the police department wraps up its investigation, according to the statement.

Prosecutors are also conducting their own, parallel investigation into the officer-involved shooting.

Anyone with information about the incident is asked to call the city’s 24-hour dispatch center at 650-329-2413.