Gov. Louis Munoz Marin, the fiery populist who created a modern, industrial Puerto Rico out of the island's sugar plantation feudalism, died yesterday in San Juan after a series of heart attacks. He was 82.

He had suffered three hearts attacks since a stroke led to his hospitalization last Saturday.

Born into politics and never really out of it, Gov. Munoz made his final public appearance March 16, stumping in the island's presidential primary for Sen. Edward M. Kennedy (D-Mass.)

In his lifetime, he oversaw the writing of a constitution and the transformation of an entire people and served four terms as their governor, from 1948 to 1964. His motto was: "We must live like the angels and work like the devil."

At the end he was still working like the devil against the idea of statehood for his beloved island, convinced that to ask for it would only mean rejection by the U.S. Congress and vast humiliation for Puerto Rico.

Although an earlier stroke had slowed and thickened the oratory that stirred his people for 30 years, Gov. Munoz's stooped figure aroused patriotism and high emotion wherever he went, the kind of emotion reserved for truly historical figures in their own time.

President Carter issued a statement yesterday expressing "deep sorrow" at the death of Gov. Munoz, whom he called "a great man . . . [who] marched in the first rank of 20th century leaders."

There were those who said he was old-fashioned, he agreed in a 1978 interview at his tropical hillside retreat, but they were mainly the young intellectuals. "Ask the jibaros in the countryside what they say," he admonished, referring to the poor mountain people who were his political base.

"They will talk to you also in the terms of principles: equality, sovereignty and common betterment . . . not in terms of money."

Weary then of the eternal squabbling among his successors in the Popular Democratic Party that he founded, Gov. Munoz said then he had come out of retirement only to talk of principle and not of Puerto Rico's economic problems.

"Americans are not stingy with money, but they are stingy with power," he said.

He spoke from experience. It was Gov. Munoz who cajoled, argued, charmed and forced bits and pieces of power away from the U.S. government to construct over the years the unique, oddly built and, for a while, wildly successful patchwork government he called a "free associated state."

"Commonwealth is a tailor-made suit," explained on of Gov. Munoz's backers once. "If you've got a funny looking body, you're going to have a funny-looking suit."

On Feb. 18 1898, three days after the USS Maine exploded in Havana Harbor, Luis Munoz Marin was born into Puerto Rico's first family. His father, Luis Munoz Rivero, was then chief of government under the Spanish king.

The U.S. Marines "liberated" Puerto Rico almost as an afterthought in 1898 at the end of the Spanish-American War, and Monoz Rivero smoothed the transition to American rule. His son grew up pampered, and eventually studied law at Georgetown University in Washington while his father was resident commissioner here.

But when his father died, Gov. Munoz left school and moved to New York where he lived briefly in Greenwich Village, writing poetry and contributing to political magazines. His marriage then to another poet, Muna Lee, ended in divorce in 1940.

From this part of his life, Gov. Munoz took the nickname, "The Bard," and he liked to be identified as a poet-leader. He was an enthusiastic Marxist then, favoring independence for Puerto Rico's impoverished people. But he joined his father's Liberal Party in 1926, and learned, he said later, that independence just wouldn't work at that time.

"My principal interest was not in political status but in the economic status of the poor," he said in 1978, "and we had nothing, nothing -- no resources, only ourselves."

The steamy, rocky island, bereft of minerals or any other visible means of support, was run then by the giant sugar plantations that paid off politicians who bought the votes of the mountain jibaros with $2 and free rum.

Editing and publishing a magazine, La Democracia, Gov. Munoz set himself against the landowners and was elected to the Puerto Rican Senate in 1932. He worked to get some of President Franklin Delano Roosevelt's New Deal money for Puerto Rico, and in 1938 formed his own party, the Popular Democratic Party.

He talked the jibaros' language. "Why has no one done anything for you?" he shouted at meeting after meeting. "It is because you have sold your votes to them all."

A pensioner, reminiscing as he waited for Gov. Munoz to speak in 1978, recalled those days. "I was just a little boy but I remember 50 or 60 men, standing here with machetes, waiting for one of the landowners to allow them to come and cut the sugar. We were slaves then . . . we were freed by Munoz Marin."

Elected president of the island Senate in 1940, his party in control of the legislature, Gov. Munoz began his drive to change the island's status. He launched "Operation Bootstrap" to bring in industry, improve agriculture and education and extend electricity to the countryside.

In this he had enthusiastic help from Rexford Tugwell, an FDR brain truster and the appointed governor of Puerto Rico. In his book, "The Art of Politics," Tugwell wrote that Gov. Munoz was the equal of FDR and New York Mayor Fiorello LaGuardia as a master politician.

"He was the kind of person who never really believed that others' motives were self-interested and so inimical to the public good," Tugwell wrote. "He always found excuses even for those who betrayed him."

When Congress agreed to allow Puerto Rico to elect its own governor in 1948, Munoz Marin won overwhelmingly on a platform of a new relationship with the United States. He constructed a constitution that gave the 2.2 million islanders U.S. citizenship and financial aid, the U.S. mails and U.S. currency. But Puerto Ricans sing their own anthem before their own flag and pay no U.S. taxes, for they do not vote in U.S. elections, although they do hold presidential primary elections.

They have no voice in foreign policy or national defense (although Puerto Ricans serve in the U.S. armed forces), except through a nonvoting representative in Congress, but there is fiscal and political autonomy at home. The press is free; Gov. Munoz vetoed a bill to regulate it that passed both houses of the island legislature in 1949.

This new creation passed Congress and was approved in a popular vote in Puerto Rico, and the commonwealth was officially born July 25, 1952.

For a time it worked brilliantly. Granted a 10-year tax exemption, industries flocked to the island tuna processing, pharamaceutical production, oil refining. There were 50 in the first year and 2,000 by the mid-1970s.

The commonwealth took over the production and distribution of electricity and some of the land transport. It built the Caribe Hilton Hotel for $7.2 million in 1952, getting the entire investment back and then some in 10 years. There were new airlines, hotels, airports, roads and ports, public housing and a movement toward a minimum wage.

Concerned that his victories were too one-sided, Gov. Munoz pushed through a constitutional requirement that at least one-third of each legislative house consist of opposition party members, regardless of the vote. He worried that his people were to materialistic, so he launched "Operation Serenity" in 1964 to promote spiritual and cultural values.

"If our Puerto Rico is be the Puerto Rico we love and respect," he said then, "it must not only hunger for goods but thirst for jusitice, the arts, science, understanding and human fellowship."

He survived a major battle with the island's Catholic Church, which issued a pastoral letter in 1960 forbidding Catholics to vote for him. It charged his encouragement of birth control and curtailment of religious education were part of an "undemocratic" political program. Gov. Munoz called it "medieval interference," and easily won a fourth term.

But much of the commonwealth's success depended on cheap oil to fuel industry, low wages to keep it coming in, and the steady emigration of the unemployed to New York.

The commonwealth ws already beginning to sour a bit when Gov. Munoz decided in 1964, at the age of 66, not to seek a fifth term as governor. He tried to retire to his hilltop Trujillo Alto to write his memoirs, but he kept having to return to public life -- first to campaign for the commonwealth idea in a 1967 plebiscite, which won, and then for his party in subsequent elections that it lost.

In 1957, he told Washington Post writer Chalmers Roberts: "When the PDP has carried out its pledges, the job will be done and it probably will be defeated."

Successive PDP governments were repeatedly rebuffed in efforts to win more autonomy within the commonwealth structure from Congress, and Gov. Munoz was alarmed at the growth of statehood sentiment.

"I am very pessimistic that my people, not knowing what it really means, will choose statehood by a few votes and be very wounded by the result," he said two years ago. He took to the stump for a final time to counsel against it.

Even so, pro-statehood Gov. Carlos Romero Barcelo yesterday announcing a seven-day mourning period for the island's grand old man.

Gov. Munoz leaves a son and a daughter from his first marriage and two daughters from his second marriage to Inez Maria Mendoza.

When Gov. Munoz announced his retirement in 1964 to protest delegates at the party national convention, he told them he wasn't really leaving. "You must continue to have confidence in yourselves. Only then will I know I have created a people of determination, with strength and with spirit . . .

"I am not your strength," he told them. "You are your own source of strength. Forward, forward . . . I am with you and I remain a part of you." s