pentapy: A toolbox for pentadiagonal matrizes.
Project description
Welcome to pentapy
Purpose
pentapy is a toolbox to deal with pentadiagonal matrices in Python.
Installation
The package can be installed via pip. On Windows you can install WinPython to get Python and pip running.
pip install pentapy
References
The solver is based on the algorithms PTRANS-I and PTRANS-II presented by Askar et al. 2015.
Examples
Solving a pentadiagonal linear equation system
This is an example of how to solve a LES with a pentadiagonal matrix.
import numpy as np
from pentapy import solve
size = 1000
# create a flattened pentadiagonal matrix
M_flat = (np.random.random((5, size)) - 0.5) * 1e-5
V = np.random.random(size) * 1e5
# solve the LES
X = solve(M_flat, V, is_flat=True)
# create the corresponding matrix for checking
M = (
np.diag(M_flat[0, :-2], 2)
+ np.diag(M_flat[1, :-1], 1)
+ np.diag(M_flat[2, :], 0)
+ np.diag(M_flat[3, 1:], -1)
+ np.diag(M_flat[4, 2:], -2)
)
# calculate the error
print(np.max(np.abs(np.dot(M, X) - V)))
This should give something like:
4.257890395820141e-08
Requirements:
Contact
You can contact us via info@geostat-framework.org.
License
GPL © 2019
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
Built Distributions
File details
Details for the file pentapy-0.1.0.tar.gz
.
File metadata
- Download URL: pentapy-0.1.0.tar.gz
- Upload date:
- Size: 120.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/38.2.4 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | cf300596716829edbbc5a6ecf52a497fcec0e3a18e222b999b8d401dee1ed0da |
|
MD5 | 4d1331b0014fc308002f6a9acf2ef283 |
|
BLAKE2b-256 | b0ddb2a9a18516d49660f8d301a8feba834896c5c0bb78061c6499829caf5d53 |
Provenance
File details
Details for the file pentapy-0.1.0-cp36-cp36m-win_amd64.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp36-cp36m-win_amd64.whl
- Upload date:
- Size: 196.5 kB
- Tags: CPython 3.6m, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b5d0b92e1ef88bb2d85a6a7937e1ae8e1db2bf18befa2c5c1332b729c39ce8f0 |
|
MD5 | 0c27ab08c156a4e3d4c918bfba744c60 |
|
BLAKE2b-256 | 08f2c479f9b05bf48383fd69b0b4345cf84b3b51ea8cbd15f0324c0828ec019a |
Provenance
File details
Details for the file pentapy-0.1.0-cp36-cp36m-win32.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp36-cp36m-win32.whl
- Upload date:
- Size: 185.3 kB
- Tags: CPython 3.6m, Windows x86
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7206adcec46f6250488cf055e096ce2c13e31d606e054c7ced1ff2ed37ad77ad |
|
MD5 | 2de0034e0ed2372b6069f213b8cb7922 |
|
BLAKE2b-256 | 9256b428e91b9cbcf6a0c68054be6d4bdb42e46a32026f8b0a5646a61bf1f166 |
Provenance
File details
Details for the file pentapy-0.1.0-cp36-cp36m-manylinux1_x86_64.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp36-cp36m-manylinux1_x86_64.whl
- Upload date:
- Size: 407.0 kB
- Tags: CPython 3.6m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/38.2.4 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 542e2390861303c653b33626ced4b9f7102fc0921c8026106ab4b1a737f126ef |
|
MD5 | d6efefbe52d31f2cb8626f25a116eaa7 |
|
BLAKE2b-256 | 605c8a0f84158ef138dd566373bd1bbb2170098769b007f0d03b2bd5af34f331 |
Provenance
File details
Details for the file pentapy-0.1.0-cp36-cp36m-manylinux1_i686.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp36-cp36m-manylinux1_i686.whl
- Upload date:
- Size: 388.5 kB
- Tags: CPython 3.6m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/38.2.4 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 603787d5e5a2ea026499dba7d8ce7198f64328973a0e07cbe0fe44b2b0b298cd |
|
MD5 | daac3625f05b048141fc888f6497a531 |
|
BLAKE2b-256 | 3b90ed6095cfbe27313d4bdd6a7377019b128533c22b42ab963425854163c071 |
Provenance
File details
Details for the file pentapy-0.1.0-cp36-cp36m-macosx_10_6_intel.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp36-cp36m-macosx_10_6_intel.whl
- Upload date:
- Size: 269.8 kB
- Tags: CPython 3.6m, macOS 10.6+ intel
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/39.2.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 22ad0c2a26cb7c2539ea26b2cf7aed6f47ed211fefd92b4f0d84e4e740dbb3c3 |
|
MD5 | cd9fbc822a90f520d85bdabc015262a1 |
|
BLAKE2b-256 | 15a1d5e9160e2d87185096a1ae856bb1579311b7d7c6e2e01df2fe6ff2135359 |
Provenance
File details
Details for the file pentapy-0.1.0-cp35-cp35m-win_amd64.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp35-cp35m-win_amd64.whl
- Upload date:
- Size: 195.8 kB
- Tags: CPython 3.5m, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 21ed5dc9d3c8ae9e0ea1b3ee8078ac494d00ae938d3678e9c65ad4c854fdc456 |
|
MD5 | 8417e56e7d4c04e87036d012d7eb384a |
|
BLAKE2b-256 | b5ff223238d2e0cc1c3401b6b8e5fcaae91c58f62ef4afa180ae66652cabf32d |
Provenance
File details
Details for the file pentapy-0.1.0-cp35-cp35m-win32.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp35-cp35m-win32.whl
- Upload date:
- Size: 184.7 kB
- Tags: CPython 3.5m, Windows x86
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | eb3fd28de3460c8b4c28975cca3e3dac9d6a41d6b3c9f3576dd4b5ec78a0934b |
|
MD5 | c0f68953096aa9dc506cd4d916bdbb96 |
|
BLAKE2b-256 | 917d77513096b31caa83670bdd8cc4c6814ee4581dd7cca7a19a7bb7a1a12de9 |
Provenance
File details
Details for the file pentapy-0.1.0-cp35-cp35m-manylinux1_x86_64.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp35-cp35m-manylinux1_x86_64.whl
- Upload date:
- Size: 403.8 kB
- Tags: CPython 3.5m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.0.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.5.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 257357d0c2b4bc1db71fec08112cc40bb248308bf293ffcee2a6ed9a496e0071 |
|
MD5 | e26885c54a597153861ada6db6a1dfd9 |
|
BLAKE2b-256 | 46954bd910e7913285a744466f0c1862e0b9530e0218489c928e4245fb8c724c |
Provenance
File details
Details for the file pentapy-0.1.0-cp35-cp35m-manylinux1_i686.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp35-cp35m-manylinux1_i686.whl
- Upload date:
- Size: 383.7 kB
- Tags: CPython 3.5m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.0.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.5.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 307cfcbe7ddafcc6bff9322975d277e0cbcdde720fa662f8aff43b9ccd81c82e |
|
MD5 | 69f73c966da4399360b54e0cdc972be2 |
|
BLAKE2b-256 | 407b51545a0e537aefda9704be9093a488b6ee27797c13d9d5b802f0e8a92b35 |
Provenance
File details
Details for the file pentapy-0.1.0-cp35-cp35m-macosx_10_6_intel.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp35-cp35m-macosx_10_6_intel.whl
- Upload date:
- Size: 267.1 kB
- Tags: CPython 3.5m, macOS 10.6+ intel
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/39.2.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 69f83294dc9a5d7d0102a59efffa590bf614071d7084ab90b1710b717257b291 |
|
MD5 | ec68c06dea09bf9014e10e4f46381422 |
|
BLAKE2b-256 | a4ed857dbffbd65983228b55a4c665bc035f1bb894f88150e6f62396255b3d29 |
Provenance
File details
Details for the file pentapy-0.1.0-cp34-cp34m-win_amd64.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp34-cp34m-win_amd64.whl
- Upload date:
- Size: 194.7 kB
- Tags: CPython 3.4m, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | d39914fc4493f713eed3de64d545fcc77e2920e329bedc72855d59d3aa6563fb |
|
MD5 | 5c6e249a3caa3ba9c1601491d1fcfdc8 |
|
BLAKE2b-256 | 8f46fedb5367b98413ce94b1db1706884b2731a8ff2227f23d0b07be24056bc8 |
Provenance
File details
Details for the file pentapy-0.1.0-cp34-cp34m-win32.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp34-cp34m-win32.whl
- Upload date:
- Size: 186.7 kB
- Tags: CPython 3.4m, Windows x86
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ce30d3e88490b1ed0934939bbe3478fada8d2ee89cf7690c2f28c100ed614220 |
|
MD5 | 42992d2d4efd4942c62b399c1779ba2a |
|
BLAKE2b-256 | 51fa3e4335ede823ee5069fe21c4f0e0227dc00848b45f4293c5735369fb179f |
Provenance
File details
Details for the file pentapy-0.1.0-cp34-cp34m-manylinux1_x86_64.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp34-cp34m-manylinux1_x86_64.whl
- Upload date:
- Size: 408.0 kB
- Tags: CPython 3.4m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/35.0.2 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.4.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | eb5afc5baeeb3e667e56688eb326e660b66dc3f94b2888ad63e256b0a485c1e3 |
|
MD5 | 2dfa20c7f8a781b9416cd97c9465da68 |
|
BLAKE2b-256 | 8fe3377344dc6d688e46d651b5c3f1c5fea3003a3e709c1c7fe227445e616c79 |
Provenance
File details
Details for the file pentapy-0.1.0-cp34-cp34m-manylinux1_i686.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp34-cp34m-manylinux1_i686.whl
- Upload date:
- Size: 388.3 kB
- Tags: CPython 3.4m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/35.0.2 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.4.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3bdc8b6a24327773aa3cdef310fe10ca87045b528497565de09a3a662bdf34c2 |
|
MD5 | a6beadcdfcd82f567ae9418026b1e703 |
|
BLAKE2b-256 | bc45408fe8188ece2165a24efdc0d7c141603e879e4860923f17ab4b76a3e5bc |
Provenance
File details
Details for the file pentapy-0.1.0-cp34-cp34m-macosx_10_6_intel.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp34-cp34m-macosx_10_6_intel.whl
- Upload date:
- Size: 275.5 kB
- Tags: CPython 3.4m, macOS 10.6+ intel
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/39.2.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 97f659e1e4d7e46de5b39e687a5d5447a9682f350781467db428a9cd18dddc75 |
|
MD5 | f6d2d73ae30ba3be5125b080d0fee9ad |
|
BLAKE2b-256 | d87d3a99e1154801b9031274c665b49c7683e26f26049cd51558449ce491cb46 |
Provenance
File details
Details for the file pentapy-0.1.0-cp27-cp27mu-manylinux1_x86_64.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp27-cp27mu-manylinux1_x86_64.whl
- Upload date:
- Size: 406.8 kB
- Tags: CPython 2.7mu
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/38.2.4 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.14
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | de493fda47ad7a7c175ebc50f87f70fa533912f3fc4da005f0cd01fc1cf5349e |
|
MD5 | 5ccf629358451fc969b7d5acdf3104ca |
|
BLAKE2b-256 | 2948c6c2c6703d7a72eb86fc19d24f7e86fba490ad9f6104fb43c10ea53c4de6 |
Provenance
File details
Details for the file pentapy-0.1.0-cp27-cp27mu-manylinux1_i686.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp27-cp27mu-manylinux1_i686.whl
- Upload date:
- Size: 388.2 kB
- Tags: CPython 2.7mu
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/38.2.4 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.14
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6995e79c6e2b57c512c5b730d841c7009ff9a798571211044a5b0768568d90db |
|
MD5 | c438fa2956b277f12cb543574a0a21c0 |
|
BLAKE2b-256 | 85dc84acdb2378f92e2bf0d8191fabb6925b4091ee40a30a7a3b512c0a0c4e5b |
Provenance
File details
Details for the file pentapy-0.1.0-cp27-cp27m-win_amd64.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp27-cp27m-win_amd64.whl
- Upload date:
- Size: 201.1 kB
- Tags: CPython 2.7m, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b7b1058815ecb81075c1b3d0d1a187c5b01dc93ab69cf0e752cca89fe01955f4 |
|
MD5 | 39a8fb5f84ca95250de41ebae769dd5b |
|
BLAKE2b-256 | 89da9215c6e504aa23aa2c48eee7c8305b22067f638664d4f7960a86e399b093 |
Provenance
File details
Details for the file pentapy-0.1.0-cp27-cp27m-win32.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp27-cp27m-win32.whl
- Upload date:
- Size: 189.7 kB
- Tags: CPython 2.7m, Windows x86
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7a203d44f998b2081beaaf878e2fe147bb9206e616d051420e8b23f0671460a1 |
|
MD5 | 1740cd864d5fbbfc177f68d83cda56a3 |
|
BLAKE2b-256 | adcb0971cde506384240c547192050d286320a52d7ae1fa1cbf7780a1a47ddca |
Provenance
File details
Details for the file pentapy-0.1.0-cp27-cp27m-manylinux1_x86_64.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp27-cp27m-manylinux1_x86_64.whl
- Upload date:
- Size: 406.7 kB
- Tags: CPython 2.7m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/38.2.4 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.14
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 485da0439ab197c6784ed6a908c8845264115650c68ae2378d1bbcffbc3cd366 |
|
MD5 | 404dc5f16b941c5cf544689e18995793 |
|
BLAKE2b-256 | d735e9709bdf5831cc6f943f7fb3d4b715d34eac7b191b7030c7a09ea6716a49 |
Provenance
File details
Details for the file pentapy-0.1.0-cp27-cp27m-manylinux1_i686.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp27-cp27m-manylinux1_i686.whl
- Upload date:
- Size: 388.2 kB
- Tags: CPython 2.7m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/38.2.4 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.14
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e3a5be00e92dd3a195594528b288f516938120fa11ddb95e8a2b0408e0f38d57 |
|
MD5 | fbb44628217ae1258d7bb36d675f5b8e |
|
BLAKE2b-256 | b4375a45f52346a56839cf7c8e478f68dd9d1dfe4d72f20626f11aab8240713a |
Provenance
File details
Details for the file pentapy-0.1.0-cp27-cp27m-macosx_10_6_intel.whl
.
File metadata
- Download URL: pentapy-0.1.0-cp27-cp27m-macosx_10_6_intel.whl
- Upload date:
- Size: 286.0 kB
- Tags: CPython 2.7m, macOS 10.6+ intel
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1974f45d0d113aba67ef590b88c288f065cf86a86a8dee578ac9996ebd65e146 |
|
MD5 | 66d6ef3eaf6f74dfb33d10d312644da3 |
|
BLAKE2b-256 | ddfa38a47146bd764f74869f6f344c5380e3182309706ce67b4377dd499756be |