A provision in Canada's new National Energy Program that would allow oil and gas companies to drive out foreign shareholders has raised fears among securities industry analysts that the nation no longer may be able to attract U.S. energy investments.

Federal Energy Minister Marc Lalonde unveiled an omnibus Energy Security Act last week which, among many other proposed changes, could enable Canadian companies to drive out foreign shareholders.

The act contains amendments to many other pieces of federal legislation, but the analysts are concerned about proposed changes in the Canada Business Corporations Act.

The act would enable companies dependent on a high degree of Canadian ownership as a requirement for government grants, royalties, licenses, and permits to reduce foreign shareholdings by cancelling existing issued shares.

This could happen only if the foreign investor refused to sell. In such circumstances, the company could cancel the shares, reissue them as "constrained" shares and resell them to Canadians. The foreign shareholder then would receive the proceeds of the sale.

Companies would be able to issue both free and constrained shares and would be entitled to buy back shares and reissue an equivalent number of shares that could be held only by Canadians.

Foreign investors dissatisfied with their treatment could file notices of dissent and receive "fair value," based on independent appraisal of the company's assets.

There is no indication of how many, if any, companies would resort to the proposed forced Canadianization, but analysts here fear the proposed legislation will be seen as another example of "foreigners not welcome."

Although the legislation is permissive, enabling those companies that wish to raise their Canadian ownership ratio to do so--and only with the consent of two-thirds of the shareholders--analysts say the threat of forced sale is enough to turn foreign investors away from the Canadian market.

Canadian oil and gas companies have been among the most active issues on the American Stock Exchange in New York. Although these issues accounted for a high proportion of total Amex trading in 1981, analysts say activity in the Canadian oils has fallen by half in New York. They fear that the Energy Security Act could result in a further steep decline in interest in Canadian energy securities among U.S. investors.

They also fear that Canadian oil and gas shares will decline if companies use their own funds to buy back stock, reissue it in restricted form, and attempt to resell the shares to the much smaller Canadian population.

Burns Fry Ltd. of Toronto, a major investment house, says in a report that as the legislation proceeds and becomes more widely known, "There is a danger of an overreaction by non-Canadian investors to the potential risks inherent in the legislation."

This could produce a "further sell-off of Canadian energy securities by foreign investors," the report says. In the longer term, "It is also likely that the non-Canadian owner would be more reluctant to invest in shares of a company with restricted ownership or in a company that could consider restricting its shares.

"This could become a significant factor limiting the impact of non-Canadian investment in the energy sector of the Canadian securities markets," it adds. The report emphasizes that the legislation will have no direct impact if companies do not seek to put restraints on common shares.

It says that, in most instances, ownership restrictions will apply to new shares and not to existing shares.

Ed Zederayko, an analyst with Gordon Securities Ltd. in Toronto, feels that the average foreign investor will see the act as another move aimed against the non-Canadian investor.