The Meijer G function $G^{m,n}_{p,q}\left(\begin{matrix}(a_1,\dots,a_p) \\ (b_1,\dots ,b_q)\end{matrix}\bigg|~z\right)$ is defined via a certain contour integral in the complex plane. In this definition, it is stated that for $k\in\{1,\dots,n\}$ and $j\in\{1,\dots,m\}$, that $a_k-b_j$ cannot be a positive integer, as that would cause the poles in the integrand to coincide.

But, this doesn't seem to stop Mathematica from evaluating it. For instance, when writing this question I was dealing with $$G^{2,1}_{1,4}\left(\begin{matrix} (1) \\ (0,1,\frac{1}{2},1)\end{matrix}\bigg|~z\right)$$ We see clearly that $a_1-b_1=1$ which is a positive integer. So, this instance of the Meijer G shouldn't be defined, according to DLMF and Wikipedia. But my version of Mathematica has absolutely no problems with it, see:


This appears to me like some sort of analytic continuation. For instance, in the original definition of the Riemann zeta function, $\zeta(-1)$ should not be defined (it is a divergent sum). But using the functional equation $$\zeta(1-s)=2\Gamma(s)(2\pi)^{-s}\cos(\pi s/2)\zeta(s)$$ We can obtain $\zeta(-1)=-1/12$.

Is something similar happening with the Meijer G? If so, what? What continuation formula is Mathematica using?

Or perhaps the poles coinciding is really no big deal and it can be evaluated anyway?

I am very confused. Would appreciate some help.


I picked a bad example. In this case the $G^{2,1}_{1,4}$ could be reduced to a $G^{2,0}_{0,3}$ via the cancellation identity, i.e $$G^{2,1}_{1,4}\left(\begin{matrix}(a)\\(0,1,\frac{1}{2},a)\end{matrix}\bigg|~z\right)=G^{2,0}_{0,3}\left(\begin{matrix}-\\(0,1,\frac{1}{2})\end{matrix}\bigg|~z\right)$$ Which doesn't break any rules so can be evaluated without any issues. But if I pick a case where the cancellation identity can't be used, like $$G^{2,1}_{1,4}\left(\begin{matrix}(2)\\(0,1,\frac{1}{2},1)\end{matrix}\bigg|~z\right)$$ Mathematica (expectedly!) throws an error:

error output

So there are no discrepancies with the definitions listed on DLMF, Wikipedia, etc and the numeric implementation in Mathematica.

(I have crossposted this on Mathematics SE as well.)

  • $\begingroup$ Cross-posting is usually not a good idea, please see this. $\endgroup$
    – user293787
    Sep 14, 2022 at 15:13

1 Answer 1


The input


of type $G^{2,1}_{1,4}$ evaluates to


of type $G^{2,0}_{0,3}$. This is a special case of the first identity under basic properties of the $G$-function on Wikipedia, which is also a direct consequence of the definition of the $G$-function.

OPs example is a=1 and {u,v,w} = {0,1,1/2}.

  • $\begingroup$ See also MeijerG[{{},{}},{{u,v},{w}},z]//FunctionExpand. $\endgroup$
    – user293787
    Sep 14, 2022 at 15:21

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.