1
$\begingroup$

I am having trouble performing the following integration which comes from a larger function (let me know if I inputted the code wrong from Mathematica so I can fix it!) and even with assumptions, Mathematica just gives back the original line of code. Any suggestions on how to help Mathematica evaluate this I would be grateful, thanks! (I can also post in Latex what the integral looks like if that may help anyone).

(Note: I do need/want the symbolic version of this and not a numerical form, so I haven't tried NIntegrate[] yet. I am particularly interested in the behavior of the Q's and m's (specifically ln(-Q^2/m^2) and how that behaves. This is the final step in a computation from QFT if anyone was wondering).

Integrate[SeriesData[\[Epsilon], 0, {Complex[0, 
Rational[1, 4]] Pi^(-2) (
2 m^4 - 4 m^2 (m^2 - Q^2 (1 - x) x) - (m^2 - Q^2 (1 - x) x) (
 6 (m^2 - Q^2 (1 - x) x) + Q^2 (5 - 12 x + 8 x^2)))
 Subscript[m, 1]^2 Subscript[m, 2]^2, Complex[0, 
Rational[1, 16]]
 Pi^(-2) ((-8)
   m^4 + m^2 ((-8) Q^2 (-1 + x) x + 20 (m^2 - Q^2 (1 - x) x)) + (
  m^2 - Q^2 (1 - x) x) (
  14 (m^2 - Q^2 (1 - x) x) + Q^2 (
    15 - 36 x + 20 x^2)) + Rational[-1, 4] (m^2 - Q^2 (1 - x) x) (
  16 m^2 + 4 Q^2 (5 - 12 x + 8 x^2)) (
  1 - 2 EulerGamma + Log[
   16] + 2 Log[Pi] + 2 Log[(m^2 - Q^2 (1 - x) x)^(-1)]) - 4 (
  m^2 - Q^2 (1 - x) x)^2 (
 2 - 3 EulerGamma + Log[
  64] + 3 Log[Pi] + 3 Log[(m^2 - Q^2 (1 - x) x)^(-1)]) - 4 m^4 (
 EulerGamma - Log[4 Pi/(m^2 - Q^2 (1 - x) x)]))
 Subscript[m, 1]^2 Subscript[m, 2]^2, Complex[0, 
Rational[1, 384]]
 Pi^(-2) ((-220) (m^2 - Q^2 (1 - x) x)^2 + 48 (
   m^2 + Q^2 (-1 + x) x)^2 - 6 (m^2 - Q^2 (1 - x) x) (
 28 m^2 + Q^2 (17 - 60 x + 44 x^2)) - 6 (m^2 - Q^2 (1 - x) x) (
 20 m^2 + Q^2 (15 - 36 x + 20 x^2)) (-1 + 2 EulerGamma - Log[
 16] - 2 Log[
  Pi] - 2 Log[(m^2 - Q^2 (1 - x) x)^(-1)]) + 56 (
   m^2 - Q^2 (1 - x) x)^2 (
  2 - 3 EulerGamma + Log[
   64] + 3 Log[
    Pi] + 3 Log[(m^2 - Q^2 (1 - x) x)^(-1)]) + Rational[1, 2] (
  m^2 - Q^2 (1 - x) x) ((-16) m^2 - 4 Q^2 (5 - 12 x + 8 x^2)) (
  6 + 6 EulerGamma^2 + Pi^2 + 24 Log[2]^2 + Log[
   4096] + 6 Log[Pi] + 24 Log[2] Log[
    Pi] + 6 Log[Pi]^2 - 6 EulerGamma (
   1 + Log[16] + 2 Log[Pi]) + 6 (
    1 - 2 EulerGamma + Log[16] + 2 Log[Pi])
     Log[(m^2 - Q^2 (1 - x) x)^(-1)] + 6 Log[(
       m^2 - Q^2 (1 - x) x)^(-1)]^2) - 12 (m^2 - Q^2 (1 - x) x)^2 (
 8 + 6 EulerGamma^2 + Pi^2 + 16 Log[2] + 24 Log[2]^2 + 8 Log[
   Pi] + 24 Log[2] Log[Pi] + 6 Log[Pi]^2 - 4 EulerGamma (
  2 + Log[64] + 3 Log[Pi]) + 4 (
   2 - 3 EulerGamma + Log[64] + 3 Log[Pi])
    Log[(m^2 - Q^2 (1 - x) x)^(-1)] + 6 Log[(
      m^2 - Q^2 (1 - x) x)^(-1)]^2) + 4 m^4 (
  6 EulerGamma^2 + Pi^2 + 24 Log[2]^2 + 24 Log[2] Log[
    Pi] + 6 Log[Pi]^2 - 12 EulerGamma Log[4 Pi] - 12 (
   EulerGamma - Log[4 Pi])
    Log[(m^2 - Q^2 (1 - x)
       x)^(-1)] + 6 Log[(m^2 - Q^2 (1 - x) x)^(-1)]^2) + 96 m^2 (
  m^2 + Q^2 (-1 + x) x) (EulerGamma - Log[
  4 Pi/(m^2 - Q^2 (1 - x) x)]))
 Subscript[m, 1]^2 Subscript[m, 2]^2}, -1, 2, 1], {x, 0, 1}, 
 Assumptions -> 
  m > 0 \[And] Q > 0 \[And] \[Epsilon] > 0 \[And] 
  m \[Element] Reals \[And] Q \[Element] Reals]
$\endgroup$
3
  • 1
    $\begingroup$ I've not looked at this in detail, but the behaviour might depend strongly on whether m^2 - Q^2 (1 - x) x is ever zero in the integration interval. Supplying conditions that ensure that it is not might help. $\endgroup$
    – mikado
    Commented Nov 13, 2023 at 22:13
  • $\begingroup$ @mikado how would I write that assumption into the integral? I am not sure about that though since I do want it to be able to go to the massless limit ($m=0$) but the ratio $m^2/Q^2 = x(1-x)\geq 0$ is true. So how would I insert that? $\endgroup$
    – MathZilla
    Commented Nov 13, 2023 at 23:31
  • $\begingroup$ Since 0<x<1 => 0<(1-x)x<1/4, I think that m>Q/2>0 could be a suitable condition. $\endgroup$
    – mikado
    Commented Nov 14, 2023 at 21:41

1 Answer 1

4
$\begingroup$
$Version

(* "13.3.1 for Mac OS X ARM (64-bit) (July 24, 2023)" *)

Clear["Global`*"]

It is more efficient to convert the SeriesData to a normal expression. For example,

series = Series[E^x, {x, 0, 4}];

Integrate[series, {x, 0, 1}] // RepeatedTiming

(* {0.0680269, 103/60} *)

Integrate[series // Normal, {x, 0, 1}] // RepeatedTiming

(* {0.0000175881, 103/60} *)

Your integrand as a normal expression is

integrand = 
  SeriesData[ϵ, 
    0, {Complex[0, 
       Rational[1, 4]] Pi^(-2) (2 m^4 - 
        4 m^2 (m^2 - Q^2 (1 - x) x) - (m^2 - 
           Q^2 (1 - x) x) (6 (m^2 - Q^2 (1 - x) x) + 
           Q^2 (5 - 12 x + 8 x^2))) Subscript[m, 1]^2 Subscript[m, 2]^2, 
     Complex[0, 
       Rational[1, 16]] Pi^(-2) ((-8) m^4 + 
        m^2 ((-8) Q^2 (-1 + x) x + 20 (m^2 - Q^2 (1 - x) x)) + (m^2 - 
           Q^2 (1 - x) x) (14 (m^2 - Q^2 (1 - x) x) + 
           Q^2 (15 - 36 x + 20 x^2)) + 
        Rational[-1, 
          4] (m^2 - Q^2 (1 - x) x) (16 m^2 + 4 Q^2 (5 - 12 x + 8 x^2)) (1 - 
           2 EulerGamma + Log[16] + 2 Log[Pi] + 
           2 Log[(m^2 - Q^2 (1 - x) x)^(-1)]) - 
        4 (m^2 - Q^2 (1 - x) x)^2 (2 - 3 EulerGamma + Log[64] + 3 Log[Pi] + 
           3 Log[(m^2 - Q^2 (1 - x) x)^(-1)]) - 
        4 m^4 (EulerGamma - Log[4 Pi/(m^2 - Q^2 (1 - x) x)])) Subscript[m, 
        1]^2 Subscript[m, 2]^2, 
     Complex[0, 
       Rational[1, 384]] Pi^(-2) ((-220) (m^2 - Q^2 (1 - x) x)^2 + 
        48 (m^2 + Q^2 (-1 + x) x)^2 - 
        6 (m^2 - Q^2 (1 - x) x) (28 m^2 + Q^2 (17 - 60 x + 44 x^2)) - 
        6 (m^2 - Q^2 (1 - x) x) (20 m^2 + Q^2 (15 - 36 x + 20 x^2)) (-1 + 
           2 EulerGamma - Log[16] - 2 Log[Pi] - 
           2 Log[(m^2 - Q^2 (1 - x) x)^(-1)]) + 
        56 (m^2 - Q^2 (1 - x) x)^2 (2 - 3 EulerGamma + Log[64] + 3 Log[Pi] + 
           3 Log[(m^2 - Q^2 (1 - x) x)^(-1)]) + 
        Rational[1, 
          2] (m^2 - Q^2 (1 - x) x) ((-16) m^2 - 
           4 Q^2 (5 - 12 x + 8 x^2)) (6 + 6 EulerGamma^2 + Pi^2 + 
           24 Log[2]^2 + Log[4096] + 6 Log[Pi] + 24 Log[2] Log[Pi] + 
           6 Log[Pi]^2 - 6 EulerGamma (1 + Log[16] + 2 Log[Pi]) + 
           6 (1 - 2 EulerGamma + Log[16] + 
              2 Log[Pi]) Log[(m^2 - Q^2 (1 - x) x)^(-1)] + 
           6 Log[(m^2 - Q^2 (1 - x) x)^(-1)]^2) - 
        12 (m^2 - Q^2 (1 - x) x)^2 (8 + 6 EulerGamma^2 + Pi^2 + 16 Log[2] + 
           24 Log[2]^2 + 8 Log[Pi] + 24 Log[2] Log[Pi] + 6 Log[Pi]^2 - 
           4 EulerGamma (2 + Log[64] + 3 Log[Pi]) + 
           4 (2 - 3 EulerGamma + Log[64] + 
              3 Log[Pi]) Log[(m^2 - Q^2 (1 - x) x)^(-1)] + 
           6 Log[(m^2 - Q^2 (1 - x) x)^(-1)]^2) + 
        4 m^4 (6 EulerGamma^2 + Pi^2 + 24 Log[2]^2 + 24 Log[2] Log[Pi] + 
           6 Log[Pi]^2 - 12 EulerGamma Log[4 Pi] - 
           12 (EulerGamma - Log[4 Pi]) Log[(m^2 - Q^2 (1 - x) x)^(-1)] + 
           6 Log[(m^2 - Q^2 (1 - x) x)^(-1)]^2) + 
        96 m^2 (m^2 + Q^2 (-1 + x) x) (EulerGamma - 
           Log[4 Pi/(m^2 - Q^2 (1 - x) x)])) Subscript[m, 1]^2 Subscript[m, 
        2]^2}, -1, 2, 1] // Normal;

Simplify the integrand prior to integrating

LeafCount /@ {integrand, integrand2 = integrand // Simplify}

(* {954, 787} *)

Expand the integrand into a sum and integrate term-by-term

integrand2 // Expand // Head

(* Plus *)

The integration is quite slow: (* leave out the Short to see the full result *)

(int = Assuming[
     m > 0 ∧ Q > 0 ∧ ϵ > 0 ∧ 
      m ∈ Reals ∧ Q ∈ Reals,
     Simplify[Integrate[#, {x, 0, 1}] & /@ (integrand2 // Expand)]]) // 
  Short[#, 20] & // AbsoluteTiming

enter image description here

Including the given conditions in the assumptions improves the timing; however, the integration is still quite slow,

(int2 = Assuming[
     m > 0 ∧ Q > 0 ∧ ϵ > 0 ∧ 
      m ∈ Reals ∧ Q ∈ Reals && 
      2*m > Q && (Q <= Re[Sqrt[-4*m^2 + Q^2]] || 
        NotElement[Sqrt[-4*m^2 + Q^2], Reals]),
     Simplify[Integrate[#, {x, 0, 1}] & /@ 
  (integrand2 // Expand)]]) // 
  Short[#, 20] & // AbsoluteTiming

enter image description here

However, the quicker result increases the LeafCount:

LeafCount /@ {int, int2}

(* {8282, 9495} *)
$\endgroup$
3
  • $\begingroup$ Is there a way to expand the $\log(m^2-Q^2x(1-x))$ within Mathematica such that I get the following output, $\log(1-(Q/m)^2x(1-x)) + log(m^2)$ or for those of with the inverse inside the log, write it as $\log(1/(m^2 - Q^2x(1-x)) = -\log(m^2 - Q^2x(1-x))$? Or would this not even help the situation? $\endgroup$
    – MathZilla
    Commented Nov 14, 2023 at 4:31
  • $\begingroup$ Also, when I put this on my bigger computer, it does the entire integral in about 1 minute. The condition Mathematica puts on the integral is that $2m>Q$ and $Q\leq Re[\sqrt{-4m^2+Q^2}]$. $\endgroup$
    – MathZilla
    Commented Nov 14, 2023 at 4:40
  • 1
    $\begingroup$ Since Assuming[m > 0 && Q > 0, Log[m^2 - Q^2 x (1 - x)] == Log[m^2*(1 - (Q/m)^2 x (1 - x))] // Simplify] evaluates to True; just define rule = Log[m^2*(1 - (Q/m)^2 x (1 - x))] :> Log[1 - (Q/m)^2 x (1 - x)] + Log[m^2]; and use expr /. rule as required. $\endgroup$
    – Bob Hanlon
    Commented Nov 14, 2023 at 6:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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