By one of those unforeseen coincidences, Japan's Prime Minister Takeo Fukuda was here to talk with President Carter as the 38 Republican senators delivered a jeremiad lamenting the failures of the Carter foreign policy. Since Fukuda had come to Washington primarily to get assurances that the differences between the two countries could be, if not resolved, then simmered down, the Republican blast was hardly a happy omen.

For if foreign policy is to become a partisan issue exploited in the campaign this fall and then again in 1980, the hope of reducing foreign threats and frustrations to manageable proportions is dim indeed. That applies with particular force to the troubled relatioship between Tokyo and Washington.

At the outset it should be said that Japan has been a faithful ally. That dates from Gen. Douglas MacArthur's proconsulship immediately after the Japanese surrender. MacArthur showed a judicious balance of firmness and benevolence in steering the Japanese people toward a democratic form of government, sweeping into the dust heap the remains of feudalism.

In the following years the Japanese have tried earnestly to live up to the tenets of the initial agreement. They renounced nuclear weapons and, as he only country ever to be hit by an atomic bomb, they have been active in promoting nuclear nonproliferation. They have come to terms with Washington over the use of their large-scale peacetime nuclear reactor. for a highly industrialized nation without oil or coal, it was considered an essential element for future development.

Criticism in the United States has often centered on the fact that Japan gets by with spending so small a share of the national budget on defense. It has a free ride under the American defense umbrella.

But that is in record with the original stipulation that Japan's defense forces should be basically an internal-security service. Although with some prodding from Washington the concept has been enlarged, Japan's forces remain small. The reason, of course, is that her neighbours, having suffered under the expansionist drive of Co-Prosperity Sphere, are fearful of renewed militarism.

It is an advantage for Japan to be spending from 2 to 3 percent of her gross national product on defense while the United States spends somewhere between 7 and 9 percent. It takes little imagination, however, to realize how a sudden upsurge in Japanese military spending would send waves of alarm throughout the Pacific basin.

The bone in the throat is the trade surplus: $14 billion in current accounts worldwide for FY 1977, including $9 billion with the United States. That is a measure of Japan's need to export in order to import fuel and food for a country scarcely larger than the State of California and with far less arable land. It is a measure, too, of Japanese ingenuity and resoucefulness in industry.

The current dispute coming from powerful U.S. business interests is over the charge of "dumping" by Japanese steel and television firms among others, using concealed government subsidies to crack the American market. That shrewd trade negotiator Robert Strauss has managed to fend that off with so-called voluntary agreements in the most disputed areas.

How long that kind of compromise will work is the question. That is where the Republican lament over Carter ranks are strong protectionist advocates reflecting ties to the big-business interests pushing to stem the flow of Japanese goods.

Going protectionist - putting up the tariff barriers - would be a calamity for the world economy. For Japan it would be a disaster, and that disaster could have the gravest repercussions for the American position in the Pacific.

Fukuda gave assurances that Japan's $14-billion surplus worldwide in last fiscal year can be brought down to $6 billion in the new fiscal year. Reduction on the scale would take in lot of Japan's $9-billion surplus with the United States.

They are an amazing people. ON a visit to Japan several years ago, I visited a Sony plantwhere on the assembly lines they were working with the intensity that is singularly Japanese. On two lines the men and women wore red arm bands. Who are they? Oh, they're on strike, and when the strike ends they will get them the same increase in pay and perks as the others.

It is hardly our business to tell them not to work so hard. What they are being told is to relax a bit and let their people enjoy more of the good things of life, including expanded imports from the United States.

That means a greater effort on the part of Americans sales organizations and for the Japanese cutting the red tape that snarls the trade with Japan's biggest customer. In that respect the meeting with Fukuda was not just an exercis in the rhetoric of goodwill. It was a bid for a stable partnership between the two largest non-communist powers.