The reason here is that your function is only very strongly peaked in a very small region of your integration region and is effectively zero everywhere else, quad
never finds this peak and thus only see's the integrand being zero.
Since in this case you know where the peaks are, it would be reasonable to split the limits of the integration so that you consider the regions around the peaks separately.
To do this you can use the points
argument in a slightly bastardized way to force quad
to consider the peaks separately.
In [3]: integrate.quad(integral_fun, -100000, 100000, points=[-10,10])
Out[3]: (1.0000000000000002, 8.671029607900576e-10)
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…