TEHRAN, FEB. 4 -- President Ali Akbar Hashemi Rafsanjani said today that Iran has presented Iraq with "ideas" to end the Persian Gulf War and would be willing to meet President Saddam Hussein and even deal with Washington if Baghdad's response proved positive.

Warning that "any exclusion of Iran from negotiations would mean genuine security could not be achieved" in the gulf, Rafsanjani spoke cautiously about ideas he said he conveyed last week to visiting Iraqi Deputy Prime Minister Saddoun Hammadi for Saddam's consideration.

Rafsanjani said he would not spell out details for fear of compromising his initiative and said "no specific plan" existed at this stage. He cautioned that he had found "no flexibility whatsoever" in Iraq's positions during Hammadi's three-day visit here.

The Soviet Union praised Rafsanjani's offer and a Foreign Ministry spokesman said Deputy Foreign Minister Alexander Belonogov will go to Tehran on Tuesday to discuss the war, the Associated Press reported. U.N. Secretary General Javier Perez de Cuellar said he welcomed Iran's initiative.

Rafsanjani's move came after a week of visits to Tehran by top officials of several countries, including France, Kuwait, Algeria, Pakistan, Yemen and India, and the release a week ago by the United States and the Soviet Union of a joint statement outlining ways for Iraq to move toward a resolution of the war. Also last week, Saudi King Fahd and Egyptian President Hosni Mubarak met and raised the possibility of an immediate cease-fire if Saddam withdrew his forces from Kuwait.

The Iranian leader appeared relaxed and confident throughout a 2 1/2-hour news conference today, and betrayed no inkling of irony in potentially associating Iran's two archenemies, Iraq and the United States, in a peace initiative.

Rafsanjani's main thrust was to reiterate Iran's determination to "remain neutral" -- in the conflict, but "not to the consequences of the war," as he described postwar regional security arrangements.

Rafsanjani also left open the possibility that Iran might hold the vast majority of the Iraqi warplanes impounded here -- which the United States has said total about 90 -- as reparations for damages incurred during the 1980-88 war between Iran and Iraq.

He acknowledged the presence of only "around 14" Iraqi aircraft, however, and said they and their crews will remain interned in accordance with "international regulations" until the end of the war.

Recalling that 300 aircraft sought asylum in Switzerland during World War II, Rafsanjani said it was the "principle" and "not the numbers" that was important.

The "majority" of Iraqi pilots in Iran were not defectors, he said, but flew here "to preserve their aircraft," in acts beyond Iran's "control, will or choice."

"The first days we wanted to stop them," he said, "but we could not convince them to return to Iraq." Some warplanes arrived over Iran with so little fuel that they would have crashed if they remained airborne for "five more minutes," he said, adding that three made crash landings and the pilot of one was killed.

While disputing his figures on the planes that have reached Iran, diplomats said Rafsanjani's version of their arrival tallied with their impressions. They noted that Iran had flatly rejected Hammadi's request that the impounded warplanes be released for use against Israel.

At first glance, Rafsanjani's determination to stake out a major postwar regional role appears complicated by Iran's relative diplomatic isolation inherited from the Islamic Revolution that overthrew the monarchy here in 1979 and from its own war with Iraq.

With no diplomatic ties with Washington since 1979 and poor diplomatic relations with Britain and key Arab states arrayed against Iraq, Iran is viewed with suspicion by Saudi Arabia and its smaller Arab allies in the Gulf Cooperation Council.

Diplomats said these weak, oil-rich states have not forgotten Tehran's pressures on them during the Iran-Iraq war and remain suspicious now that the allied coalition is reducing Baghdad's military deterrent against a resurgent Iran.

But at the same time, Tehran's hostility toward both Baghdad and Washington, symbolized in Iran's joint demands for Iraq to end its occupation of Kuwait and for foreign forces to leave the region, created what diplomats here described as a kind of negative even-handedness that could make Iran a possible channel of serious communication.

"If Saddam Hussein went to King Kong and said, 'I want to withdraw and can you fix it,' " a Western diplomat said, "everyone would applaud. The world wants a result."

In reply to a question, Rafsanjani justified a meeting with the Iraqi leader, saying, "If there was any hope that it would save the Iraqi people and the people of the region suffering, why shouldn't I do this?"

His reply apparently was aimed at militant Iranian fundamentalists who have called for an anti-Western jihad, or holy war, to defend the fellow Muslims of Iraq.

If Iraq accepted Iran's ideas, Ranfanjani said, "there would be so much pressure on the United States" that it would be forced to accept such a solution, although "it is going beyond the aims of the United Nations" in its current bombing campaign against Iraq.

In a country where the United States is still called "the great Satan" and is blamed for siding with Baghdad during Iran's war with Iraq, Rafsanjani spoke openly of recent dealings with the Swiss Embassy, which represents American interests here.

Since Baghdad has not replied to Iran's ideas, no decision to talk to the United States on this score has yet been made, he said, but such an approach would seem "logical" if required.

Diplomats here said they did not think Rafsanjani's willingness to talk to Washington about the war should be interpreted as a gesture of reconciliation toward the United States, which they said remains very much "the great Satan" in Iranian eyes.

Defending Iran's neutrality in the war, he said no decision has yet been made about what its stance would be if Israel launched massive raids against Iraq in retaliation for continued Scud missile attacks on its territory. Several times he expressed disapproval of Iraq, and he denied reports from Baghdad that allied aircraft had entered Iran's air space or crashed in Iran. He also complained that a recent Iraqi map showing both Kuwait and the Shatt al Arab waterway between Iran and Iraq as Iraqi territory "weakened our confidence" in Baghdad.

Nonetheless, he said Iran was pledged to send Iraq medicine, which is not subject to the U.N. embargo, and had consulted the U.N. committee controlling food shipments about what foodstuffs could be dispatched there.

He reiterated Iran's refusal to allow the regional map to be redrawn and said that "after the war there should be no adventurous acts." This suggested condemnation both of Iraq's invasion of Kuwait and of possible Turkish designs on Iraqi Kurdistan if central authority broke down in Baghdad.

But despite Iran's longstanding denunciation of NATO, Rafsanjani indicated he understood NATO member Turkey's reasons for allowing its bases to be used by American aircraft to bomb Iraq.