Everything takes place under Allah's will and according to His traditions and the same way Allah had the power to prevent Prophet Ibrahim's blade from cutting he could have also disabled all of the enemies' weapons, and miraculously saved Imam Hussein, but such a miracle did not happen for everything should not be carried out through uncommon and unordinary means and on top of that the most noblest and greatest causes and philosophies behind the incident of Ashura, such as protecting Islam, presenting the perfect role model for mankind, meeting Allah through martyrdom, etc. were only and only possible under regular circumstances and the occurrence of what happened on that day.
There is no doubt that the universe is the creation of Allah and operates according to his commands and the traditions he has determined. Allah is the cause of all causes (the ultimate cause) therefore He's the one who, through His never-ending wisdom, has assigned every cause its particular effect, hence, furthermore he's capable to take away that effect. Like when God removed the natural effect of fire – which was to burn and provide heat – right before the idol worshipers through Prophet Ibrahim into it, in order to save him. Or when Allah prevented the sharp knife in Prophet Ibrahim's hand from penetrating that saved Ismail from being sacrificed by his father. Of course, we believe that God was able to dull the swords and daggers of Yazid's Army and miraculously save Imam Hussein and his companions, but this did not happen because not everything is supposed to happen by miracles. Actually in contrast to that, Allah's divine custom is to allow things to happen through their own natural and ordinary causes.
In addition to such, there were many other purposes intended in the incident of Ashura which were only possible if it were carried out by natural means. Some are as follows:
1. When regarding the complicated political condition that Muawiyah and Yazid had created, justifying the wrong they would do by doing whatsoever they desired and merely labeling it with Islam and also the fact that distinguishing wrong from right had became very difficult, we can come to the conclusion that the only way to stop this situation and revive Islam was for the Imam to become martyred along with his children and companions. 
2. The ahadith regarding this matter indicate that the Imam was destined to be martyred so he could achieve his ultimate purpose which was awakening the ummah (Muslim nation) and saving them from ignorance. 
3. Imam Hussein believed that martyrdom was the most beautiful and honorable death possible. This can be seen in the sermon that he gave on his departure from Mecca to Iraq: "The beauty of death for mankind is like the beauty of a necklace on the neck of maidens.";  meaning that death isn’t a restriction imposed onto one, but rather like the beauty of a necklace, a blessing granted to him. So, why would anyone refuse to wear this necklace, especially when it is for Allah's sake?! And for Imam Hussein (A.S.), dying for the sake of his religion was very pleasant and like honey.  Shehadah isn’t a flaw or deficiency, rather, it is of high and great value  and Imam Hussein would have missed out on it if his martyrdom was to be prevented.
4. Meeting Allah and his Prophets meant much more to Imam Hussein than remaining in this world - especially with the governing circumstances at that time - as he mentioned in his sermon in Mecca: "My eagerness to meet my ancestors is like the eagerness of Yaaqub to meet Yusuf." 
5. The Imam wasn’t willing to use miracles, because he was obliged to conform to ordinary circumstances all humans must consent and adapt to. In addition to that, one of the main reasons why Imam Hussein has had such a great impact upon the lives of Muslims and all seekers of justice and freedom is the fact that he carried out his acts without using supernatural means but rather conducted based on common and standard circumstances. Leading his household to an unfair battle, them being taken as prisoners and all the disrespect they saw, were reasons to why Imam Hussein's uprising became monumental and lasted.  True, the imam could have overthrown Yazid using miracles, but the affect of such would be very much less than what he did on Ashura and wouldn’t reveal the sinister intentions of the Umayyids.
6. The event of Ashura and the way Imam Hussein fought oppression is an act of standing before deviation from Allah's commands, something that might happen at any period of time for any Muslim and a true Muslim must follow the path of the Imam and fight for it. If Imam Hussein (A.S.) wanted to perform this vital duty by miracles and his authority in cosmic guardianship (wilyah takwini) he would not have been able to be a role model for all humans of all times. Thus Prophets and Imams were bound to act according to the ordinary standards of knowledge and power in their day to day lives and merely do things like miracles only when God desired and when it was for the sake of the community and nation’s (ummah) guidance.  God Almighty has appointed the prophets and imams to be the role models and teachers of mankind so we can pick up the right lifestyle by observing their lives and codes of conduct, thus if Imam Hussein (A.S.) had saved himself from shahadah by using miracles, he and his household would no longer play the role of being an example of resistance, fighting oppression, and patience when facing difficulties and making sacrifices for greater values.
 See: Misbah Yazdi, Muhammad Taqi, Azarakhshi Digar az Asemane Karbala, pp. 44-66.
 Biharul-Anwar, vol. 44, pg. 329.
 Biharul-Anwar, vol. 44, pg. 366; Muhaddith Ardebili, Kashful-Ghummah fi Ma’rifatil-A’immah, vol. 2, pg. 29; Luhuf, pp. 110-111.
 Shokufayiye Aql dar Partove Nehzate Hoseini, pg. 27.
 Biharul-Anwar, vol. 44, pg. 366; Kashful-Ghummah fi Ma’rifatil-A’immah, vol. 2, pg. 29; Luhuf, pp. 110-111.
 Adopted from Question 580 (website: 633): Imam Husein and the rejection of water on the day of Ashura.