From Dr. Laurence Brown:
Ar-Rum (The Romans - surah
30) similarly presents and interesting entrée
on the banquet of 'food for thought.' Verses 2-4 were revealed at the time of a victory (in battle) of Persia over Rome, prior
to news of the battle reaching Makkah by normal channels (i.e., travelers, caravans, etc.). Furthermore, a reversal of fortunes, with Rom visiting victory over Persia within 3 to 9 years, was predicted in the same verses. As history records such events, Persia celebrated victory over Rome at Antioch in 613 CE, and the Byzantines were subsequently defeated in Damascus, driven out of Armenia, and overrun in their cherished city of Jerusalem.  Chalcedon was taken by the Persians in 617 CE, and Egypt conquered in 619.   The situation was beginning to look pretty bleak for the Roman empire, right up to the time Heraclius launched his historic campaign of 622-627 CE. Decisively pounding the Persian forces, led by the famous general Shahr-Baraz, on Armenian soil in the year 622 CE, the Romans defeated a major Persian force for the first time in three years since losing Egypt, nine years since the defeat at Antioch, and bracketing the remainder of the above mentioned deats within the time period of three to nine years.   Surah
"The Romans have been defeated.
In the nearest land (Syria, Iraq, Jordan, and Palestine),
and they, after their defeat, will be victorious.
Within three to nine years. The decision of the matter,
before and after (these events) is only with Allah.
And on that Day, the believers (i.e. Muslims) will rejoice."
(TMQ - Muhammad Al-Hilali and Muhammad Khan translation - 30:2-4)
The history is remarkable, for the reason that by the time of Muhammad, Rome was an empire in decay. The period of 395-476 CE is described in scholastic works as the fall of the Western Empire. Alaric, chief of the Visigoths, led the army which sacked Rome in August, 410 CE. Gaiseric, king of the Vandals and the Alani, sacked Rome in the summer of 455 CE. Attila the Hun overran the area in the mid-400's, and the last emperor of the intact and undivided Roman empire was deposed in the late 5th century. So a prediction which surfaced nearly two centruies later, stating that the already disintegrating Roman empire would gain a victory over the huge and seemingly superior Persian army, would have seemed rash on a human level. And so it appears to have been judged by those who denied the revelation - men such as Ubay Ibn Khalf.
The story is narrated in many historical accounts of Arabian history. The Arabs did not percieve the conflict to be limited to one of Persia versus Rome, but rather a contest between paganism and people of a scripture. The pagan Arabs conceived the fire-worshipping Persians to be brothers in paganism whereas the Muslims viewed the Romans to be people of a scripture. hence the interest in one side prevailing, reflecting the superiority of the god of the winner. When the Persians were victorious over Rome, the pagan Arabs celebrated. Following this, the above ayat
(verses) were revealed, strengthening the hearts of the believers. When Abu Bakr As-Siddiq (the closest companion and the future first Caliph following the prophet's demise) learned the revelation, he interrupted the pagans from their celebration and told them thst they should not be so happy, because the victory was destined to be overturned with the help of Allah. Upon hearing this, Ubay Ibn Khalf called Abu Bakr a liar, prompting Abu Bakr to return the charge by saying, "You are the liar, O enemy of Allah." Ubay then challenged Abu Bakr by betting 10 camels that Rome would not be victorious in 3 years. When Abu Bakr informed Muhammad of the wager (which was made before the prohibition of gambling was revealed), Muhammad reminded him that the Arabic word 'Bid'i
' in the revealed verses means between three and nine years, and so the time period should be extended to that foretold in the revelation. When Abu Bakr returned to Ubay, Ubay asked if Abu BAkr regretted the wager, to which Abu Bakr responded in the negative, following which Abu Bakr stated that he wanted to increase the wager to 100 camels and the time to 9 years. Ubay agreed. 9 years later Abu Bakr gained a herd of camels, and the encyclopedia of Islamic evidences gained yet one more entry. 
An odd prediction in completion of the above prophecy is the final line, "And on that Day, the believers (i.e., Muslims) will rejoice." In the absence of microwave and satellite relays, radios, CNN, etc., news of such events took days to weeks, sometimes even months (if weather forbade travel) to achieve transmission. How, then, could the prediction that the Muslims would be rejoicing on the very day the Persians were defeated be made with such confidence? Yet, such was precisely the case, for the predicted defeat of the Persians occurred on the exact same day that the Muslims celebrated their own victory over the disbelievers at the Battle of Badr. Worldly coincidence or divine plan?
 Ostrogorsky, George. 1969. History of the Byzantine State
. (Translated from German by Joan Hussey). New Brunswick: Rutgers University Press. p. 95.
 Sykes, Sir Percy Molesworth. 1951. A History of Persia
. 3rd edition. Vol 1. London: Macmillan & Co., Ltd. p. 483.
 Ostrogorsky, George. p. 95.
 Ostrogorsky, George. pp. 100-101.
 Sykes, Sir Percy Molesworth. Vol 1. pp. 483-484.
 Tafseer Ibn Kathir, Musnad Ahmad, Sunan Tirmithee and An-Nisa'ee
(Brown, The First and Final Commandment
, pp. 397-400)