# Integrate: Mathematica does nothing, not even repeat the code!

I need to calculate the following integral:

$$\int_{-\infty}^{\infty}da\int_{-\infty}^{\infty}db\int_{-\infty}^{\infty}dx\int_{-\infty}^{\infty}dy~e^{\frac{-(b^{2}+(a-10g)^{2})}{g^{2}-1}}e^{\frac{-(y^{2}+(10g-x)^{2})}{g^{2}-1}}(0.3+0.7\frac{(b^{2}+(a-10g)^{2})}{g^{2}-1})(0.3+0.7\frac{(y^{2}+(10g-x)^{2})}{g^{2}-1})$$ The corresponding mathematica code is

Integrate[E^(-(b^2 + (a - 10 g)^2)/(g^2 - 1)) E^(-((10 g - x)^2 + y^2)/(g^2 - 1)) (0.3 + 0.7 (b^2 + (a - 10 g)^2)/(g^2 - 1)) (0.3 +
0.7 ((10 g - x)^2 + y^2)/(g^2 - 1)) E^-((a - x)^2 + (b - y)^2), {a, -∞, ∞}, {b, -∞, ∞}, {x, -∞, ∞}, {y, -∞, +∞}, Assumptions -> g > 1]

Mathematica gives nothing. It does not even repeat the integral form. Actually the calulation is finished with a beep and when I define a number (say, 0.3) using a symbol, the symbol becomes undefined.

• Quit the kernel and try again. Let us know the result
– L.K.
Jan 16 '17 at 18:58
• Under the Help menu, there's Why the Beep?... Try it. I'm guess the integral crashed the kernel. Jan 16 '17 at 18:59
• Split the integral in two, dependant on a, b and x,y, it would make the symbolic integration easier. I've managed to integrate one but not two at the same time. Jan 16 '17 at 19:02
• Does this do it? int1 = Integrate[E^(-((10 g-x)^2+y^2)/(g^2-1)) (3/10+7/10 ((10 g-x)^2+y^2)/(g^2-1)) E^-((a-x)^2 + (b-y)^2), {x, -Infinity, Infinity}, {y, -Infinity, Infinity}, Assumptions->g>1] // Simplify; Integrate[ int1 E^(-(b^2+(a-10 g)^2)/(g^2-1)) (3/10+7/10 (b^2 + (a-10 g)^2)/(g^2 -1)), {a, -Infinity, Infinity}, {b, -Infinity, Infinity}, Assumptions->g>1] // Simplify
– Bill
Jan 16 '17 at 19:29
• "when I define a number (say, 0.3) using a symbol, the symbol becomes undefined" indicates that the kernel crashed. Unfortunately, that happens often. In such cases, re-writing the expression is advisable. Jan 16 '17 at 19:39

If I use exact values for 0.3 and 0.7, it works:

Integrate[
E^(-(b^2 + (a - 10 g)^2)/(g^2 - 1)) E^(-((10 g - x)^2 + y^2)/(g^2 -
1)) (3/10 + 7/10 (b^2 + (a - 10 g)^2)/(g^2 - 1)) (3/10 +
7/10 ((10 g - x)^2 + y^2)/(g^2 - 1)) E^-((a - x)^2 + (b - y)^2),
{a, -∞, ∞}, {b, -∞, ∞}, {x, -∞, ∞}, {y, -∞, +∞},
Assumptions -> g > 1]

After a minute or so I get this:

(*  ((-1 + g^2)^2 (29 - 88 g^2 + 109 g^4) π^2)/(50 (-1 + 2 g^2)^3)  *)

When using an exact solver, it is better to use exact numbers such as 3/10 instead of 0.3. The approximate numbers 0.3 are represented by floating-point numbers that are subject to round-off error:

(0.3 + 0.6) - 0.9
(*  -1.11022*10^-16  *)

And such errors can throw off exact solvers.