2
$\begingroup$

I want to evalutate an integral $$I = \int_{-0.01}^0 \int_{-0.01}^0 \left(\frac{1}{\sinh|t_2+t_1+T| \sinh|t_2+t_1|}\right)^{2/m} \left(\frac{\sinh|2t_1+t_2+T|}{\sinh|t_1+T|}\right)^{1/m} \left(\frac{\sinh|t_2|}{\sinh|t_1|}\right)^{1/m},$$ where $m=3$ is fixed and I want to vary $T$. This integral is mathematically shown to be convergent. For various values of $T$ within range $10^{-6}<T<10^{-4}$, I sometimes get an overflow error, such as:

NIntegrate::inumri: The integrand ((Csch[Abs[t1]] Sinh[Abs[t2]])^(1/3) (Csch[Abs[5.01187*10^-6+t1]] Sinh[Abs[<<22>>+2 t1+t2]])^(1/3))/(Sinh[Abs[t1+t2]] Sinh[Abs[5.01187*10^-6+t1+t2]])^(2/3) has evaluated to Overflow, Indeterminate, or Infinity for all sampling points in the region with boundaries {{0,1},{0.,2.48466*10^-32}}.

I don't know a particular pattern for what values of $T$ does this error occurs. (However, the error does not occur for $|T|>0.1$.) Below is my relevant code:

exp1 = (Csch[Abs[t1]] Sinh[Abs[t2]])^(1/
  m) (Sinh[Abs[t1 + t2]] Sinh[Abs[T + t1 + t2]])^(-2/
   m) (Csch[Abs[T + t1]] Sinh[Abs[T + 2 t1 + t2]])^(1/m)
tab1 = Table[{T, 
   NIntegrate[exp1 /. {m -> 3}, {t1, -0.01, 0}, {t2, -0.01, 0}]}, {T, 
   Table[10^(-n), {n, 4, 6, 0.1}]}]

The result is:

{{0.0001, 0.225753 - 2.69464*10^-8 I}, {0.0000794328, 
  0.225296 - 2.4616*10^-8 I}, {0.0000630957, 
  0.224902 - 2.37137*10^-8 I}, {0.0000501187, 
  0.224563}, {0.0000398107, 0.22427}, {0.0000316228, 
  0.224019}, {0.0000251189, 0.223802}, {0.0000199526, 
  0.223616 - 3.04706*10^-8 I}, {0.0000158489, 
  0.223455}, {0.0000125893, 0.223317}, {0.00001, 
  0.223199}, {7.94328*10^-6, 0.223097}, {6.30957*10^-6, 
  0.223009}, {5.01187*10^-6, 
  NIntegrate[
   exp1 /. {m -> 3}, {t1, -0.01, 0}, {t2, -0.01, 0}]}, {3.98107*10^-6,
   NIntegrate[
   exp1 /. {m -> 3}, {t1, -0.01, 0}, {t2, -0.01, 0}]}, {3.16228*10^-6,
   0.222814}, {2.51189*10^-6, 0.222766}, {1.99526*10^-6, 
  0.222725}, {1.58489*10^-6, 0.22269}, {1.25893*10^-6, 
  0.22266}, {1.*10^-6, 0.222634}}

Note that sometimes the integral is left unevaluated.

Why does this error happen? Note that for $T<0$, the only singularity of the integral is at $t_1=0$, which is the boundary of the integration range.

$\endgroup$
2
  • 1
    $\begingroup$ Independant of the value T there is a singularity at t1=t2=0! $\endgroup$ Oct 25 at 13:56
  • $\begingroup$ @UlrichNeumann But that is again the boundary (corner) of the integration range! $\endgroup$
    – eigenvalue
    Oct 25 at 13:58
4
$\begingroup$

Mathematica v12.2(Windows 10) doesn't show this behavior.

Try with rationalized integration limits

tab1 = Table[{T, 
NIntegrate[exp1 /. {m -> 3}, {t1, -1/100, 0}, {t2, -1/100, 0}]}, {T,Table[10^(-n), {n, Range[4,8]}]}]
(*{{1/10000, 0.000109877}, {1/100000, 0.000109843}, {1/1000000,0.000109839}, {1/10000000, 0.000109838}, {1/100000000, 0.000109838}}*)
$\endgroup$
3
  • $\begingroup$ Thanks! That is very interesting, and I wonder why using exact numbers help in this case. $\endgroup$
    – eigenvalue
    Oct 25 at 13:59
  • 1
    $\begingroup$ You're welcome. Before starting evaluation of a command, Mathematica often tries to simplifiy the expression. Numeric numbers possible leads to roundoff effects. $\endgroup$ Oct 25 at 14:23
  • $\begingroup$ Exact numbers have infinite precision. $\endgroup$ Oct 25 at 15:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.