London (CNN) -- Diehard supporters, tourists and the curious swamped pockets of left-wing protesters to bid farewell to former British Prime Minister Margaret Thatcher in London Wednesday.
In scenes that echoed the divisions Thatcher drove through Britain as she transformed the economy and society during the 1980s, people of all social classes lined the route from the Palace of Westminster to St. Paul's, some to pay tribute, some to condemn and many just to get up close to a spectacular state occasion.
Hours before the ceremony began, the crowds were already five or six deep in some places; thousands crammed onto the sidewalk alongside souvenir shops and cafes opposite the cathedral -- for centuries a symbol of London and the site of historic moments in the life of the city, from the Blitz to the Royal Wedding of Prince Charles and Lady Diana to the Occupy protests.
Many of the onlookers were smartly dressed, their dark outfits echoing the formal suits of the "official" mourners; others carried Union Jacks, photographs of the "Iron Lady" and fold-up picnic chairs, giving the somber occasion a somewhat festive air.
"I had to be here," said Ian Twinn, a child of the Thatcher era, originally from Essex in eastern England, who traveled from his home in New York especially for the funeral.
He typified the sort of person for whom Thatcher's legacy of free-market economics and individuality had the greatest impact.
"I was a boy in the 1980s. Rightly or wrongly, she changed the landscape of the UK forever, and she made me feel I could do anything," said Twinn. "We haven't seen anybody like her since -- on either side of the Atlantic."
For Jacqueline Lawrie, from London, who met Thatcher several times in the 1980s while working as a photographer on the local paper in her constituency, Britain's first female PM was a huge influence.
"She was a real inspiration for women -- she made us feel we could achieve anything we wanted to," Lawrie said.
Fellow Londoner Catherine Bingham agreed: "She did so much to show women that there isn't a glass ceiling."
While the majority of those in the crowds were old enough to remember Thatcher's era well, younger mourners were also on hand to pay tribute.
"She had a really good attitude and didn't let anything stand in her way," said Alistair Brockbanks, who was just four years old when Thatcher left Downing Street for the last time, "I think she's quite inspirational to people."
Iain McGill, from Edinburgh, said Thatcher "showed the value, the power of ideas. She changed the lives of tens of millions of people for the better, she defeated Communism. She changed the world, not down the barrel of a gun but through ideas."
But others in the crowd felt Thatcher's 11 years in power had left the UK a less positive legacy.
At Ludgate Circus on the approach to St. Paul's, a crowd of about 100 protesters waved placards, rainbow-hued "Peace" flags and signs reading "Tory Scum," "Anarchists Against Thatcher" and "Respect is earned in life, not death" as the Union Jack-draped coffin, topped with an opulent arrangement of cream roses, passed by on a gun carriage.
Rowland, from London, was among those waving Socialist Worker placards reading: "We remember: The miners, Falklands, Poll Tax, Bobby Sands. Now bury Thatcherism," a summing up of the coal battles, the Falklands Conflict, a hated tax based on homes and an Irish Republican Army convict who died on hunger strike.
"I'm not here to celebrate Thatcher's death, which I think some are," he insisted. "I'm here because this shouldn't have been a state funeral. David Cameron and others have tried to present this as a moment of state unity, but she's not a unifying figure -- the ideas she represents are continuing to do great harm to the country."
London's police, well used to running security in a city where the pomp and ceremony of royal and state occasions is a feature of life, had warned protesters to exercise carefully their right to object to what Thatcher stood for. Turning their backs on the military procession carrying Thatcher's casket was acceptable; yelling obscenities and throwing objects was not.
Even some of the protesters were of a very British kind: Polite to a fault.
"Rest in Peace, but Kindness is better than Greed," read one sign, carried by James Wilkinson, from London.
"It's a protest, but a mild one," he explained. "I really wanted to see the spectacle, I admit that, but I thought if I came, I had to show that I'm no fan of Margaret Thatcher. I didn't think she warranted such an occasion."
Many of those who lined the streets in tribute to the former PM said they understood that she was a polarizing figure.
"Whether you like someone or not, and whether you like what they did or not, you have to be respectful," said Lionel Voke, an activist in the Conservative Party that the "Iron Lady" led to three election victories.
"We're here out of respect -- to us, she was wonderful. I accept that not everyone sees it the same way, but it's the same if Tony Blair died. I wouldn't necessarily come, but I'd expect him to be treated with respect, and I'd want him to rest in peace."
Blair led the reformed Labour Party to victory over the Conservatives in 1997, seven years after Thatcher was unceremoniously bundled out of office in a political coup by her colleagues.
He was among the mourners at the funeral, a reminder that she saw the adoption of free market economic policies by the rival Labour Party as perhaps her greatest achievement -- an orthodoxy few in the political mainstream challenge despite the banking crisis and a lengthy recession.
"People have a right to have their say, and they did that on Saturday at their protests, but I don't think you should interrupt people's grief -- this is a family which has lost their mother, their grandmother," said Ian Twinn.
Others were clearly angered by the presence of what they saw as an "obnoxious and tasteless" protest, with mutterings of "no respect," and "put them on the front line!" spreading through the crowd.
But one of those demonstrating against Thatcher's legacy, Ben, from London, said he had thought carefully about the wording of his banner: "RIP: Regulated finance industry, fair taxes, communities, the great British mining industry, free milk for schoolkids," because "I didn't want to be insulting or disrespectful."
And for the most part, the boos and chants were drowned out by ordinary members of the public who came to bid farewell to a woman who transformed Britain and, in some cases, their own lives.
"We know what the UK was like before 1979 and it wasn't pleasant," said Voke. "I started my own business in the 1970s, and it thrived in the '80s -- I credit Margaret Thatcher for that."
That was a sentiment echoed by Fred Ehrlich, a "great admirer" of Thatcher, who moved to the UK from his native Germany in 1957. "She was just what this country needed. Before she came along, in the 1970s, it was awful here, they used to call it 'the sick man of Europe,' but she changed all that."
The funeral -- officially ceremonial rather than a state occasion in a distinction invisible to all but the most pedantic royal watcher -- was the first for a former prime minister and war leader since Winston Churchill's body was borne along the same route a generation ago.
In recognition of her role in the Falklands conflict with Argentina in the early 1980s, pall-bearers from each of the UK's armed services carried Thatcher's coffin into the cathedral, having escorted it from the official church of the Royal Air Force.
Retired RAF serviceman David Tindall, from Kent in southeastern England, was one of many former armed forces personnel there "to pay my respects to a lady I thought was the greatest prime minister since Churchill."
While for many the day was a somber one, for Katherine Mills, from London, it was a positive occasion.
"I don't really do funerals, but for her, I thought I should come along. It feels like a celebration," she said. "It's like the changing of the guard; we've moved into a different season with her passing. It's not a sad occasion -- she had had an amazing life."
CNN's Laura Smith-Spark contributed to this report.