pyhypergeomatrix
Hypergeometric functions of a matrix argument.
Evaluation of the hypergeometric function of a matrix argument (Koev & Edelman's algorithm)
Let $(a_1, \ldots, a_p)$ and $(b_1, \ldots, b_q)$ be two vectors of real or complex numbers, possibly empty, $\alpha > 0$ and $X$ a real symmetric or a complex Hermitian matrix. The corresponding hypergeometric function of a matrix argument is defined by
$${}_pF_q^{(\alpha)} \left(\begin{matrix} a_1, \ldots, a_p \\ b_1, \ldots, b_q\end{matrix}; X\right) = \sum_{k=0}^{\infty}\sum_{\kappa \vdash k} \frac{{(a_1)}_{\kappa}^{(\alpha)} \cdots {(a_p)}_{\kappa}^{(\alpha)}} {{(b_1)}_{\kappa}^{(\alpha)} \cdots {(b_q)}_{\kappa}^{(\alpha)}} \frac{C_{\kappa}^{(\alpha)}(X)}{k!}.$$
The inner sum is over the integer partitions $\kappa$ of $k$ (which we also denote by $|\kappa| = k$). The symbol ${(\cdot)}_{\kappa}^{(\alpha)}$ is the generalized Pochhammer symbol, defined by
$${(c)}^{(\alpha)}_{\kappa} = \prod_{i=1}^{\ell}\prod_{j=1}^{\kappa_i} \left(c - \frac{i-1}{\alpha} + j-1\right)$$
when $\kappa = (\kappa_1, \ldots, \kappa_\ell)$. Finally, $C_{\kappa}^{(\alpha)}$ is a Jack function. Given an integer partition $\kappa$ and $\alpha > 0$, and a real symmetric or complex Hermitian matrix $X$ of order $n$, the Jack function
$$C_{\kappa}^{(\alpha)}(X) = C_{\kappa}^{(\alpha)}(x_1, \ldots, x_n)$$
is a symmetric homogeneous polynomial of degree $|\kappa|$ in the eigen values $x_1$, $\ldots$, $x_n$ of $X$.
The series defining the hypergeometric function does not always converge. See the references for a discussion about the convergence.
The inner sum in the definition of the hypergeometric function is over all partitions $\kappa \vdash k$ but actually $C_{\kappa}^{(\alpha)}(X) = 0$ when $\ell(\kappa)$, the number of non-zero entries of $\kappa$, is strictly greater than $n$.
For $\alpha=1$, $C_{\kappa}^{(\alpha)}$ is a Schur polynomial and it is a zonal polynomial for $\alpha = 2$. In random matrix theory, the hypergeometric function appears for $\alpha=2$ and $\alpha$ is omitted from the notation, implicitely assumed to be $2$.
Koev and Edelman (2006) provided an efficient algorithm for the evaluation of the truncated series
$$\sideset{_p^m}{_q^{(\alpha)}}F \left(\begin{matrix} a_1, \ldots, a_p \\ b_1, \ldots, b_q\end{matrix}; X\right) = \sum_{k=0}^{m}\sum_{\kappa \vdash k} \frac{{(a_1)}_{\kappa}^{(\alpha)} \cdots {(a_p)}_{\kappa}^{(\alpha)}} {{(b_1)}_{\kappa}^{(\alpha)} \cdots {(b_q)}_{\kappa}^{(\alpha)}} \frac{C_{\kappa}^{(\alpha)}(X)}{k!}.$$
Hereafter, $m$ is called the truncation weight of the summation (because $|\kappa|$ is called the weight of $\kappa$), the vector $(a_1, \ldots, a_p)$ is called the vector of upper parameters while the vector $(b_1, \ldots, b_q)$ is called the vector of lower parameters. The user has to supply the vector $(x_1, \ldots, x_n)$ of the eigenvalues of $X$.
For example, to compute
$$\sideset{_2^{15}}{_3^{(2)}}F \left(\begin{matrix} 3, 4 \\ 5, 6, 7\end{matrix}; 0.1, 0.4\right)$$
you have to enter
>>> from pyhypergeomatrix.hypergeomat import hypergeomPQ
>>> hypergeomPQ(15, [3, 4], [5, 6, 7], [0.1, 0.4], 2)
We said that the hypergeometric function is defined for a real symmetric
matrix or a complex Hermitian matrix $X$. Thus the eigenvalues of $X$
are real. However we do not impose this restriction in pyhypergeomatrix.
The user can enter any list of real or complex numbers for the eigenvalues.
Univariate case
For $n = 1$, the hypergeometric function of a matrix argument is known as the generalized hypergeometric function. It does not depend on $\alpha$. The case of $\sideset{_{2\thinspace}^{}}{_1^{}}F$ is the most known, this is the Gauss hypergeometric function. Let's check a value. It is known that
$$\sideset{_{2\thinspace}^{}}{_1^{}}F \left(\begin{matrix} 1/4, 1/2 \\ 3/4\end{matrix}; 80/81\right) = 1.8.$$
Since $80/81$ is close to $1$, the convergence is slow. We compute the truncated series below for $m = 300$.
>>> from pyhypergeomatrix.hypergeomat import hypergeomPQ
>>> hypergeomPQ(300, [1/4, 1/2], [3/4], [80/81])
1.79900265281923
References
-
Plamen Koev and Alan Edelman. The efficient evaluation of the hypergeometric function of a matrix argument. Mathematics of computation, vol. 75, n. 254, 833-846, 2006.
-
Robb Muirhead. Aspects of multivariate statistical theory. Wiley series in probability and mathematical statistics. Probability and mathematical statistics. John Wiley & Sons, New York, 1982.
-
A. K. Gupta and D. K. Nagar. Matrix variate distributions. Chapman and Hall, 1999.
Metadata
Release files for pyhypergeomatrix 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| pyhypergeomatrix-0.1.0.tar.gz | 17.7 kB | Without provenance | Details for pyhypergeomatrix-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pyhypergeomatrix-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for pyhypergeomatrix-0.1.0-py3-none-any.whl |
Total release size: 35.7 kB
Release files / pyhypergeomatrix-0.1.0.tar.gz
| Download URL | pyhypergeomatrix-0.1.0.tar.gz |
|---|---|
| Size | 17.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ef5e8e102fbced76101d46273f3bf8cfc3797f9f1ad8e4fc049cc725bf4cd8c0
|
|
BLAKE2b-256 checksum How to use checksums |
7869f0878d287f5c722c73373059a8c98a637c0f056aced743b559d6422a71d3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.7.0 CPython/3.10.5 Windows/10
|
Release files / pyhypergeomatrix-0.1.0-py3-none-any.whl
| Download URL | pyhypergeomatrix-0.1.0-py3-none-any.whl |
|---|---|
| Size | 17.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
14899bbaeee021f85bac72b3c2ff91b039e08235b1389a199643b3591de94d9a
|
|
BLAKE2b-256 checksum How to use checksums |
dc225ba9c2275195fa6647da5a6c67082bf72563878d0d3af91daf62ffd0a37c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.7.0 CPython/3.10.5 Windows/10
|
Security for pyhypergeomatrix 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.