Three inmates who teamed up to pull off an intricate escape from a California jail stuck together and eluded authorities for nearly a week. Then authorities said their alliance began to unravel over a disagreement on whether to kill a cab driver they'd taken hostage.

Six days after their breakout — and 400 miles to the north — fugitives Hossein Nayeri and Bac Duong came to blows in a San Jose motel room because Nayeri wanted to kill the man and bury his body and Duong did not, authorities said Monday. Duong prevailed but the next day left with the hostage, traveled back to Orange County and turned himself in.

The cab driver, who suffered only minor injuries, immediately went to authorities. The following day, Nayeri and the third fugitive, Jonathan Tieu, 20, were arrested in San Francisco after an alert citizen spotted the stolen van near a Whole Foods Market parking lot.

The trio's rapid undoing after days on the lam was a dramatic end to an escape plan that authorities believe was first hatched by Nayeri six months earlier after he was jailed on charges of torture and kidnapping for allegedly cutting off a man's penis because he believed he had buried a large sum of money in the desert.

When Duong was booked into the Central Men's Jail in December on attempted murder charges, he provided an outside contact who helped Nayeri execute his plan, including the smuggling of a knife into the jail, authorities said.

Tieu, who was awaiting trial on a gang-related murder charge, also joined in, authorities said.

"This took a while," Orange County Sheriff Sandra Hutchens said. "To defeat these security systems, to defeat these metal grates, to defeat these 1-inch bars, it took some time."

Once out, the three were picked up by the accomplice that Duong had provided and driven to safety.

That night, Duong kidnapped a taxi driver at gunpoint and then stole a van the following day in Los Angeles, authorities said.

The fugitives and the cab driver spent three nights at a motel in Southern California before they drove 400 miles north to the San Francisco Bay Area in the taxi and van.

They stayed in a San Jose motel two nights and Nayeri and Duong fought over the cab driver's fate, Hallock said.

When Nayeri and Tieu left the motel the next day to get the van's windows tinted, Duong drove back to Southern California with the cab driver and surrendered Friday at an auto repair shop in Orange County just miles from the jail. He told authorities his fellow fugitives were last in San Jose and confirmed they were still using the white van.

Nayeri and Tieu were arrested Saturday in San Francisco after a man spotted the stolen van near a Whole Foods Market parking lot.

Loc Ba Nguyen, the alleged outside accomplice who knew Duong, has been charged with felony counts of possession of a weapon in a place of custody, carrying or sending a useful aid to escape from a jail or prison and aiding escape, with a criminal enhancement for being in possession of a dangerous or deadly weapon. Among the items he smuggled in was a knife, authorities allege.

He will be arraigned later this month and has not entered a plea. He is free on $300,000 bail.

In their detailed account of the escape, authorities said the trio waited until after a 5 a.m. head count on Jan. 22 then slipped through a hole they had sawed in a metal grate that led to a plumbing tunnel. They then crawled through piping inside the jail walls to reach the roof, pushed aside barbed wire and rappelled down four stories using a rope made of sheets.

By 5:15 a.m., they were outside and picked up by Nguyen. They bounced from one home to the next that day, moving among three different Orange County cities.

At 9:30 p.m. — as guards realized they were missing — the trio took a cab to a Target in suburban Los Angeles. They shopped for unknown items then kidnapped the taxi driver, authorities said.

The next day, Duong stole the van during a test drive and the three got haircuts to disguise themselves before checking into a motel in Rosemead with the hostage.

It was the first escape in nearly three decades from the California facility built in 1968.