Sweden intensified its air and sea search today for a foreign submarine -- thought to be Soviet -- hiding in the coastal waters of the country's most sensitive naval installation.

Naval spokesmen said the vessel was spotted with sonar and radar equipment several times during the morning and more depth charges were dropped close enough for the craft to be damaged. But as of this evening, the exact whereabouts, condition and most importantly, the identity of the submarine remained a mystery.

Cmdr. Sven Carlsson said at a press conference that a submarine rescue ship capable of salvaging damaged vessels had been added to the surface ships, helicopters, submarines and divers conducting a round the clock search in an area about 12 miles long and about 2 1/2 miles wide that has been under way since Friday. Carlsson also said that Army units have been brought to the area to "prepare for any eventuality."

The Berga naval facility, on the Horsfjarden Bay about 25 miles south of Stockholm, has been transformed into a press center for the hundreds of reporters drawn to a spectacular hunt of the kind that in the past were conducted in great secrecy. But the discovery last October of a Soviet submarine, which ran aground at a naval base further south along the coast, alerted the public to the extent of Soviet spy activity.

As the number of submarine sightings has mounted sharply -- eight since June -- the Swedish military, backed by politicians of all parties, have decided that tougher and more public measures were necessary against the vessels. Last month new rules of engagement were announced that would permit repeated close-order use of depth charges against intruders.

While those new regulations were not to be implemented until next July, spokesmen made it clear today that they basically were being followed now. What sets this incident apart from others is the location, between the Navy's Musko base on an archipelago and the mainland. "This is so far inside a restricted area, so close to our main naval base that it seems more aggressive and ruthless than anything before," Cmdr. Hans Von Hofsten said.

So far, the Navy has dropped 2,750 pounds of explosives in the area in which the submarine is thought to be but has not attempted to score a direct hit. "The problem is we don't want to kill the submarine," Carlsson said.

The stated intention of the massive search is to force the vessel to surface, make a positive identification of its nationality and then order it away. Officials of the outgoing Swedish government have not ruled out extensive interrogation or even trials of key officers. But a final decision on how to deal with the craft once it is captured will be up to the new Socialist prime minister, Olof Palme, who takes office Friday.

While spokesmen still refuse to say categorically that a submarine is lurking in its military-controlled waters, there appears to be no doubt that some vessel is there -- even if it turns out to be only a small and possibly unmanned decoy.

[The Kremlin, in its first comment on the incident, said the submarine affair may be a hoax designed to disrupt Scandinavian-Soviet ties, Reuter reported from Moscow.]

Swedish newspapers have said the vessel was believed to belong to a Warsaw Pact nation, perhaps the Soviet Union or Poland. Of the nations operating submarines in the Baltic, the United States, West Germany and Denmark have said none of theirs is involved. Poland has made no declaration.

The vessel was first spotted just inside the archipelago where the Musko base is located by a Swedish naval motorboat, which reported seeing a periscope. The facility, which features a maze of tunnels and underwater hideaways, is considered vital to the security of Sweden in the event of a war.

In contrast to other recent sightings, a decision was made that this vessel would not be allowed to escape.

Monday, the search was escalated with increased and closer use of depth charges. To supplement these, according to unconfirmed reports, the Swedes are attempting to use an experimental weapon that magnetically attaches itself to the hull of the vessel, releasing a small quantity of explosives to open a hull and forcing the submarine to surface.

In explaining why, despite all these resources, the vessel has eluded capture for five days, Carlsson said, "He has everything on his side." In particular, the water provides multiple layers of protection because of differences in temperature, salt content and current at various depths, he said. As a result, officers explained, it is difficult to sustain contact with the craft with radar or sonar. Moreover, each time a depth charge is dropped the water is disrupted, allowing the ship to take evasive action.

Yesterday it was suggested that the submarine probably would have to surface today because it would be running out of air. But it is also possible that the vessel can raise a snorkel just enough during the night to keep it supplied with air. This holds out the prospect that the search could go on for days.

What baffles Swedes is why the Soviets -- if it is in fact their submarine -- would go to such lengths to harass this country. A Defense Ministry study of the submarine problem published last month said that compared with 1980, when submarines were spotted at discreet distances from the shore, "they now act a great deal more provocatively and have been found to penetrate even deeper into our coastal waters than before."

In considering motives for such action, the study observes that if "a foreign power" intends to operate submarines in Swedish waters in wartime then "appropriate planning" will call for detailed investigation of the coastal region.

The submarine issue has emerged as a major political factor in Sweden. It was the main foreign policy issue in the recent campaign for a new parliament, and Palme pledged to maintain a tough line against violations of the country's territorial waters by any power.

Despite its neutralist stance, the need for a strong defense is widely accepted in Sweden. The repeated and disturbing submarine sightings are said to be deepening Sweden's resolve to keep as close a watch as possible on the Baltic Sea, its natural border with the Soviet Union.