With the prime minister's office applying pressure, Japan's public corporations are agreeing to increase substantially their offer to solve a long and sharply contested trade dispute with the United States.

The new offer emerged after a top aide to Prime Minister Masayoshi Ohira virtually ordered Nippon Telephone and Telegraph, a public corporation, to open it's procurement policy to bids by foreign suppliers in a new effort to trim Japan's trade surplus.

In a traditional Japanese response, the corporation's president, Tokuji Akikusa, promptly offered his resignation as a gesture of accepting responsibility for the trouble he has caused the government with his adamant opposition in recent weeks.

The United States and the European Economic Community have insisted that Japan increase its imports and lower its trade surplus by letting companies sell machinery and equipment to its large public corporations that usually follow a "Buy Japan" policy.

The exact terms of the offer were not disclosed in full, but government sources indicated it would probably open up about $7 billion worth of Japanese government purchases to foreign bids, including some of NTT's main-line equipment, which had been the central issue.

However, some of the more sophisticated telecommunications equipment reportedly was exempted from the offer, raising the possibility that it might be rejected by the U.S. special trade representative, Robert Strauss. A high-ranking Foreign Ministry official flew with the offer to Washington Friday night for meetings with Strauss this week.

Strauss rejected a previous Japanese offer on March 29, calling it "wholly inadequate" and abruptly broke off negotiations.

The government procurement issue had been the most hotly contested trade dispute this year and had become entangled in the government's current effort to smooth out ruffled diplomatic relations with Washington.

The Japanese want the issue settled before Ohira makes a state visit to the United States early in May and before the economic summit conference is held in Tokyo in June, thus giving American negotiators extra leverage in extractin concessions.

Besides the money involved, which is considerable, U.S. officials said they regarded the issue as important symbolically as a test of the Japanese government's willingness to pressure domestic corporations to eliminate trade barriers. They contend that if the government is not willing to influence public corporations such as NTT to drop their barriers against foreign sales, it could not be expected to do much about purely private companies that do not buy abroad.

The government was internally divided, with some officials maintaining that American demands were unfair and an interference in Japan's domestic affairs. But it ultimately agreed to seek a better offer to smooth Ohira's path to Washington.

At the center was NTT, the giant telecommunications corporation that buys almost all of its equipment from domestic firms in private contracts. Only 4 percent of its purchases are through competitive bidding and less than 1 percent of them are made from foreign countries. It buys about $3 billion worth of equipment annually, about half of it from four large Japanese firms.

NTT, which enjoys considerable bureaucratic independence, resented the government's interference an insisted that foreign equipment would be incompatible with its standardized communications systems.

NTT asserted that permitting international bidding would drastically complicate its relations with domestics suppliers, which are tuned to build only what @ntt wants. It also claims it would force the company to release technological secrets developed by suppliers to foreign competitors. Foreign equipment would create problems of operations and maintenance, NTT argued.

Threatened with foreign competition, NTT's suppliers have mounted an intense public relations campaign with newspaper ads headlined, "The Japanese Telephone System Is Now in Danger." The ads contend that imported equipment would lower the efficiency of the Japanese phone system and that its high quality of service would be impaired. The collapse of Japan's communications system, assert the advertisements, is too great a sacrifice for the cause of better trade relations.

Japan's previous offer to open up $5 billion of government procurement to foreign bidders was met by the American insistence on $7.5 billion. In addition, the United States insisted that NTT's mainline communications equipment, including switchboards and other sophisticated gear, be included in the offer. It said the earlier offer included too many low-quality items such as mops, cleaning rags and concrete telephone poles, which no foreign bidder could offer competitive prices on.

It is not precisely clear what the latest Japanese offer embraces. According to one account substantially confirmed by a government official Saturday, it would open up a total of $7 billion of governmetn procurement to foreign bidders of which between $1.8 billion and $2.5 billion would b e purchased by NTT. The Japanese National Railways and other government corporations are included.

According to the Asahi newspaper, however, the offer exempts from foreign bids NTT's computer-connected switchboards and all lines except cables.

The latest offer was pieced together after direct intervention from Ohira's chief Cabinet secretary, who met Friday morning with Akikusa and urged him to permit international bidding on the mainline equipment. It was regarded as a virtual command from the prime minister.

Akikusa bowed to the pressure and Saturday announced he was submitting his resignation. That often is a symbolic gesture as a way of accepting responsibility in Japan, but Akikusa's aides said he intended to go through with the resignation.