An inquest into a deadly siege in a Sydney cafe began on Thursday, aimed at determining exactly how a gunman and two of his hostages ended up dead after a 16-hour standoff with police.

Man Haron Monis, a 50-year-old Iranian-born, self-styled cleric with a long criminal history, burst into a downtown cafe last month and took 18 people hostage. Over the next 16 hours, Monis forced his hostages to outline his demands in a series of online videos — including that he be permitted to speak to the prime minister and be delivered a flag of the Islamic State group. The standoff finally ended when police stormed the cafe in a barrage of gunfire to free the captives. Two hostages were killed, along with Monis.

Police have not said whether hostages Tori Johnson, the 34-year-old manager of the Lindt Chocolat Cafe, and Katrina Dawson, a 38-year-old lawyer, were killed by Monis or in police crossfire. Unconfirmed reports have since emerged that Johnson died while trying to wrestle the shotgun away from Monis, allowing several of his fellow hostages to escape before police moved in. But authorities have never clarified exactly what happened.

The coronial inquest — a court-like proceeding convened after unusual deaths in Australia — is aimed at determining how Monis and his captives died and whether their deaths could have been prevented.

"Rarely have such horrifying events unfolded so publicly," Coroner Michael Barnes told the court. "Overlaying the intense personal suffering on display were fearsome themes which called up wider and more far-reaching threats that understandably terrified many, even among those who only saw it from afar. ... We will do all within our power to undertake a comprehensive investigation that is rigorous, independent and searching."

Separately, Prime Minister Tony Abbott has ordered a sweeping government review of the siege and the events leading up to it. The review, expected to be released in the next week or two, will examine why Monis was out on bail despite facing a string of violent charges, including 40 counts of sexual assault and accessory to murder in the slaying of his ex-wife. The review will also address how Monis obtained a shotgun despite Australia's strict gun laws.

Monis was on the Australian Security Intelligence Organisation's watch list in 2008 and 2009, but was later dropped from it. The agency was tracking Monis because he had sent a series of offensive letters to the families of dead Australian soldiers.