President Carter yesterday unexpectedly discarded a prepared speech describing his frustration with the federal bureaucracy and returned to a trusted campaign technique - the question and answer forum.

This time it was with the Illinois General Assembly.

In the course of the 30-minute session, the President praised the Equal Rights Amendment - Illnois is one of the key states that have not ratified the amendment - and strongly reaffirmed the "special relationship" between the United States and Israel.STBut the most striking aspect of what occurred here was not what Carter said but that he decided at the last minute to do the unexpected, something almost totally out of character for him.

Since early in his presidency, Carter has meticulously followed his schedule, whether in Washington or traveling around the country, and since the criticism early in the administration that his impromptu remarks often caused public confusion, he has relied increasingly on prepared speeches.

But Carter is also trying to recapture some of the themes and spirit of his campaign, when he vowed always to remain close to "the people" and to conduct an "open government."

He told the assembled legislators that he understood and shared with them the pressures and difficulties of serving in public office.

He added, "I am not saying these things to deplore the responsibility that I have to share with you, but to indicate to you that quite often the difficulties of public service are not adequately understood by the American people, and the best way to let them understand it is to keep an open mind and an open heart and an open door and to reach out to them for advice and counsel . . . ."

White House press secretary Jody Powell said the president first mentioned the possibility of the question and answer format Thursday night in Chicago, although he did not tell his staff of his decision until he was flying to Springfield from Chicago yesterday morning.

"He's obviously comfortable with it and enjoys that sort of give and take," Powell said of the question session. Moreover, Powell said, there was an underlying political reason for the decision.

The ERA is an explosive issue in Illinois, one of the key battlegrounds in the ratification fight.

In his undelivered speech. Carter was prepared to call for ratification, but in his impromptu remarks to the legislature before the question session, he took a more subtle approach.

"The eyes of the nation are focused on the men and women in this chamber," he said. "Illinois has a great tradition of insisting upon equality of opportunity.

". . . What you do here in this chamber in the next few weeks might very well determine whether women do have those equal rights guaranteed in the United States Constitution or whether they don't."

Three more states must ratify the amendment by next spring for it to become part of the Constitution.

ON Israel, Carter said, "I believe Israel can rest assured that there will never be any deviation in our own country from our total commitment to giving them adequate provisions to defend themselves."

Asserted that "an iron triangle of bureaucracy, congressional committees and well-organized special interests" stands in the way government reforms. He said that as governor of Georgia he learned that "there are few things more frustrating than dealing with the federal bureaucracy."

After more than a year as president, he continued, "I am still frustrated by the federal bureaucracy. There are few levers a president can pull to bring immediate action. There are too many agencies, doing too many things, overlapping too often, coordinating too rarely, wasting too much money - and doing too little to solve real problems,"

Carter's return to the themes and techniques of his campaign served to underscore the highly political nature of his two-day trip that ended yesterday. In Illinois, he campaigned for Democratic candidates, and at a dinner Thursday night in Chicago he extolled the virtues of the Cook County Democratic organization.

He would up the trip with a final appearance in Charleston, W. Va., at a fund-raiser for Democratic Sen. Jennnings Randolph.

"He (Randolph) would have had much more impact in West Virginia if he had brought (Sen. Edward M.) Kennedy in here," one Charleston resident said in recognition of Carter's political problems. "Of course, there's nothing wrong with bringing in the presid ent of the United States."