Even before the events of 11 September, Americans were involved in one of their periodic bouts of history-fuelled self-examination. The death of around 1,000 Second World War veterans a day had stimulated further interest in that war and launched an avalanche of bestselling books with titles such as The Greatest Generation, Flags of Our Fathers and Band of Brothers (now made into the most expensive television drama series ever). Reflections on the courage and self-sacrifice of the dying generation of war veterans made the super-affluent baby boomers of the 1990s feel guilty and unworthy. Those feelings of being not quite up to the achievements of the "Greatest Generation" have profoundly influenced the rhetoric and conduct of the current war against terrorism.
Foreign visitors to the United States are often struck by the size and number of flags flown not just from government buildings, but also from schools, ranch houses, fast-food joints and second-hand car dealerships. The phenomenal outburst of flag flying, waving and wearing since the attacks on New York and Washington might look jingoistic, and perhaps even mawkish, but it has to be seen and understood in the context of American feelings about history and country.
The heroic mythology of the American revolution helped to create an identity for a fledgling nation struggling to hold itself up against the powers of the Old World. In the 19th century, the United States became a country of immigrants - between 1860 and 1900, around 13.5 million immigrants arrived at its shores - and the job of turning Poles, Swedes, Irish, Italians, Germans, Russians and Lithuanians into Americans required an overarching set of beliefs and lessons in good citizenship gleaned from the heroic past. So a widely accepted canon of historical knowledge was developed.
Everyone "knew" that the young George Washington, when accused of chopping down a valuable cherry tree, manfully said: "Father, I cannot tell a lie." Everyone knew the last words of 21-year-old Nathan Hale, captured by the British and sentenced to death for spying: "I only regret that I have but one life to lose for my country." The son of Hale's nephew, the poet and Unitarian minister Edward Everett Hale, wrote one of the most popular American short stories of the 19th century, The Man Without a Country, in which a young US army officer is accused of treason and asked repeatedly to prove his faithfulness to his country. In an ill-judged outburst in the courtroom, he shouts: "Damn the United States! I wish I may never hear of the United States again!"
He is sentenced to a life of perpetual exile at sea, with no one allowed to mention the United States within his hearing. When he is on his deathbed, one of his jailers visits his cabin and finds that it has been turned into a shrine to all things American. As the man without a country shuffles off this mortal coil, he says: "There cannot be a man who loves the old flag as I do, or prays for it as I do, or hopes for it as I do."
Thirty years after Hale's short story was published, another patriotic clergyman, Francis Bellamy, wrote the Pledge of Allegiance to the flag as part of a nationwide ceremony for schoolchildren commemorating the 400th anniversary of Columbus's "discovery" of America. The daily ritual continued through my childhood in Massachusetts in the 1950s, and even today, from Maine to California, American schoolchildren salute the flag before they begin their classes: "I pledge allegiance to the flag of the United States of America and to the republic for which it stands, one nation under God, indivisible, with liberty and justice for all."
All Americans can recite the Pledge of Allegiance, sing "Star-Spangled Banner" or "God Bless America", and spout a dozen well-known quotations - from Nathan Hale to Abraham Lincoln to David G Farragut ("Damn the torpedoes - full speed ahead!").This patriotic education is part of what makes Americans American. Dr Johnson's now cliched observation that "patriotism is the last refuge of a scoundrel" appears to Americans as a laughable example of English cynicism.
As long as their nation remains the most ethnically diverse country in the world (and there are signs that it is getting more rather than less so), Americans will regard patriotism as the glue that holds them together.
One feature of this patriotism under President George W Bush has been the use of the language of the Wild West. Europeans were bemused by Bush's John Wayne-like rhetoric, in which terrorists were "folks" who were wanted "dead or alive". Yet the vocabulary of the Wild West is deeply resonant to all Americans. In July 1893, a young academic called Frederick Jackson Turner spoke at an American Historical Association conference in Chicago. His lecture, titled "The Significance of the Frontier in American History", contained one of the most influential theses in the country's intellectual history. Turner noted that "the existence of an area of free land, its continuous recession, and the advance of American settlement westward, explain American development". He also remarked on the "frontier individualism that from the beginning promoted democracy".
Turner devised his thesis just as the frontier was being closed, and in response to it. How would America respond to the end of limitless physical expansion? Where would the energy that settled the wilderness go? It was pretty obvious to the men and women of Turner's time that America's manifest destiny would next be played out in a role on the world stage. Their prediction has proved true: the optimism and pragmatism of which Turner spoke have usefully outlived the frontier; but now, Americans must reach beyond their frontier individualism.