Contour Integration over complex function

Dear all,

I need to calculate the following integral (please see the attached pdf file). The integrand contains gamma functions of complex variable. There are 2D integration and 2D summation. Free parameters are \alpha_i, \beta_i (i=1,2).

I need to obtain a numerical value of this integral at some values of \alpha_i and \beta_i.

Is there any possibility to integrate such an integrand?

Any help will be appreciated.

Thank you!
amp.pdf (25.7 KB)

Dear all again,

Are complex numbers defined in ROOT? Operation with complex numbers, calculations, e.t.c.

Any help/link will be appreciated.

Andrey.

root [0] #include <complex>
root [1] complex<double> x;
root [2] cout << x << endl;
(0,0)
root [3] complex<double> y(11,22);
root [4] cout << y << endl;
(11,22)
root [5] arg(y)
(double)1.10714871779409041e+00
root [6] log10(y)
(21const complex<double>)(1.39088,0.480829)
root [7] sin(y)
(21const complex<double>)(-29935.9,-264.982)

For the “interpreted code”, see files returned by:

find ${ROOTSYS} -name "*complex*"

In particular “${ROOTSYS}/cint/cint/include/_complex.h” (in ROOT 5), for example.

For the “(pre)compiled code”, you can use whatever your compiler / libraries provide.

Thank you!

One more question. Are math. functions could be used with complex variable? For example: Cos(1+2i), Gamma(1-5i), e.t.c. If it is not straightforward, how it could be implemented?

Best regards,

Is there any possible way to perform integration and return a complex number?

(Here is a short code of desired integral)

In other words, can I pass :

complex<double> integrand(double *var, double *par)
{
    complex<double> c1(var[0], par[0]);   // integration runs over the real variable (double) and imag. part    
                                                            //  remains  unchanged. 

    return TMath::Exp(-c1);                     // The result is also complex number.
}

to the integrator (for example, TF1,simple one dim integral)

        TF1 *func = new TF1("qqq",integrand, 0,10,2);  // integration from 0 to 10
	func->SetParameters(par1, par2);  //whatever parameters
	complex<double> res = (func->Integral(0,10));   // the result is a complex number

Many thanks!

Hi,

Complex mathematical function and also their integration in the complex space is not currently supported in ROOT. You might need to use a software package like Mathematica,

Best Regards

Lorenzo

Simple complex functions (like “cos”) can immediately be accessed from the interpreter:

root [0] #include <complex>
root [1] cos(complex<double> (1,2))
(21const complex<double>)(2.03272,-3.0519)

“Advanced” complex functions (like “gamma”) are not implemented (in ROOT 5).
You need to (pre)compile your code and use an external library which provides them (e.g. CERNLIB).

Thank you for your suggestions and help!