Iran's supreme leader Ayatollah Ali Khamenei has called for "heroic flexibility" in the country's stand during nuclear talks, signalling willingness for diplomatic engagement with the west.

Addressing Iran's Revolutionary Guards commanders, Khamenei said: "I agree with the issue that I called some years ago as heroic flexibility since this move is highly good and necessary on certain occasions, but with commitment to one main condition."

Khamenei, who wields the ultimate authority in Iranian affairs, added: "A wrestler sometimes shows flexibility for technical reasons. But he does not forget about his opponent or about his main objective."

Khamenei's remarks come at a time when Iran and the US are trying to reach out to each other over Iran's controversial nuclear programme.

The Iranian leader firmly denied that Iran is seeking to acquire nuclear weapons. "We do not believe in nuclear weapons because of our beliefs, not for the sake of the US or other countries, and when we say that no country should possess nuclear weapons, we ourselves are definitely not trying to possess them."

It was earlier reported that Khamenei had authorised the newly elected president Hassan Rohani to hold direct talks with the US on Iran's nuclear activities.

Alongside Khamenei's comments, President Barack Obama has also struck a conciliatory note. In an interview with the Spanish-language broadcaster Telemundo, he said: "There is an opportunity here for diplomacy. And I hope the Iranians take advantage of it."

Both Iran and the US had earlier confirmed the exchange of letters between Obama and Rohani.

Although it was earlier speculated that the two leaders would meet on the sidelines of the UN General Assembly, the White House said no such meeting has been scheduled.

Shortly after his takeover as president, moderate cleric Rohani had pledged to pursue a flexible approach towards the US.