Sen. Mike Gravel (D-Alaska), a maverick who often set congressional teeth on edge with his flamboyant tactics and abrasive manner, has become the first senatorial casualty of the 1980 elections.

With most of the votes counted from Alaska's primary election on Tuesday, the 50-year-old Gravel was handily defeated in his bid for a third term by Clark Gruening -- providing an ironic finale to a bitter volatile campaign.

Gruening is the 34-year-old grandson of the man Gravel unseated in winning his first Senate term 12 years ago, the late Ernest Gruening (D), one of the founding fathers of the 49th state.

Gruening will face Fairbanks banker Frank Murkowski, who ran away with the Republican nomination, in the Nov. 4 general election. Without an incumbent in the race, a close contest is expected.

Gravel's defeat came as Sen. Herman E. Talmadge (D-Ga.), another incumbent with deep political troubles this year, survived the toughest fight of his career Tuesday in defeating Lt. Gov. Zell Miller in Georgia's Democratic primary runoff.

In the Oklahoma race to succeed retiring Sen. Henry Bellmon (R), it will take a Sept. 16 runoff in both parties to determine the contenders for November.

For the Democrats, the choice will be between oilman Robert S. Kerr Jr., son of the late Sen. Robert Kerr, and Andy Coats, a former prosecutor from Oklahoma City, who ran close behind in nearly complete returns from Tuesday's voting.

Republicans will choose between industrial John Zink and state Sen. Don Nickles, who also ran almost neck-and-neck.

From the start of this election campaign, Gravel was marked by GOP strategists as the most vulnerable Senate Democrat, although they conceded he might be as susceptible to a Democratic coup as a Republican one.

A key question had been how Gravel's no-compromise opposition to the huge Alaska lands bill, which dominated the Senate during much of the final weeks of the campaign, would play in Alaska, where the legislation was viewed as a scurrilous Washington land grab.

In a sense, it was vintage Gravel: "Fighting for Alaska," as his campaign slogan put it, against the Potomac power cliques. But it might well be that, in the end, Gravel hurt himself by being unable to kill the lands bill.

Even Gravel's own people conceded that the Senate's vote this month to break his filibuster against the bill, followed by Senate passage of the measure, contributed to a plummeting of the senator's poll ranking just before the primary.

Before the vote, Gravel's standing had been improving in some polls, including Republican ones, and some of his critics were saying that his "grandstanding," as they called it, would pay off.

Gravel's failure played right into Gruening's campaign theme that he was shortchanging Alaska by his ineffectiveness and confrontational politics, just before facing the voters six years ago Gravel brought home the trans-Alaska pipeline, for which he had fought.

In his political career, Gravel has been a maverick, a loner, at times a hair-shirt -- an unclubby fellow in a rather clubby place. He is hardly on speaking terms with his Alaska colleague, Sen. Ted Stevens (R), and has fared barely better with some important people in his own party, such as Sen. Henry M. Jackson (D-Wash.)

Born to modest circumstances in Massachusetts, Gravel moved to Alaska as a young man, striking it rich as a real estate developer and, like the younger Gruening several years later, moving into statewide politics by way of the state legislature. His political personality projects a mixture of Eastern urbanity and frontier-style defiance.

Perhaps his most flamboyant act came in 1972, three years after he entered the Senate, when he called a midnight meeting of his Public Works subcommittee on buildings and grounds to read from the Pentagon Papers, a secret account of the Vietnam war. Gravel, a critic of the war, read until he broke down in tears.

Over the years, he has earned a reputation as one of the Senate's heavier hands in campaign fund-raising, shaking the Washington money tree for all it's worth, according to critics.

By contrast, Gruening pledged not to take contributions from special-interest groups. When Gravel tried to turn the tables by saying that support for Gruening's campaign by some Jews amounted to "special-interest" support, Gruening cried foul and the tactic appeared to backfire on Gravel.

When it became clear Tuesday night that he was losing, Gravel refused to say whether he will support Gruening in the November election.

Gravel blamed his defeat in part on Republican crossover votes, which are a regular practice in Alaska's open primary, in which all candidates run on the same ballot and the top vote-getters from each party win their retrospective nominations.

Gruening had appealed openly in the campaign for Republican support, but his victory margin -- 33,694 votes to 26,783 with 387 of 421 precincts reporting -- indicated that Republican crossovers alone were not responsible for Gravel's defeat.

Gravel also blamed what he called negative advertising against him by an independent group called Friends of Alaska.

Gravel's departure from the Senate at the end of this session will mean the third chairman in less than 12 months for the Senate's environmental pollution subcommittee. Gravel succeeded Edmund S. Muskie as chairman of the panel when Muskie became secretary of state. Who succeeds Gravel may depend on election contests this fall.

No other Senate incumbents appear seriously threatened for renomination, but a half dozen or more Democrats, along with several Republicans, face tough challenges in November. Three House members, all Democrats, have been defeated for renomination so far.

On the Alaska ballot, voters divided almost evenly on a referendum measure to create a commission to reexamine statehood, with the outcome expected to a hinge on absentee ballots to be counted later.