Efficient numerical computation of the Pfaffian for dense and banded skew-symmetric matrices.
Project description
pfapack
: Efficient numerical computation of the Pfaffian for dense and banded skew-symmetric matrices
Code and algorithms are taken from arXiv:1102.3440 which is authored by Michael Wimmer.
Install
pip install pfapack
Usage
from pfapack import pfaffian as pf
import numpy.matlib
# first real matrices
A = numpy.matlib.rand(100, 100)
A = A - A.T
pfa1 = pf.pfaffian(A)
pfa2 = pf.pfaffian(A, method="H")
pfa3 = pf.pfaffian_schur(A)
print(pfa1, pfa2, pfa3)
License
MIT License
Contributions
- Bas Nijholt
- Michael Wimmer (author of the algorithms)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pfapack-0.1.0.dev0.tar.gz
(12.3 kB
view hashes)
Built Distribution
Close
Hashes for pfapack-0.1.0.dev0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6775ce76a7289b1d3019bc5f930ceb166b5175e3323a988255a4476678122e35 |
|
MD5 | 4a47bbc2436da58fdcb8cbd1748a7e04 |
|
BLAKE2b-256 | 4a80664e747bc0bed56a9cc019bca0ff5a75ed095cda8a2995fe385e8fbd2941 |