Investors betting on an optimistic outcome in the war with Iraq -- or those who are discounting it -- may be ignoring history at their peril. Middle East history suggests a more prolonged and difficult aftermath to Operation Iraqi Freedom than is currently priced into stocks.

If, as most military experts expect, the battle joined at Karbala spells the end of Saddam Hussein's regime in the next few weeks, stocks are likely to rally. But the aftermath could be far more problematic.

The recent suicide attack by an Iraqi officer in Najaf is a worrisome sign that even when Saddam Hussein's Ba'ath party is gone, an

intifada

-style uprising is a possibility.

U.S. financial markets are not currently priced for a prolonged occupation of Iraq characterized by suicide bombings and other terrorist-style attacks, as experienced by Israeli forces in the West Bank. Those currently optimistic about shares aren't too concerned about such a possibility.

Prior to the war, Tobias Levkovich, senior institutional U.S. equity strategist at Salomon Smith Barney, issued a report that calculated a 20% probability of a "quick Iraqi campaign followed by a more tumultuous aftermath," including increased terrorism. In line with the market's general optimism about the war, Levkovich's report figured a 60% probability that it will be a short conflict with a positive outcome.

This week, Levkovich said he wouldn't change that view, arguing that the risk of terrorism is not any greater today vs. six weeks or six months ago. The strategist also argued that three of the five biggest market risks of the war -- surging oil prices, a widening regional conflict and severe allied casualties -- appear less of a risk now vs. before the war. (The final one, Iraq using weapons of mass destruction, remains a wild card.)

Nevertheless, the Najaf attack, in which four U.S. soldiers died, surprised some Middle East experts, because "by and large Iraq is a more secular society where you don't have the same kind of religious fanaticism like the Taliban and al Qaeda," said Steve Dinero, a professor of Middle Eastern studies at Philadelphia University.

Should such attacks become routine, as Iraqi Vice President Taha Yassin Ramadan threatened, "the market's not going to like that," said Thomas McManus, equity portfolio strategist at Banc of America Securities. "The market is not going to like anything other than a pretty quick and painless resolution of major goals of the campaign" -- removing Saddam from power and finding weapons of mass destruction.

That said, the strategist believes sentiment has swung "from cakewalk to quagmire" and the market is thus "in a position where it can handle some minor disappointments."

Salomon's Levkovich offered a similar view, suggesting equity risk premiums have "captured" the potential for a tumultuous aftermath in Iraq.

Furthermore, "when you run a portfolio, you build hedges against extreme events, you don't build around them," he said.

Certainly, it's possible that Ramadan's threat and Jihad Islami's pledge to send 4,000 suicide bombers to Iraq both will prove to be desperate and grotesque exaggerations. Hopefully, Egyptian President Hosni Mubarak's warning "if there is one bin Laden now, there will be 100 bin Ladens afterwards" will be grossly inaccurate.

But some Middle East experts fear otherwise, at least in the near term.

After the conventional war is (presumably) won, "the Iraqis will move to unconventional warfare

featuring layers of opposition," including remnants of the Republican Guard, Saddam's special security detail, the Fedayeen, and "suicide bombers who overlap with the Fedayeen," said Steven Yetiv, associate professor of political science at Old Dominion University, who has been a consultant to the U.S. State and Defense departments. (The Fedayeen, a combination of regular and irregular forces, already have attacked coalition forces at Nasariya and Basra.)

"Some of those forces will be fighting for Saddam, and as soon as it's very clear he's on his way down, their fervor will decrease," Yetiv continued. But "others will be fighting for Iraq or the Baghdad in Arab mythology. Some will fight for Islam. Those will continue

fighting after Saddam."

Yes, that's a "worst case scenario" and hopefully will prove overly pessimistic. Perhaps resistance will crumble. Maybe the Bush administration will be vindicated and regime change in Iraq will engender positive change throughout the Middle East. But it seems some civilian military planners, and many investors, initially bet on a best-case scenario in Iraq, and things haven't exactly worked out that way so far.

Sometimes it pays to plan for the worst, especially in wartime, and most especially in the Middle East.

History's Rocky Roadmap

Some have compared postwar Iraq with postwar Japan, in which Gen. Douglas MacArthur oversaw the relatively calm military occupation and initial rebuilding of Japanese society. Less optimistic observers say Israel's experience in Lebanon from 1982 to 2000 and its current occupation of the West Bank provide a more accurate -- and less bullish -- template.

"It's difficult for the American government to understand the differences and similarities between Iraqis who support Saddam, and a lot aren't, and an Iraqi who fears the U.S. occupation," said Dinero. "If, in the minds of Iraqis, they're seeing an occupation that parallels Israel's occupation of the West Bank, their reaction will be parallel."

To many Westerners, the hardest aspect of the war may be grasping that many Iraqis don't see us as liberators or at all beneficial. While "we are coming to bring

Iraqis food and medicine and a better life," as President Bush said Monday, many Arabs see us as an imperial power bent on occupation, if not blasphemous "crusaders" bent on attacking Islam.

Resulting Arab anger may transform into "more terrorism, more recruits, more random violence and 'martyrdom' operations," said Yetiv.

Dinero believes terrorist attacks against allied forces, including suicide bombings, actually will increase after Saddam is (officially) gone.

"I do not believe the people presently fighting against the American army are doing so because they love Saddam," he said. They're fighting "because they fear the U.S. and what our occupation and our belief system will bring to their land."

During World War I, the French and British made a secret pact -- the

Sykes-Picot agreement to carve up the Middle East, Dinero recalled. "From an Arab perspective, this is no different from 1916." (Stern warnings to Syria by Donald Rumsfeld and Colin Powell have done nothing to alleviate Arab concerns that Iraq is the first of a series of American military ventures in the region.)

From a military perspective, Russ Lockwood, CEO of MagWeb.com, the largest online military history archive, recalled the British in World War I initially used "minimal force" in a "grab-as-much-as-you-can" push to Baghdad, but eventually got overextended. The second, ultimately successful phase of the campaign was "much more methodical," paralleling the current situation, although the time frame now is measured in weeks vs. years. There are also some parallels to when Alexander the Great conquered the Persian Empire, the Seleucid wars of succession, a variety of Roman army adventures in the region, and to a lesser account, the Mongol invasion, Lockwood said.

All that may sound like ancient history to us, but the Arab world is "always looking back," Dinero said. To them, "the future is the past."

On some levels, Israel's 1982 invasion of Lebanon most closely parallels "Operation Iraqi Freedom" in that Israel's goal was removing Palestinian terrorist cells operating within Lebanon. The Israelis enjoyed initial successes and were greeted as liberators by the Lebanese. But Israeli soldiers no longer were viewed as a liberators as Lebanese civilian casualties mounted and Christian militia massacred Palestinian refugees at Sabra and Shatilla.

Despite rising attrition among its soldiers and mounting political pressure, Israel didn't extricate itself from Lebanon until 2000, because its leaders feared that leaving would encourage terrorists. That proved to be the case, and it raises far-reaching questions about America's "exit strategy" for Iraq (assuming we have one).

It's oft-stated, but worth repeating: Getting into Baghdad may be easier than getting out.

Aaron L. Task writes daily for TheStreet.com. In keeping with TSC's editorial policy, he doesn't own or short individual stocks, although he owns stock in TheStreet.com. He also doesn't invest in hedge funds or other private investment partnerships. He invites you to send your feedback to

Aaron L. Task.