The Philippines' first election in six years and its aftermath have proved, despite continual claims to the contrary, that martial law restraints on democracy in the former U.S. colony will last as long as President Ferdinand Marcos does, and perhaps longer.

The election, advertised as part of Marcos' plan to return to normal, free spirited Philippine politics, was carefully stacked in the president's favor long before votes were cast April 7. The subsequent vote fraud charges and mass arrests this week only reaffirmed the 60-year-old leader's determination not to repeat the mistakes of former Indian prime minister Indira Gandhi and submit his one-man rule to a real electoral contest.

There remains a slim chance that the Philippines army may someday become disenchanted enough with Marco's dizzying playing of one social group against another to unseat him. But Philippines generals are as unlikely as Marcos to return to the unrestrained political combat that characterized what was probably Asia's most democratis country before martial law was imposed in 1972. Marcos shows no sign of losing his touch at keeping the stability minded army and police commanders happy.

The prospect of martial law, continuing into the indefinite in fact if not in name, future poses serious problems for U.S. relations with a nation of strategic, economic and sentimental importance to Americans. Congressmen who must someday consider a new military bases agreement with Marcos have been outspoken in their criticism of martial law.

Anti-Marcos political exiles in the United States have been very active in wipping up opposition to martial law by playing both on the fact that more than 300,000 Filipinos now live in the United States and on historical fondness for what had once seemed to be a successful transplant of American-style democracy in Asia.

After 5 1/2 years of repeated assurances from Marcos that he plans to lift martial law, he seems no more emotionally capable of the act than he ever did. He is a brilliant lawyer who becomes impatient when anyone else tries to legislate.

"You can see him fidgeting when he's presiding over meetings where other people are making suggestions, talking on an on," said a veteran diplomat here.

The election, rather than being a step toward democracy and a concession toward the island nation's most powerful ally, the United States, became a lesson in Marcos' continued discomfort with any kind of dissent and his ability to keep all potential rivals for power at bay.

At a press conference this week with foreign journalists, Marcos argued the importance of the election of a new National Assembly in removing a "legal obstacle" to the eventual lifting of martial law and the surrender of his legislative power to an independent assembly. Yet, the day before the press conference he had issued Presidential Decree No. 1348, guaranteeing that none of the anti-Marcos candidates could take a seat in the new assembly if any of the elderly pro-Marcos victors suddenly died.

The assembly election was so carefully arranged in advance in Marcos' favor that it was suprising how relatively free of abuse the actual voting was and how high the opposition scored - about 40 percent in Manila in the figures released by Marcos' vote counters.

Most importantly, unlike Gandhi in India, Marcos himself was not a candidate. His position as both president and prime minister in the new 200-member assembly had been assured in a national referendum in December.

The leader of the opposition in Manila, political prisoner and former senator Benigno Aquino, was not allowed to campaign, except for one television performance that was so electrifying that it was not repeated. The newspapers and television networks refused to take opposition advertisements. The anti-Marcos group had only enough time and money to campaign in Manila, and there Marcos profited from his power to reward neighborhood leaders with organizing funds and govenment employees with new pension benefits.

He approved a voting system that required any Marcos sympathizers who might also want to vote for Aquino out of sympathy to write Aquino's name on the ballot, thus denying the opposition leader many cross-over votes that might have given him a chance of winning.

Then, on election eve, the opposition announced a "noise barrage." It allowed thousands of Manila residents the easy opportunity of registering their displeasure with the harsher aspects of martial law by simply banging a pot or honking a horn. There was a considerable din, some dented automobiles, and Marcos, the political fine tuner, decided to turn down the volume of dissent.

He canceled an order restraining police from making arrests during the campaign. Within hours, about 50 demonstrators had been rounded up. When the opposition held far more peaceful march two days after the vote, to protest what they charged was a rigged election and widespread vote fraud, police arrested nearly 600 people, the first such mass arrest in months.

Marcos soon saw what a bad press the arrests were giving him abroad, and twisted the dial back a bit. He released most of the marchers and held a press conference for the foreign journalists he had been damning privately for what he called one-sided reporting.

It was a virtuoso demonstration of the Marcos style of government. He still kept the police on alert for further trouble, kept eight important opposition march leaders in jail and thus unable to help organize more protests, and obliged the foreign press to report his words undistracted by the oppositon outcrys they had been hearing earlier in the week.

From the first day of martial law, when Marcos assumed one-man rule but noted that he was acting under a constitution that allowed such emergency powers, he has proved to be a master tightrope artist. A Moslem rebellion weighed him down in the south, but allowed him to justify his continuation of martial law in the north.

He has used the nationalist arguments against foreign economic exploitation advanced by his leftist enemies to support a program of increased Philippine control of key industries. This has benefited many of his business friends and has increased his personal control of the economy. He has kept the military from cracking down too hard on dissidents by pointing to all the military aid coming from a U.S. Congress sensitive to human rights.

The Filipinos call it "magis," a euphemism for the right mix of muscle, public relations and corruption that keeps Marcos in power. Conversations with more than a hundred voters from every sector of society these past two weeks indicate that most prefer the last five years to the high crime and inflation of the final days before martial law, although they would like to see Aquino free and more dissenting views heard. Filipinos wonder if any successor could match Marcos' skills in maintaining the system. But most expect that anyone who might succeed him, even Aquino, would try in some ways to follow his lead. As businessman said: "We're never going back to 1972."