I want to use Simpson's rule to evaluate the following double integral: $$\int_{a}^{b}\left|\int_{0}^{z}x\cdot \mathrm{erf}(x-10)\cdot J_{0}(x) \mathrm{dx}\right|^{2}\exp(-0.5*(z-40)^2)\mathrm{dz} $$
Usually, if both the limits were numeric I would get away with just applying simps
from scipy.integrate
twice, but here I have no idea how to proceed.