The Theme system that replaced the older provincial one is often lauded as a reform that allowed the ERE to recover after the Slavic and Muslim invasions. What problems, in particular, did it aim to solve, and was it successful in doing so?
This post is tagged as 15th century but as the Thematic system was largely dissolved by the 11th I'm going to ignore that.
The result of the Roman defeat at Yarmok in 636 was decisive. Both the Armenian and Oriental field armies were battered, in addition to the destruction of their Ghassanid allies who had long been an effective barrier against Arab incursions. These forces were the only field armies in vicinity of the Syria, the next closest field army being the praesental forces kept close to Constantinople. At this point the Romans had to make a choice, pull remaining eastern forces into Palestine or Egypt, protecting the Empire's most financially profitable provinces, withdraw into Anatolia, protecting the Constantinople, or splitting the forces and attempting to defend both Egypt, and Anatolia. The Roman Emperor Heraclius decided to pull all remaining forces into Anatolia, leaving Syria, Palestine, Egypt, and eventually Africa (modern Tunisia) to their fates.
Something to keep in mind when talking about this time period is that decades of brutal, destructive warfare with Persia had just concluded in 628. Heraclius had pushed the empire extremely hard to win the conflict, and it had not yet recovered by the onset of the Arab conquests. During the Persian wars all of Syria, Palestine and Egypt were conquered and occupied; Constantinople was besieged; the Church had to melt down gold and silver to create coinage to pay the soldiers; and the Romans suffered many defeats, depleting the army of soldiers. Considering the difficult position of the Empire's army and finances, it would be incredibly difficult to mount an offensive against the Arabs. With Egypt, Syria, and Palestine gone, even a coherent defensive strategy would be challenging to accomplish. The Empire needed soldiers to defend its borders, but lacked the cash to pay them. This was the beginning to the concept of the Theme system, the need to defend the Empire's borders, but do so at a reduced financial cost. This is where things get a bit complicated, mainstream historians agree that fiscal compensation for soldiers when down as they transitioned into the Thematic system, Treadgold estimates this as a 50% pay reduction but this is far from certain. The reduction of pay meant that soldiers would be hard pressed to support themselves and had to find other means to supplement earnings. Some historians hypothesize that this difference was made up for by billeting the soldiers with the local populations, some argue that Imperial Lands were granted to the soldiers in return for military service. Both sides are fairly well supported so it's not easy to say definitely who is correct.
So now that we've briefly covered the problem the Theme system was trying to solve, we can ask was it successful? For the most part yes, foreign occupation of Anatolia was prevented all the way up until the aftermath of the battle of Manzikert in 1071. In fairness to the Thematic system, it was largely dismantled by this time, with most Stratiotes (Thematic soldiers to put it simply) commuting their service with payments in cash and staying home. There was also a gradual breaking up of the larger Themes into smaller and smaller parts, this succeeded in reducing Thematic rebellions, but also reduced the effectiveness at combating foreign incursions. In conclusion, there were certainly attacks that were simply too large for the Thematic forces to repel, but these rarely (if ever) resulted in significant strategic changes to the Empire's outlook. The Theme system allowed the Empire to survive the Arab conquests and eventually thrive during the 10th and early 11th centuries. Once the Thematic system began to decay, Anatolia could not be held and the Empire would never fully recover.
Sources
Byzantium and its Army Warren Treadgold
Warfare, State and Society in the Byzantine World John Haldon
Recruitment and Conscription John Haldon
Military Service, Lands, and the Status of Soldiers John Haldon
History of the Byzantine State George Ostrogorsky (for some dates)