Possible Bug in LoopFunction with controlmdiff?

Report the bugs you found
Post Reply
JPEllis
Posts: 71
Joined: 28. Apr 2016, 10:34

Possible Bug in LoopFunction with controlmdiff?

Post by JPEllis » 5. Feb 2018, 13:15

Hi,

In the AddLoopFunctions file, you have:

Code: Select all

Real(dp), Private :: controlmdiff = 1.0e-15_dp !controls the mass difference
                                               !when comparing two masses
which is, I presume, to avoid divergences which might occur when two masses are too close together. (If not, then disregard the rest of this post).

The issue appears later when the mass splitting is calculated. Instead of the usual mass splitting, it is normalized it:

Code: Select all

     If (xm1.Ne.0._dp) Then
        mdiff = Abs((xm1-xm2)/xm1) !to avoid problems when comparing xm1 with xm2
     Else If (xm2.Ne.0._dp) Then
        mdiff = Abs((xm1-xm2)/xm2)
     Else
        mdiff = 0._dp
     End If
The problem is that if both xm1 and xm2 are both of order controlmdiff (or smaller), then this normalized mass difference will in fact be much larger than controlmdiff.

I encountered the issue when I had xm1 = 0 (for a massless fermion), and xm2 = 1e-20 (for a photon, which is just equal to Mass_Regulator_PhotonGluon**2). This resulted in controlmdiff being equal to 1 which the algorithm then clearly deemed to be safe.

Furthermore, the SA_ variant of the loop function (which I presume means safe? The code has no comments :/ ) doesn't catch the error because it only checks if the masses are exactly zero. Perhaps it should check if the mass is less than controlmdiff?

Josh
Joshua Ellis jpellis.me

FStaub
Site Admin
Posts: 822
Joined: 13. Apr 2016, 14:05

Re: Possible Bug in LoopFunction with controlmdiff?

Post by FStaub » 6. Feb 2018, 13:26

Hi,

I agree. A better check should read

Code: Select all

If (xp.Eq.0._dp) Then
    If (xm1.ge.controlmdiff) Then
    mdiff = Abs((xm1-xm2)/xm1) !to avoid problems when comparing xm1 with xm2
    Else If (xm2.ge.controlmdiff) Then
    mdiff = Abs((xm1-xm2)/xm2)
    Else
    mdiff = 0._dp
    End If
   If ((mdiff.Le.controlmdiff).And.(xm1.le.controlmdiff)) Then !xp=xm1=xm2=0
    write(ErrCan,*) "DerB1(0,0,0) diverges!"
 
Do you agree?

Cheers,
Florian

Post Reply