There are several reason why it failed, and also several times that they engineers had the opportunity to prevent this whole damn thing from happening.
Haliburton used a not so good method to cement the well in HOURS before the explosion. Once Haliburton finished with the well, the rigs operators decided not to run some test that weren't "needed" but were recommended. Then when they did actually run the required pressure tests and what not, the well failed those tests. So instead of shutting down the operation, they decided to move forward with some more tests, and that's when the explosion occurred. I think it was within 20 hours of Haliburton finishing work on the well itself that the explosion happened.
A couple of other things happened as well during this whole thing. The first was the BOP failing. The battery died, and it's hydraulic system was leaking, so even if someone managed to hit the button, it wouldn't do anything. Then after the fire started on the rig itself, they were trying to turn off some valve that they thought might stop the fire, only to find out that the valve was replaced with a test unit. Of course they found this out 20 hours AFTER they started trying to figure out what was up with the valve. They wasted a day on that for nothing. Awesome.
The sad part is that all the safety equipment is in place, they just never checked it, and then ignored the results of the tests that are setup to warn about these things. So not only was this a mechanical failure, but it was also caused by people trying to take short cut to make a buck. Hence why the state is trying to go after BP on criminal charges, because there is evidence that they ignored repeated warnings and took illegal shortcuts.
Having worked in the oil fields up in Canada, I can say that it is absolutely inconceivable to ignore these safety systems. I have seen this equipment, and seen what it can do, and why in the world someone would ignore them is beyond me. And why was this acceptable? I got YELLED at if I rolled up my selves on my covies on the work site for christ sake, and yet these fucktards are ignoring VITAL safety tests and nobody says a thing? Seriously? What the hell is that? If Canada can regulate the industry properly, why can't the US? Oh that's right, thats because the people in the government that are supposed to be watching over and regulating the industry are literally sleeping with representatives from said industry, and letting them write their own applications for permits and what not and then approving them. Gotta love the nice and uncorrupted US government
It's very sad that this whole thing was totally preventable. *sigh* God this country pisses me off sometimes!