As his whistle-stop bumped slowly up the peninsula from San Jose, the candidate was at his best: fresh, crisp and feisty. He kept hearing a new "pulse beat" from the "pounding rails." He kept talking about another old train rider, Harry Truman, who came from behind to win the presidency.

The crowds were large and loud at every stop. Everywhere there were dozens of signs with the candidate's official campaign theme: "A vote for Anderson is a vote for Anderson."

But there was an air of unreality about it all. It was best captured by the old Jackson Browne song played by a rock band that greeted the train here: It was called "Running on Empty."

For during these last, long days of the campaign, John B. Anderson is exactly what he once swore he never wanted to be: a candidate with no chance of winning the presidential race, but able to profoundly affect its outcome.

Many of his advisers and most loyal supporters privately concede their greatest hope is only for a respectable showing, enough to "send a message" and keep their hopes alive for forming a new third party.

"The nice thing is that this is not the end. It's the beginning of a third party. So I don't feel tired or weary," says John Buckley, the sheriff of Middlesex County, Mass., a skilled politician who has been with Anderson from the very beginning.

"Basically, it was just the old third-party problem that's held us back. It was a question of time," he added. "This was the 12th year of the Reagan candidacy, the ninth year of the Carter one. We had only six months."

What happened?

Anderson's candidacy was improbable from the start, perhaps fatally so. Illusionary. Impossible. Unlikely, at best.

"In the fact of what was really possible, we're a roaring success," says one adviser."It's always been a long shot. The odds against him were very, very high."

Here he was, a figure unknown to most Americans only eight months ago, a rather conventional congressman from Rockford, Ill. He'd served the Republican Party long and well, yet he couldn't win a single GOP primary. He was a man of traditional views, a strange vehicle for protest.

His biggest strength wasn't what he was. It was what he was not. He wasn't Ronald Reagan. And he wasn't Jimmy Carter. That was important, very important, in an election where almost half the population though both men inadequate to govern.

Like all candidates, Anderson was flawed. He was too preachy, some said. He was a rebel without a cause, said others. Or at least it was hard to define what his cause was.

But he was different, and that was important: stern, strong-jawed with a resounding baritone voice, horned-rimmed glasses and that snowy white hair; an intellectual in a profession that detests braininess, perhaps the most cerebral presidential candidate since Adlai Stevenson, a man he quoted often and well.

For a moment, he rode the crest. He was a bright new face of presidential politics -- the candidate with ideas, possessor of what his supporters called "the Anderson difference," a politician not afraid to say his piece, hell or be damned.

The Secret Service gave him the code name "Stardust," and his fiery wife, Keke, was dubbed "Starlet." The Gallup Poll put him at 24 percent in June, ahead of Carter and Reagan in some states. The Democratic National Committee was so afraid of what his candidacy would to to President Carter its leaders considered -- then rejected -- a plan to spend $225,000 to keep him off the ballot.

But somehow, somehwere along the way, the magic slipped away from John Anderson. By his own admission he became a "sidebar" in the presidential race. Now, on election eve, he stands at between 7 and 10 percent in the latest national opinion polls.

"They didn't take advantage of the momentum when the momentum was there," says Peter Hart, the political pollster. "The attitudes were there. He was definitely part of the equation. People wanted to know more about him.

"Then he became a convention politician. The uniqueness went out of his campaign. He ended up giving people more of the same stuff rather than something unique," adds Hart. "Voters found out about his 50 cent gas tax, but there weren't 10 specific interesting and unique proposals to hang your hat on."

Anderson rejects such remarks as unrealistic. "You cannot give people a great, indigestible mass. It's hard enough to sell one idea," he said in an introspective session with a handful of reporters last week in Stamford, Conn. "To think you're going to come up with a beautiful, seven-page blueprint to reform society, change the world and do all of these things sounds so attractive in theory. But I think that would stimulate far more cynicism, far more resistance. A fellow like Aristotle comes along once every 2,000 years."

"I don't think people are going to buy whole new books of words and music written to the tune of 'Brave New World,'" he added. "I think you're going to have to fight your way back gradually, step-by-step, and we've tried to do that."

Whatever happened to the Anderson campaign happened during the summer. After the Illinois congressman launched his independent candidacy in April, he shifted tactics.

His campaign lost its innocence. David Garth, the New York political media adviser, went to work for Anderson. The prestigious Washington law firm of Arnold and Porter was hired for legal work. The campaign tried to become a respectable, middle-of-the-road effort, carving out a niche in the center of the political spectrum.

Everything was directed at getting on the ballot in all of the 50 states, a costly and time-consuming effort. The theory was that, to be a credible national candidate, Anderson had to be on every ballot, and that he would get a big boost from this. He didn't.

Anderson tried courting special interest groups: Jews, blacks and organized labor. He told them all pretty much what they wanted to hear. But he won few over.

His erudite speaking style, evangelistic manner and past voting record didn't sell among labor leaders. He couldn't communicate with blue collar America. "You've got to get that blue collar vote or you're not a viable candidate in America," says Sheriff Buckley.

Anderson was left with a loyal hardcore of support among a rather affluent well-educated slice of middle class white America.

There were tactical mistakes. In an effort to attract media attention during the Republican National Convention, the candidate was sent on a trip to the Middle East and Europe. The trip cost almost $225,000 in precious campaign funds, and it attracted only mixed reviews.

Then there was the curious flirtation with Sen. Edward Kennedy. After a meeting with the Democratic senator just before the Democratic national convention, Anderson suggested he would drop his independent bid if Kennedy won the Democratic nomination. A few days later he changed his mind when that seemed politically expedient. The man whom some of his House colleagues had called "St. John the Righteous" had become "John the Old Pol."

Then, there were money and Jimmy Carter. Under federal campaign finance law, the nominees of the major parties automatically received $29.4 million each to conduct their campaigns. Anderson got none, although the Federal Election Commission has ruled he will receive retroactive funds, provided he gets 5 percent or more of the vote tomorrow.

The Carter campaign and the Democrats went after Anderson with a vengeance. They circulated copies of his voting record, claiming he was anti-labor and anti-consumer and supported the Vietnam war and nuclear power. They hired lawyers to fight his attempts to get on the ballot. They ridiculed his candidacy. They steadfastly worked to prevent the president from participating in any debate forum that included Anderson. And in the closing days of the campaign they aired commercials distorting Anderson's civil rights record.

By Labor Day, "we were about ready to go over the waterfall," one Anderson aide said at the time. The campaign was deeply in debt and Anderson was falling in the polls.

Anderson struggled back, attempting to regain the old magic of springtime. He condemned the MX missile program before aerospace workers. He told a group of religious broadcasters that the Moral Majority and other conservative Christian groups were a threat to democracy.

He spoke passionately of a "new conservation ethic," and the "new realism" of world population and the arms race.

But it sometimes seemed as if he were followed by a black cloud. Some of it was his own campaign's making. The day he released his 317-page National Unity platform, for example, he flew off to the Midwest. But nobody had bothered to bring any copies of it along for the regional press.

When he arrived at Detroit a few days later for a joint press conference with his new running mate, Patrick Lucey, the former Wisconsin governor told reporters his family car was a French-made Peugeot, not an American-made auto. When Anderson arrived in Philadelphia, the day after his League of Women Voters debate with Ronald Reagan, he found a rally hall only one-eighth full, thanks in part to a decision to charge $3 for admission.

The debate, which the campaign had hoped would give Anderson a big boost, didn't. And by the first week in October many of those closet to the campaign had given up any chance of winning.