Page 1 of 1

Possible Bug in LoopFunction with controlmdiff?

Posted: 5. Feb 2018, 13:15
by JPEllis
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

Re: Possible Bug in LoopFunction with controlmdiff?

Posted: 6. Feb 2018, 13:26
by FStaub
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