This question is very nicely discussed in the paper of Ruelle, Ruelle, David(F-IHES) Is our mathematics natural? The case of equilibrium statistical mechanics. Bull. Amer. Math. Soc. (N.S.) 19 (1988), no. 1, 259–268. But he does not really have an answer, and perhaps nobody has an exact answer. My own opinion, is that a large part of mathematics (some say all of it, but I disagree) actually comes from physics. If this is so, it is not surprising that physics helps in discovering new theorems. Using Ruelle's example, if we ever discover an extraterrestrial civilization, its mathematics (most of it) must be equivalent to a large part of our mathematics. I am convinced that this is so. Most of mathematics is somehow determined by the laws of nature, that is by physics. A completely different explanation (with which I cannot completely agree) is that some physicists are just very clever people, and once they start thinking of mathematics, they discover new things, and when they (physicists) publish these things everyone says that these results "came from physics". I agree that this happens sometimes, but on my opinion this is a small part of the picture. I don't want to give examples (I am sure, many will be given), but I just want to make the point that this phenomenon ("unreasonable effectiveness of physics in mathematics) occurs from the very beginning of mathematics (and physics). I mean the remarkable surviving work of Archimedes, A method of mechanical theorems, where he uses physical reasoning to prove guess purely mathematical theorems. This example can be used to defend any of the two above explanations:-)