Tens of thousands of people poured through the streets of this capital's dilapidated downtown recently in a "march of empty pots." Drumming with wooden spoons as they passed the presidential palace, they suddenly began shouting for the resignation of civilian President Aristides Royo.

It was a cry for change that the country's military leaders are rushing to answer, most likely at Royo's expense.

Royo was appointed to a six-year term as president when Gen. Omar Torrijos Herrera stepped down as chief of state. Torrijos remained the most powerful man in Panama, however, and Royo served in his shadow until the general's death in a plane crash last July 31.

The surprisingly large and vehement demonstration against Royo follows 14 years of gradually loosening dictatorship, and it has provoked talk here about the unpredictability of the Panamanian people.

"Panama is not like other countries where you organize bit by bit and where revolutions build gradually," said Miguel Antonio Bernal, a radical leftist organizer of the march. "Its history is of sudden explosions. One day the people are swigging beer, dancing, fooling around. The next day: boom."

Such apocalyptic predictions could easily be exaggerations in this culture of impassioned rhetoric. But the frustrations that surfaced in the march sent tremors through the delicately balanced government of military men and civilian appointees like Royo who were unexpectedly left in charge of Panama when Torrijos' airplane crashed into a mountainside.

With the country's economy in tatters, its external debt an astronomical $3 billion and, at a time of recession, little profit coming from economic ties to the United States so close that the only paper currency in circulation is the U.S. dollar, there is plenty of room for discontent.

"One breathes it in the air," said Brig. Gen. Ruben Dario Paredes, now holding Torrijos' post as National Guard commander in chief. "The people want change."

In an extended interview the morning after the march, Paredes talked of revising Torrijos' constitution, pushing up the date of presidential elections from August 1984, thus considerably abbreviating Royo's planned six-year term.

"Twenty-four more months," said Paredes. "It's a bit long, isn't it?"

Paredes denied reports that he and other leaders of the National Guard had urged Torrijos to replace Royo, and that they tried to oust the president earlier this year.

Royo, who took office in 1978 and is legally prohibited from seeking a second term, "has always had a difficult role," said Paredes.

Royo's basic backer was Torrijos, and Torrijos "never considered the negative effect on Royo , the debilitation of not having the vote behind him, and of having most of the cries of protest and insults fall on him," according to Paredes.

"The people saw [Torrijos] as the logical next president," in Paredes' opinion.

"When a man with such power disappears suddenly, violently, it is like a blackout in the night. There is darkness, trembling, confusion," said Paredes, adding that while the Panamanian people seem to have resumed "a day-to-day normality," they are, "as if with a flashlight in a dark tunnel, searching to see who will be the next man."

"I feel the people want to go to the ballot boxes quickly," he concluded. "If this could be done without disruption of the public order, without our losing peace, without impeding economic progress, then we should . . . go to the polls more quickly."

Paredes, 48, seems to be trying to present himself as the embodiment of change and unity despite the fact that he heads the institution that has totally dominated political life here since 1968.

While many would like to see Royo's term cut short, opposition leaders fear the main purpose of such a move is to usher in a Paredes presidency before they can organize sufficiently to field a strong ticket and a competitive candidate.

"Paredes is due to retire," said one opposition leader, "but when he talks about moving up the presidential elections he may mean he's not going to retire at all."

The Revolutionary Democratic Party, set up by Torrijos as the government party, made a disappointing showing in partial legislative elections two years ago with less than 50 percent of the vote against disorganized opposition.

Since then, the seven major oposition parties have worked together with regular meetings and dinners such as one that filled a banquet hall recently with more than 1,000 opposition activists.

Ranging from the backers of 80-year-old veteran politician Arnulfo Arias to business interests to progressive and leftist factions, the opposition parties have yet to make clear what a coalition would offer. But they do appear certain that they don't want to keep the National Guard or its leaders in command of the country's political life.

Paredes, said Guillermo Cochez, secretary general of the Christian Democratic Party, "wants to be the candidate of unity, and that's going to be impossible."

Moreover, as one opposition leader suggested, speaking off the record because he is still reluctant to face a head-on confrontation with the powers behind the scenes at the Guard, "The problem with Paredes is what comes after Paredes."

It is generally assumed that Col. Manuel Antonio Noriega, the enigmatic chief of military intelligence, will ascend to the open command of the Guard when Paredes leaves, and "no one knows what side he is on," said the opposition leader.

Yet if the domestic constituency of the Guard's political leadership remains unclear, Paredes and Noriega appear to be moving steadily to shore up their backing in Washington not only through their emphasis on at least the formalities of electoral process, but in their attitude toward the regional crisis.

Panama's longstanding attempt to cultivate an image of neutrality under Torrijos appears to be ending.

"The moment of great definitions is arriving. We had wanted to be free, a friend of the whole world, as long as nobody bothered us," Paredes said. "But unfortunately the world today turns around two poles: traditional democracy and an open economy led by the United States, and the communist world led by the Soviet Union, with a system we never want to see in our country.

"We are not enemies of Russia, but we don't want them ever to fool with us here. We respect the Cuban form of government and if they think it's best for them, that's their problem and their right. But that's not what we want for Panama."