As I mentioned before their are many reasons why the romans (Yimah shemam) defeating Jews. Here is another example why given by the Rambam (Perhaps to teach us how to not repeat the same mistakes again)-
This is what abolished our kingdom, destroyed our Beit HaMikdash, prolonged our exile, and brought us to our present predicament. Our fathers sinned and are no more.
For they found many astrology books, followed them, and went astray. They imagined that these wisdoms were glorious and greatly beneficial, and they did not study warfare and land conquest. Instead, they imagined that these wisdoms would help them. Therefore, the prophets called them fools; and they certainly were fools, for they followed vanities which cannot avail nor rescue, for they are vain. (Iggrot U'Teshuvot LeRambam, Iggrot Shonot, p. 21. 204)
The Rambam writes as follows: (Rambam, Laws of Kings and Their Wars, 7:15) "A man should not think at the time of war of his wife, nor of his children, nor of his possessions, but he must free his heart of everything and set himself to the battle. And more - he should think that the entire existence of Israel depends on him. And if he is afraid and turns back, it is as if he spilled the blood of his comrades. And regarding this, it is written: 'Not to melt his brother's heart like his heart'... For everyone who fights with all of his heart, and with the intention to sanctify the Name of Hashem, is promised that he will not be harmed... and he will merit the life of the World To Come." (Rambam, Laws of Kings and Their Wars, 7:15)