Amid a dazzling display of imperial pomp and aristocratic wealth that contrasted markedly with her somber words about the economic crisis in Britain and turmoil abroad, Queen Elizabeth II opened Parliament here today.

The queen presented the austere legislative program of Prime Minister Margaret Thatcher for the coming year, including special measures to cope with "the hardship and worries of those suffering unemployment." The queen's traditional speech for the ceremonial gathering of the two houses of Parliament is prepared by the government.

Listening in the wood-paneled chamber of the House of Lords were nobles of the realm in ermine-trimmed scarlet robes, their ladies in ball gowns and diamond tiaras, lord justices in gray wigs, ambassadors in formal dress and medals, ladies in waiting in white, and yeomen of the guard in scarlet and gold. Even the BBC television cameramen wore long gray morning coats.

The queen, dressed in white and gold with a scarlet train, diamond necklace and imperial crown, sat on a golden throne with Prince Philip and Prince Charles in military uniforms on either side. They had come from Buckingham Palace on a sunny autumn day in a procession of gold-encrusted coaches and red-coated cavalry on prancing white horses.

Once the pageantry had ended, the gloom of Britain's severe economic problems enveloped the new session of Parliament. Conservative party back-benchers chosen by Thatcher to deliver the House of Commons response to the queen's speech dwelled on the problems of dying industries, rising unemployment and the growing disparity between the "two nations" of relatively rich southern England around London and the hard-hit industrial regions of northern England, Scotland and Wales.

Opposition leader Michael Foot said their concern and that of other worried Conservatives, as well as the Labor Party opposition, was part of "a rising discontent in this house and in the country" against Thatcher's economic policies, which he said were "leading the country to ruin."

Defending her policies while outlining her government's program for the coming year, Thatcher attributed Britain's recession, the deepest among the major industrial countries, to the world-wide economic slowdown compounded by the long-term "underlying weakness of our industrial economy and the fact that we have just not been sufficiently competitive."

She admitted her government has had difficulty accomplishing some of its primary goals, such as cutting government spending. She blamed excessive pay raises for government workers, the continuing "excessive" cash demands of overmanned and inefficient nationalized industries, and the higher cost of benefits for the rapidly growing number of unemployed.

But she pointed out that the inflation rate has begun to fall, wage increases in private industry are being moderated, and the number of strikes has decreased. She added that Britain also has the assured energy supply and steadily increasing revenue of North Sea oil.

Thatcher promised to continue fighting inflation with strict monetary and fiscal policies and by holding down government pay increases. She recommitted her government to "open up as much of the nationalized industries as we can to the competition and discipline of the private sector" by ending post office, telecommunications and transportation monopolies and seeking private investment in the British National Oil Corp. and other government-owned firms.

In foreign affairs, she said her government "shall achieve or come very close" to increasing defense spending by the NATO alliance target of 3 percent above inflation despite a reduction in planned military expenditure both this year and next.

She said Britain welcomed President-elect Ronald Reagan's intention to give "the highest priority to the maintenance of a confident and powerful alliance," which, she said, "creates the right basis for close cooperation and partnership between Europe and America."