I want to calculate the inverse Mellin transform of products of 3 gamma functions. $$F\left ( s \right )=\frac{1}{2i\pi}\int \Gamma(s)\Gamma (2s+a)\Gamma( 2s+b)x^{-s}ds$$ Above contour integral has 3 poles. $$s_{1}=-n$$ $$s_{2}=-\left ( \frac{n+a}{2} \right )$$ $$s_{3}=-\left ( \frac{n+b}{2} \right )$$ Which pole is used in contour integral? $$F\left ( s \right )=\sum_{n=0}^{\infty }\frac{\left ( -1 \right )^{n}}{n!}\Gamma \left ( a-2n \right )\Gamma \left ( -2n+b \right )x^{n}+\sum_{n=0}^{\infty}\frac{\left ( -1 \right )^{n}}{n!}\Gamma \left ( -\frac{n}{2}-\frac{a}{2} \right)\Gamma \left ( -n-a+b\right )x^{\frac{n}{2}+\frac{a}{2}}+\sum_{n=0}^{\infty}\frac{(-1)^{n}}{n!}\Gamma \left (-\frac{n}{2}-\frac{b}{2} \right )\Gamma (-n-b+a)x^{\frac{n}{2}+\frac{b}{2}}$$ Is this correct??

  • $\begingroup$ this is almost correct, you missed factors 1/2 in the second and third sum, see below. $\endgroup$ Commented Apr 22, 2022 at 11:27

2 Answers 2


To avoid all poles in the Mellin inversion formula you want to integrate along the line $\int_{\gamma-i\infty}^{\gamma+i\infty}ds$ where $\gamma>\max(0,-a/2,-b/2)$; then Mathematica gives the result in terms of the Meijer G-function:

\begin{align} F( x )=&\frac{1}{2i\pi}\int_{\gamma-i\infty}^{\gamma+i\infty} \Gamma(s)\Gamma (2s+a)\Gamma( 2s+b)x^{-s}\,ds\\ =&\frac{1}{\pi}2^{a+b-2} G_{0,5}^{5,0}\left(\frac{x}{16}| \begin{array}{c} 0,\frac{a}{2},\frac{a+1}{2},\frac{b}{2},\frac{b+1}{2} \\ \end{array} \right). \end{align} The integral can alternatively be evaluated by contour integration, closing the contour in the left-half complex plane and picking up the poles at $-n$, $-(n+a)/2$, $-(n+b)/2$, $n=0,1,2,\ldots$. For this we assume that $a\neq b$ and $a,b$ are both non-integer --- so that all poles are simple. I then find that

\begin{align} F(x)=&\sum_{n=0}^{\infty }\frac{\left ( -1 \right )^{n}}{n!}\Gamma \left ( a-2n \right )\Gamma \left ( -2n+b \right )x^{n}\\ &+\frac{1}{2}\sum_{n=0}^{\infty}\frac{\left ( -1 \right )^{n}}{n!}\Gamma \left ( -\frac{n}{2}-\frac{a}{2} \right)\Gamma \left ( -n-a+b\right )x^{\frac{n}{2}+\frac{a}{2}}\\ &+\frac{1}{2}\sum_{n=0}^{\infty}\frac{(-1)^{n}}{n!}\Gamma \left (-\frac{n}{2}-\frac{b}{2} \right )\Gamma (-n-b+a)x^{\frac{n}{2}+\frac{b}{2}}. \end{align} I checked numerically that this agrees with the Meijer G-function result -- it differs from the result in the OP by factors 1/2 in the second and third sum.

  • $\begingroup$ I don't understand your answer. Can you explain for me what did you do? $\endgroup$
    – Pouya
    Commented Apr 21, 2022 at 19:43
  • $\begingroup$ I applied the Mellin inversion formula to the line $\text{Re}\,s=\gamma$ that avoids the three poles you noted in your post; the integral is then evaluated by Mathematica $\endgroup$ Commented Apr 21, 2022 at 19:46
  • 1
    $\begingroup$ I do not want to use Mathematica or any computing software. I want it to be calculated manually. $\endgroup$
    – Pouya
    Commented Apr 21, 2022 at 19:51
  • $\begingroup$ I want to know which poles is used? Any 3 poles? $\endgroup$
    – Pouya
    Commented Apr 21, 2022 at 19:57
  • $\begingroup$ @Pouya --- OK, I also calculated the result "manually", as requested; all poles contribute to the contour integral. $\endgroup$ Commented Apr 22, 2022 at 11:26

This answer is intended to provide additional insight into the initial answer posted by Carlo Beenakker.

The MeijerG function is defined as

$$\text{MeijerG}\left[\{\{a_1..a_n\},\{a_{n+1}..a_p\}\},\{\{b_1..b_m\},\{b_{m+1}..b_q\}\},z,r\right]$$ $$=\frac{r}{2 \pi i} \int \frac{\left(\left(\prod\limits_{i=1}^n \Gamma(1-a_i-r s)\right) \prod\limits_{i=1}^m \Gamma(b_i+r s)\right)}{\left(\prod\limits_{i=n+1}^p \Gamma(a_i+r s)\right) \prod\limits_{i=m+1}^q \Gamma(1-b_i-r s)} z^{-s} \, ds\tag{1}$$

and with the default $r=1$ this becomes

$$\text{MeijerG}\left[\{\{a_1..a_n\},\{a_{n+1}..a_p\}\},\{\{b_1..b_m\},\{b_{m+1}..b_q\}\},z\right]$$ $$=G_{p, q}^{m, n}\left(z\left| \begin{array}{c} a_1 \text{..} a_p \\ b_1 \text{..} b_q \\ \end{array} \right.\right)$$ $$=\frac{1}{2 \pi i} \int \frac{\left(\left(\prod\limits_{i=1}^n \Gamma(1-a_i-s)\right) \prod\limits_{i=1}^m \Gamma(b_i+s)\right)}{\left(\prod\limits_{i=n+1}^p \Gamma(a_i+s)\right) \prod\limits_{i=m+1}^q \Gamma(1-b_i-s)} z^{-s} \, ds\tag{2}$$

From the definition above it can be seen that

$$f(x)=\frac{1}{\pi}\ 2^{a+b-2}\ G_{0,5}^{5,0}\left(\frac{x}{16}| \begin{array}{c} 0,\frac{a}{2},\frac{a+1}{2},\frac{b}{2},\frac{b+1}{2} \\ \end{array} \right)$$ $$=\frac{1}{\pi} 2^{a+b-2} \frac{1}{2 \pi i}\int \Gamma(s+0)\ \Gamma\left(\frac{a}{2}+s\right)\ \Gamma\left(\frac{a+1}{2}+s\right)\ \Gamma\left(\frac{b}{2}+s\right)\ \Gamma\left(\frac{b+1}{2}+s\right) \left(\frac{x}{16}\right)^{-s} \, ds$$ $$=\frac{1}{2 \pi i} \int \Gamma(s)\ \Gamma(a+2 s)\ \Gamma(b+2 s)\ x^{-s} \, ds\tag{3}$$

Mathematica also gives the following result for the inverse Mellin transform

$$f(x)=\mathcal{M}_s^{-1}[\Gamma(s)\ \Gamma(a+2 s)\ \Gamma(b+2 s)](x)\tag{4}$$ $$=\frac{1}{2 \pi i} \int \Gamma(s)\ \Gamma(2s+a)\ \Gamma(2s+b)\ x^{-s}\,ds$$ $$=\pi ^3 2^{-a-b-4} \left(4^{a+b+2} \csc (\pi a) \csc (\pi b) \, _0\tilde{F}_4\left(;\frac{1}{2}-\frac{a}{2},1-\frac{a}{2},\frac{1}{2}-\frac{b}{2},1-\frac{b}{2};-\frac{x}{16}\right)-2 \csc (\pi (b-a)) \left(4^{b+1} x^{a/2} \csc \left(\frac{\pi a}{2}\right) \, _0\tilde{F}_4\left(;\frac{a+2}{2},\frac{1}{2},\frac{1}{2} (a-b+1),\frac{1}{2} (a-b+2);-\frac{x}{16}\right)-4^{a+1} x^{b/2} \csc \left(\frac{\pi b}{2}\right) \, _0\tilde{F}_4\left(;\frac{b+2}{2},\frac{1}{2} (-a+b+1),\frac{1}{2} (-a+b+2),\frac{1}{2};-\frac{x}{16}\right)+4^b x^{\frac{a+1}{2}} \sec \left(\frac{\pi a}{2}\right) \, _0\tilde{F}_4\left(;\frac{a+3}{2},\frac{3}{2},\frac{1}{2} (a-b+2),\frac{1}{2} (a-b+3);-\frac{x}{16}\right)-4^a x^{\frac{b+1}{2}} \sec \left(\frac{\pi b}{2}\right) \, _0\tilde{F}_4\left(;\frac{b+3}{2},\frac{1}{2} (-a+b+2),\frac{1}{2} (-a+b+3),\frac{3}{2};-\frac{x}{16}\right)\right)\right)$$

which is valid for $\max\left(0,-\frac{a}{2},-\frac{b}{2}\right)<\Re(s)$.

Mathematica also expands the MeijerG result as follows.

$$f(x)=\frac{1}{\pi }\ 2^{a+b-2}\ G_{0,5}^{5,0}\left(\frac{x}{16}| \begin{array}{c} 0,\frac{a}{2},\frac{a+1}{2},\frac{b}{2},\frac{b+1}{2} \\ \end{array} \right)=\tag{5}$$ $$\frac{\pi ^2 x^{a/2} \csc \left(\frac{\pi a}{2}\right) \csc \left(\frac{1}{2} \pi (a-b)\right) \sec \left(\frac{1}{2} \pi (a-b)\right) \, _0F_4\left(;\frac{1}{2},\frac{a}{2}+1,\frac{a}{2}-\frac{b}{2}+\frac{1}{2},\frac{a}{2}-\frac{b}{2}+1;-\frac{x}{16}\right)}{4 \Gamma \left(\frac{a}{2}+1\right) \Gamma (a-b+1)}-\frac{\pi ^2 x^{b/2} \csc \left(\frac{\pi b}{2}\right) \csc \left(\frac{\pi a}{2}-\frac{\pi b}{2}\right) \sec \left(\frac{1}{2} \pi (a-b)\right) \, _0F_4\left(;\frac{1}{2},\frac{b}{2}+1,-\frac{a}{2}+\frac{b}{2}+\frac{1}{2},-\frac{a}{2}+\frac{b}{2}+1;-\frac{x}{16}\right)}{4 \Gamma \left(\frac{b}{2}+1\right) \Gamma (-a+b+1)}+\frac{\pi ^2 x^{\frac{a+1}{2}} \sec \left(\frac{\pi a}{2}\right) \csc \left(\frac{1}{2} \pi (a-b)\right) \sec \left(\frac{1}{2} \pi (a-b)\right) \, _0F_4\left(;\frac{3}{2},\frac{a}{2}+\frac{3}{2},\frac{a}{2}-\frac{b}{2}+1,\frac{a}{2}-\frac{b}{2}+\frac{3}{2};-\frac{x}{16}\right)}{4 \Gamma \left(\frac{a}{2}+\frac{3}{2}\right) \Gamma (a-b+2)}-\frac{\pi ^2 x^{\frac{b+1}{2}} \sec \left(\frac{\pi b}{2}\right) \csc \left(\frac{\pi a}{2}-\frac{\pi b}{2}\right) \sec \left(\frac{1}{2} \pi (a-b)\right) \, _0F_4\left(;\frac{3}{2},\frac{b}{2}+\frac{3}{2},-\frac{a}{2}+\frac{b}{2}+1,-\frac{a}{2}+\frac{b}{2}+\frac{3}{2};-\frac{x}{16}\right)}{4 \Gamma \left(\frac{b}{2}+\frac{3}{2}\right) \Gamma (-a+b+2)}+\frac{\pi ^2 \csc \left(\frac{\pi a}{2}\right) \csc \left(\frac{1}{2} \pi (a+1)\right) \csc \left(\frac{\pi b}{2}\right) \csc \left(\frac{1}{2} \pi (b+1)\right) \, _0F_4\left(;\frac{1}{2}-\frac{a}{2},1-\frac{a}{2},\frac{1}{2}-\frac{b}{2},1-\frac{b}{2};-\frac{x}{16}\right)}{4 \Gamma (1-a) \Gamma (1-b)}$$


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.