BEIJING • North Korea's nuclear antics have rattled its alliance with China to the point that Beijing is allowing the previously unthinkable to be discussed: Is it time to prepare for the renegade regime's collapse?

While China's official goal is to bring Washington and Pyongyang to the negotiating table, it is permitting once-taboo debate on contingencies in case war breaks out in the nation across its north-east border.

Observers say the public debate might be a tactic to try and coerce Pyongyang into cooling its weapons programme, with its nuclear and missile tests visibly angering Beijing, which has backed tough new United Nations sanctions on the country. But it may also reflect growing calls to overhaul its relationship with North Korea, a long-term ally.

Professor Jia Qingguo, dean of the School of International Studies at Peking University, raised eyebrows last month when he published an article titled Time To Prepare For The Worst In North Korea. The paper was published in English in East Asia Forum, a website of the Australian National University, but it is unlikely that he could have released it without the approval of the Chinese authorities.

Prof Jia urged Beijing to start discussing contingency plans with the United States and South Korea - talks that the two countries have sought in the past but that China has resisted for fear of upsetting Pyongyang.

"When war becomes a real possibility, China must be prepared. And, with this in mind, China must be more willing to consider talks with concerned countries on contingency plans," he wrote.

Beijing, he said, could discuss who would control North Korea's nuclear arsenal - the US or China.

To prevent a massive flow of refugees across the border, China could send its army to North Korea to create a "safety zone", he said. Another touchy issue would be who would "restore domestic order in North Korea in the event of a crisis".

China, he said, would object to letting US soldiers cross the 38th parallel into North Korea.

An August editorial in the state-run nationalist tabloid Global Times said China should remain neutral if North Korea launches missiles against the US and Washington retaliates, and intervene only if the US and South Korea try to overthrow the Pyongyang regime.

Discussions about the end of the North's regime could be aimed at scaring Mr Kim Jong Un and pleasing Mr Donald Trump before the US leader's trip to Beijing next month, a Western diplomat said.

US Secretary of State Rex Tillerson met President Xi Jinping and top Chinese diplomats in Beijing last Saturday to discuss the North Korean nuclear crisis.

"If the international community can unite and pretend there's going to be a real war, there is a chance that North Korea will freeze its nuclear tests," research fellow Wang Peng of Fudan University in Shanghai told Agence France-Presse.

But there are also signs of a genuine shift. Dr David Kelly, director of research at Beijing-based consultancy China Policy, said the thinking among Chinese academics was: "We could do better without them, a unified Korea would be incredibly good for China, the north-east would boom."

China has long supported North Korea because it serves as a buffer from US troops stationed in South Korea, but Dr Barthelemy Courmont, a China specialist at the Institute of Strategic and International Relations in Paris, said Pyongyang's downfall could be good for Beijing, especially economically.

"China now believes that a collapse of North Korea would not necessarily be to its disadvantage," said Dr Courmont. "If North Korea were to fall in a peaceful way, China would be best positioned for its reconstruction. China is the only country capable of overseeing the reconstruction of North Korea."

But dropping Pyongyang is not that simple, Dr Kelly said, adding: "The problem is, how do you cut the cord, because nobody knows what North Korea will do."

AGENCE FRANCE-PRESSE