Undated (AP) _ Wall Street's best known indicator took its fourth-largest dive ever on Friday in a busy stock market session whipsawed by so-called program trading.

The Dow Jones average of 30 industrials slid 35.68 points to 1,768.56, for its largest loss since Jan. 8, when it tumbled a record 39.10. For the week, the average lost 24.18 points.

But, beyond the blue chips, other stocks fared better. About 10 stocks rose in price for every seven that declined among all issues listed on the New York Stock Exchange.

Analysts attributed the market's heavy trading volume and volatility to professional traders closing out multiple positions in expiring options and futures on stock indexes.

At a meeting in Geneva, Switzerland, the Organization of Petroleum Exporting Countries failed Friday to win commitments from five independent oil-producing nations to reduce output. But the cartel said the five had agreed to support an effort to push oil prices up to $28 a barrel.

Without major reductions in world oil supplies, prices would be expected to remain near levels of about $15 a barrel, analysts have said.

Meanwhile, in Washington, Federal Reserve Board Vice Chairman Preston Martin hastily called a press conference and announced he has handed in his resignation.

His decision to leave next month rather than seek a second four-year term as vice chairman followed revelations about dissent among the seven governors of the nation's central bank, which stirred doubts about Fed Chairman Paul Volcker's effectiveness in steering monetary policy.

Martin, 61, had been generally viewed as a possible successor to Fed Chairman Paul Volcker when Volcker's term as chairman expires in August, 1987.

In a letter to President Reagan, Martin said: ''For the last hundred days I have agonized over whether to serve four more years as vice chairman of the Federal Reserve System.''

However, Martin told the president that ''in the end, any decision is a very personal one based upon the individual's goals and objectives.''

On the fiscal front, the Treasury said the federal budget deficit swelled to $24.58 billion last month from January's $6.49 billion shortfall.

The nearly four-fold increase in February carried the deficit for the first five months of the 1986 fiscal year about 5.7 percent past the point it had reached in the same 1985 period.

Despite the expanding pool of red ink, the Reagan administration predicts the deficit for the full year will be $202.79 billion, or 4.5 percent smaller than the record $212.3 billion shortfall in the year that ended last Sept. 30.

The administration's estimate is based partly on $11.7 billion in budget cuts that went into effect on March 1. Those cuts were required under the Gramm-Rudman deficit-reduction law and were allowed to go into effect even though the Supreme Court is reviewing whether a crucial section of the law is constitutional.

The Gramm-Rudman act, passed by Congress last year, requires that deficits be trimmed annually until the budget is in balance in 1991.

The dollar continued falling against major foreign currencies in quiet trading, and the price of gold rose sharply.