By Nick Marsh, BBC News
China and Australia are proof that governments do not have to like each other to do business.
When Anthony Albanese arrives in China on Saturday, he will be the first Australian prime minister to visit in seven years.
His three-day trip comes in the wake of plummeting relations between the two countries - and Canberra's growing military ties with Washington.
In recent years Australia and China have accused each other over human rights violations and perceived threats to national security. Public perceptions of the other side are more negative than they have ever been.
But when it comes to trade, they cannot afford to let go of each other. At the peak of their trading relationship in 2020, almost half of Australia's exports went to China.
By way of comparison, at around the same time roughly 9 percent of all US exports and only 5 percent of British exports were being sold to China.
Australia needs China
This kind of leverage can be a powerful tool if a government wants to make a point, which is what happened in 2020 when Australia called for an independent inquiry into the origins of Covid-19.
"That was deeply upsetting to the Chinese government," said Jane Golley, an economist at the Australian National University (ANU) in Canberra.
"Shortly after, the [Chinese] ambassador here gave a speech and suggested that some Australian industries might suffer as a consequence."
Sure enough, a string of Chinese tariffs and restrictions followed on an estimated A$20 billion (NZ$21.7bn) worth of Australian goods. Among the many products affected were barley, beef, wine, coal, timber and lobster.
"Basically the Chinese government was sending a message. They were unhappy with the Australian government and decided to use economic coercion to make that point," Golley added.
At the time, such a robust move from an important trading partner was a surprise to many. Since then, China has reversed many of the restrictions.
The decision to row back on the tariffs was, at least partly, helped by a change of tack from the newly elected Australian government.
Shortly after meeting with China's leader Xi Jinping at the G20 summit in Bali last year, Albanese said: "We're always going to be better off when we have dialogue and are able to talk constructively and respectfully."
He reminded Australians that trade with China was worth more than with Japan, the US and South Korea combined. Clearly, normalising relations between what he called "two highly complementary economies" would be a priority for his government.
Whether China's so-called economic coercion was successful is doubtful. Australia is still openly critical of Beijing on several fronts - but there is no question that Australian businesses and workers took a hit because of China's trade restrictions.
"We can't live without them, essentially," Golley said. "I think the Albanese government clearly decided that our economic links were too important to sacrifice and went for an improvement in our diplomacy."
China needs Australia
Australia has its own levers it can use to its advantage - especially when it comes to natural resources.
"China and Australia are deeply economically interdependent," said Benjamin Herscovitch, a research fellow at the ANU's National Security College.
Typically, China has been, and still is, highly reliant on Australia for raw materials to satisfy its vast and growing economy.
Huge amounts of its iron ore and liquefied natural gas, for example, come from Australia. Incidentally, neither of these commodities were subjected to Chinese restrictions.
The Chinese public can live without Australian wine and lobsters, but until the country is able to adequately source materials to make steel or power its factories, Beijing knows it is not in a strong position to start making demands of Australia.
Some analysts argue that China's trade restrictions were not forcing Canberra closer to Beijing - rather they had the opposite effect.
"The Chinese government started to realise that its coercive economic and diplomatic measures were driving Australia closer to the United States," said Herscovitch.
"Beijing's decision to remove trade restrictions and normalise diplomatic contact is aimed at wooing Canberra away from Washington."
One aim could be to gain Australian support for entry into the Comprehensive and Progressive Agreement for Trans-Pacific Partnership (CPTPP).
This is the successor to the doomed Trans-Pacific Partnership (TPP) - the free trade agreement from which then-US President Donald Trump withdrew. So far several countries, including Australia, have blocked China's attempts to join.
"To be blunt, China doesn't have that many friends in the world. We used to be one, but not any more," Golley said. "If you think about it, it makes sense to have a strong economic relationship with an ally of the United States. If you're being cynical, it gives you an opportunity to drive a wedge between us and Washington."
Having their cake and eating it
Given the heightened tensions with the US, it makes sense that China does not want to alienate America's allies.
Not only is Washington trying to exclude China from access to technology needed for advanced computer chips and critical minerals needed for green energy, it is also putting pressure on its allies to do the same.
Half of the world's lithium, for example, is in Australia. Chinese companies want access to such metals that are crucial for making electric vehicles, a field in which China is currently the global leader.
According to Golley, there is a danger that Australia and China become "competitors rather than collaborators" when it comes to issues they need to work together on, such as fighting climate change.
Australia's close political and military ties with the US mean it will inevitably fall on the American side of the superpower struggle.
But siding with a country whose economic policies actively harm China will only put more strain on the relationship and could risk landing both countries back at square one.
"I don't know how much longer this can continue", said Golley. "The Australian government wants a relationship with China in which, basically, we continue to export to them as normal."
"But at the same time we also diversify away from them and restrict their capital flows into the country. To me, that sounds like we want to have our cake and eat it too."
- This story was first published by the BBC.