President Ahmadinejad's statement on Tuesday that Iran will "welcome genuine changes" in US policy and is "prepared to talk" to the new American administration has been linked by commentators in the west, as well as the wider Middle East, to President Obama's statement just one day earlier when, in his first press conference since taking office, he reiterated his willingness to directly talk to the Islamic Republic.

It is understandable that analysts and observers are focusing on the possibility of a thaw in US-Iranian relations. And, indeed, after eight long years of a Manichean "you're either with us or against us" approach in Washington there is hope that this new American administration will actually pay attention to realities on the ground.

However, it is surprising that the pundits chose to focus almost exclusively on foreign politics and Obama's effect on Ahmadinejad because the Iranian president's new, conciliatory tone may have resulted less from the American overture than from a somewhat pedestrian rationale, based more in the domestic realpolitik of Iran.

Just two days before Ahmadinejad's speech, Mohammed Khatami, the former Iranian president and acclaimed champion of the country's so-called "reform" camp, announced that after long deliberations (and much prodding from supporters) he will run in the Iranian presidential elections in June.

Until Khatami's announcement, Ahmadinejad was considered the clear frontrunner. There were some other possible contenders, some from the conservative camp like Ali Larijani and others from among the reformers, but none with the incumbent's level of support among the hardline Islamists, like the Revolutionary Guards, or the folksy charm that endeared him to the Iranian masses. Also, none of the reformers who so far had talked about challenging Ahmadinejad possessed the ability to mobilise the youth and the women ¬– the two constituencies that twice brought Khatami to power and which must be won over in order to truly challenge the conservative voting machine.

But now that Mohammed Khatami has (finally) made his choice, the cards are dealt anew and Ahmadinejad finds himself in a serious electoral race. Add to this the fact that Ayatollah Ali Khamenei, the Supreme Leader of Iran, who has both publicly backed Ahmadinejad and criticised his government and policies, is long said to personally dislike the current president and may, now that Khatami is posing a real challenge to the incumbent, very well look for another, more promising conservative candidate to back.

All this will have influenced President Ahmadinejad 's (somewhat) softer tone towards the "Great Satan" America in his speech last Tuesday. If he wants to win the June election, he will have to show that he is not obstinate in his foreign policy and that he is in tune with the majority of the Iranian people who want a thawing of relations with the west. With Iran feeling the effects of the global economic crisis, particularly much higher food prices, the oil price at under $40 a barrel and the last years' profits already blown on PR projects, the Iranian president's economic populism has failed and the country's population is less inclined to vote for him on the grounds of foreign policy grandstanding alone.

While the vast majority of Iranians – conservatives and reformers alike – believe their country has the right and duty to play the role as regional (super)power, it is doubtful that many support a course of total confrontation with the west. And with Khatami now returning to the helm of the reform camp, Ahmadinejad is likely to continue the softer tone on talks with the United States. Should there also be meetings between American and Iranian diplomats, on however low a level, before the June elections he might actually be able to convert this talk into electoral votes.