Skip to main content

Transformations between quantum weight enumerators

Project description

qsalto logo

transform your quantum weight enumerators

PyPI Package MIT License Tests

qsalto provides transformations between several quantum weight enumerators, including

  • Shor-Laflamme enumerators $a$, $b$,
  • Rains unitary enumerators $a'$,
  • and Rains shadow enumerators $a''$.

We provide both

Python package

The python package qsalto can be installed via pip install qsalto and features functions to generate nine classes of transformation matrices.

Matrix Function Transforms from ... ... to is self-inverse
$M$ M(n) $\mathbf{a}$ $\mathbf{b}$
$M'$ M1(n) $\mathbf{a'}$ $\mathbf{b'}$
$M''$ M2(n) $\mathbf{a''}$ $\mathbf{b''}$
$T'$ T1(n) $\mathbf{a}$, $\mathbf{b}$ $\mathbf{a'}$, $\mathbf{b'}$
$T'^{-1}$ iT1(n) $\mathbf{a'}$, $\mathbf{b'}$ $\mathbf{a}$, $\mathbf{b}$
$T''$ T2(n) $\mathbf{a}$, $\mathbf{b}$ $\mathbf{a''}$, $\mathbf{b''}$
$T''^{-1}$ iT2(n) $\mathbf{a''}$, $\mathbf{b''}$ $\mathbf{a}$, $\mathbf{b}$
$T'''$ T3(n) $\mathbf{a'}$, $\mathbf{b'}$ $\mathbf{a''}$, $\mathbf{b''}$
$T'''^{-1}$ iT3(n) $\mathbf{a''}$, $\mathbf{b''}$ $\mathbf{a'}$, $\mathbf{b'}$

To compute the full matrices, a special algorithm making use of recursive patterns is employed. Each matrix generator also features the computation of single elements through, e.g., M(100, entry=[3,4]) where entry specifies the row and column of the entry (in that order). This is only faster than computing the entire matrix when merely very few entries are computed.

Single-shot estimators

Furthermore, the function single_shot_estimators(n) generates single-shot estimators for $a$, $b$, $a'$, $b'$, $a''$, and $b''$ for all possible numbers $m=0,...,n$ of singlets as an outcome of a two-copy bell measurement. This function returns six 2D-arrays (one for each quantum weight enumerator in the order as given above) with the estimator for $m$ singlets in the $m$-th column.

License

This library is distributed under the MIT License.

If you want to support work like this, please cite our paper: tba

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

qsalto-0.1.0.tar.gz (7.0 kB view details)

Uploaded Source

Built Distribution

qsalto-0.1.0-py3-none-any.whl (6.3 kB view details)

Uploaded Python 3

File details

Details for the file qsalto-0.1.0.tar.gz.

File metadata

  • Download URL: qsalto-0.1.0.tar.gz
  • Upload date:
  • Size: 7.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.0 CPython/3.12.4

File hashes

Hashes for qsalto-0.1.0.tar.gz
Algorithm Hash digest
SHA256 cb42514f0b7e49c94187f811c4ed2254fc1d2139e52bef10c6ba71d96fb39730
MD5 e60dfc3f43cca40dcd7214389046bbea
BLAKE2b-256 c4c46a3399f3b4371a3a7753b1cb340c282354561a582eb8bba7bb9c2a0db104

See more details on using hashes here.

File details

Details for the file qsalto-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: qsalto-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 6.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.0 CPython/3.12.4

File hashes

Hashes for qsalto-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 0201a41e80c5a06760a330a05618443b923613ae85493ed5e8fe64163645c20f
MD5 60333425e177ae8b1d6d0756efd0a79f
BLAKE2b-256 a033085e04024e2dfe6dde336dc471fea07edfd57fcce4379b87a6206f77ebdc

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page