During the recent hostage crisis in Beirut, both President Reagan and Vice President George Bush rejected chances to note similarities with the 1979-81 hostage crisis in Iran. No doubt it would be difficult to take back critical comments they made about President Carter in the heat of the 1980 presidential campaign. But neither man has showed that he has gained any appreciation of Carter's ordeal.

This politicians' response is in sharp contrast to Carter's appeal during the recent crisis for all Americans to support the president. What Reagan and Bush said was not just lacking in grace; it was also not smart. In relying on a popular view that Carter could do no right and Reagan no wrong, the president and vice president missed a chance to start building a supportable policy againstterrorism.

The steps now required will need the backing of Democrats as well as Republicans. By declining at his June 18 press conference to utter a simple "I guess I learned something," Reagan missed a chance to enlist in his cause those Democrats who have believed that as a candidate in 1980, he sold both his president and his country short.

In fact the similarities between the two hostage crises outweigh the differences to the point that what Reagan cites as a crucial difference -- that Carter had "a government on the other side" -- is almost trivial.

In both cases, Americans were the targets. We are known to care about our people. We are as influenced by television as any other nation. And we are omnipresent in the Middle East. We are the wealthy Western superpower in the region, held responsible for events beyond our doing and looked to -- even by some of our enemies -- to work political miracles beyond our abilities.

In each case, as well, the U.S. military machine was effectively neutralized, although Carter -- who, unlike Reagan, had to beware of provoking a Soviet military reaction -- did try a rescue when the hostages' lives seemed in jeopardy. In each case, patience was necessary to save the lives of hostages and innocent civilians. In each, the American people became deeply frustrated and wanted prompt action.

In Iran, the Ayatollah Ruhollah Khomeini seized on the events at the U.S. Embassy for his own political ends. He used our diplomats as pawns in his effort to consolidate his revolution. Only when that was done -- with icing on the cake as Carter was deposed at the polls -- did he let our people go.

In Lebanon, a relatively straightforward, though tragic, case of hijacking and murder also became a struggle for political advantage. Nabih Berri, leader of the Amal, spent two weeks trying to protect and then to advance his position against the more radical Hezbollah.

Here lies a key difference between the two hostage crises. In Iran, there proved to be nothing Carter could do diplomatically to secure the hostages' release until the ayatollah had worked his will. By contrast, from the beginning Reagan had a card to play: acceding to the release of 766 Shiite prisoners in Israel. Despite all the efforts to convey the opposite impression, this is exactly what the Reagan administration has done. (The White House may believe that there was no "linkage"; no potential terrorist will be impressed.)

Perhaps in a similar situation Carter would have done the same. In fact, he did not. Under the circumstances Reagan was probably right to do what he did, but his decisions reflected the same sort of prudent thinking on the part of a president that he had condemned in 1980, when it was practiced by Carter.

Carter's diplomacy, while taking 444 days, also brought home all the hostages, including two nondiplomats who had been seized separately. By contrast, Reagan accepted an end to the crisis with seven Americans left behind -- presumably as insurance against American military retaliation. To be sure, Carter directed that any hostage, given a chance to be free, should take it. Some were released early. But when the 52 hostages came home in January 1981, no one was left behind.

Two presidents have faced deeply frustrating crises of a surprisingly similar quality. Each has acquitted himself to the best of his ability. Hostages have come home. But viewed in terms of the opprobrium that Jimmy Carter endured, his stewardship now comes into new focus; his efforts to preserve both national interest and honor are more clearly apparent.

With Ronald Reagan's own ordeal now over, he can correct the record. It would require an act of statesmanship, but on other occasions he has been equal to the task. In the process, he can earn the respect and support of political leaders across the aisle. As Americans, we can then begin to fashion a national bipartisan policy to deal with a common threat.

The writer served on the National Security Council staff during the Carter administration.