Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

Zixy

CI PyPI version License: Apache-2.0

Zixy is a high performance library for the manipulation of Pauli strings and other quantum algebraic objects.

Installation

From PyPI

The package is available via PyPI and can be installed using the preferred package manager, such as pip.

pip install zixy

From source

Developers may wish to install from source. The recommended method is by using maturin from the top level directory.

git clone https://github.com/quantinuum/zixy
cd zixy
maturin develop

Usage

Overview

The package is written in Rust, with Python bindings enabled via PyO3. The base containers in the Python interface are defined in a general fashion. The user-facing API separates these objects into three important classes:

  • Coeff: a coefficient, defining a scalar value of varying types.
  • Cmpnt: a component, defining a basic algebraic building block.
  • Term: a term, consisting of a Cmpnt scaled by a Coeff.

Coefficients are separated into built-in Python types such as float or complex, symbolic sympy expressions, and roots of unity such as Sign and ComplexSign, which have custom implementations.

Additionally, each such class has associated containers for collections of that type. Implementations of these base classes may narrow their implementation depending on the coefficient type.

Example

These general building blocks are sufficient to define many different quantum algebraic objects. An example of one such specification of the objects in Zixy is Pauli strings. These are made available in the zixy.qubit.pauli submodule, with the qubits forming a basis for their definition available in zixy.qubit.

import zixy.qubit as zq
import zixy.qubit.pauli as zqp

qubits = zq.Qubits.from_count(4)
print(len(qubits))  # 4

strings = zqp.Strings.from_str("X0 Y1 Z3", qubits)
print(str(strings))  # X0 Y1 Z3

terms = zqp.RealTerms.from_str("X0 Y1 Z3")
print(str(terms))  # (1, X0 Y1 Z3)

For other specifications such as computational basis vectors, further example notebooks are available.

Rust

The trait NumRepr (meaning "number representation") is implemented by all types that can represent the numbers multiplying components. In collections, these are stored contiguously in vector-like structures. Values of NumRepr types are closed under multiplication, but do not implement addition. Implementers of NumRepr are

  • Unity: a unit type representing +1 and only +1. The corresponding collection container UnityVec only stores a length, the number of unit values.
  • Sign: the square roots of unity (+1, -1). The corresponding collection container, SignVec is implemented as a bitset.
  • ComplexSign: the fourth roots of unity (+1, +i, -1, -i). The corresponding collection container, ComplexSignVec is implemented as a paired bitset.

The FieldElem subtrait of NumRepr is implemented by types whose values form a field with multiplication and addition. Implementers of both NumRepr and FieldElem use Vec<T> for collection storage, and are

  • Real: Floating point value f64
  • Complex: Complex floating point value Complex64 from num_complex crate.

The Python interface further supports symbolic types via SymPy, which are not currently available within the Rust library.

On the Rust side, components are stored contiguously in CmpntList types. These implement the business logic applicable to their elements. There are three main kinds of container that encapsulate CmpntList with generic coefficient type C

  • Terms<C: NumRepr>: stores a C::Vector of the same length as the CmpntList, offers mutable access to the components and coefficients.
  • TermSet<C: NumRepr>: stores a C::Vector of the same length as the CmpntList and via an indirect hash map, provides constant complexity lookup and enforces uniqueness among components. Offers mutable access only to the coefficients.
  • TermSum<C: FieldElem>: works like Set<C> but with linear combination semantics and is only defined for FieldElem-implementing coefficient types.

Download files

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

Source Distribution

zixy-0.4.0rc0.tar.gz (588.5 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

zixy-0.4.0rc0-cp310-abi3-win_amd64.whl (1.4 MB view details)

Uploaded CPython 3.10+Windows x86-64

zixy-0.4.0rc0-cp310-abi3-win32.whl (1.2 MB view details)

Uploaded CPython 3.10+Windows x86

zixy-0.4.0rc0-cp310-abi3-musllinux_1_2_x86_64.whl (1.9 MB view details)

Uploaded CPython 3.10+musllinux: musl 1.2+ x86-64

zixy-0.4.0rc0-cp310-abi3-musllinux_1_2_i686.whl (1.9 MB view details)

Uploaded CPython 3.10+musllinux: musl 1.2+ i686

zixy-0.4.0rc0-cp310-abi3-musllinux_1_2_armv7l.whl (1.9 MB view details)

Uploaded CPython 3.10+musllinux: musl 1.2+ ARMv7l

zixy-0.4.0rc0-cp310-abi3-musllinux_1_2_aarch64.whl (1.8 MB view details)

Uploaded CPython 3.10+musllinux: musl 1.2+ ARM64

zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.6 MB view details)

Uploaded CPython 3.10+manylinux: glibc 2.17+ x86-64

zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_s390x.manylinux2014_s390x.whl (1.7 MB view details)

Uploaded CPython 3.10+manylinux: glibc 2.17+ s390x

zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl (1.9 MB view details)

Uploaded CPython 3.10+manylinux: glibc 2.17+ ppc64le

zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl (1.6 MB view details)

Uploaded CPython 3.10+manylinux: glibc 2.17+ ARMv7l

zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (1.6 MB view details)

Uploaded CPython 3.10+manylinux: glibc 2.17+ ARM64

zixy-0.4.0rc0-cp310-abi3-manylinux_2_5_i686.manylinux1_i686.whl (1.7 MB view details)

Uploaded CPython 3.10+manylinux: glibc 2.5+ i686

zixy-0.4.0rc0-cp310-abi3-macosx_11_0_arm64.whl (1.5 MB view details)

Uploaded CPython 3.10+macOS 11.0+ ARM64

File details

Details for the file zixy-0.4.0rc0.tar.gz.

File metadata

  • Download URL: zixy-0.4.0rc0.tar.gz
  • Upload date:
  • Size: 588.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for zixy-0.4.0rc0.tar.gz
Algorithm Hash digest
SHA256 cb8d7cc46b8ec1e231e92e41ca8ea251717d9fd1ea9872b59e3aa8252c95dd07
MD5 0bfb5daba6034464dae9355c35494e19
BLAKE2b-256 c40c196c39214ff01dba772066f60f38c7df6a55e5cf53553110092e8e103cbc

See more details on using hashes here.

Provenance

The following attestation bundles were made for zixy-0.4.0rc0.tar.gz:

Publisher: release.yml on Quantinuum/zixy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file zixy-0.4.0rc0-cp310-abi3-win_amd64.whl.

File metadata

  • Download URL: zixy-0.4.0rc0-cp310-abi3-win_amd64.whl
  • Upload date:
  • Size: 1.4 MB
  • Tags: CPython 3.10+, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for zixy-0.4.0rc0-cp310-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 25865a77593d77127444c017544c5889567abd7f687155ddb7814b8b1da99fbd
MD5 0e9a05b9a89e5c497b0e9d5ccbe6874c
BLAKE2b-256 4467135b6e95668f7ce2d66b101ad5d9e54bc63e1a204718547901d1273457d2

See more details on using hashes here.

Provenance

The following attestation bundles were made for zixy-0.4.0rc0-cp310-abi3-win_amd64.whl:

Publisher: release.yml on Quantinuum/zixy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file zixy-0.4.0rc0-cp310-abi3-win32.whl.

File metadata

  • Download URL: zixy-0.4.0rc0-cp310-abi3-win32.whl
  • Upload date:
  • Size: 1.2 MB
  • Tags: CPython 3.10+, Windows x86
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for zixy-0.4.0rc0-cp310-abi3-win32.whl
Algorithm Hash digest
SHA256 5f6230d0bd4830bb1d7b0dfc79fad5cea20610866ebabb84807e7f1b4c587a3b
MD5 a991ea111c262e81f3f943acaaf15c13
BLAKE2b-256 899ea49900e20436af96386c9a5f714dd4a1c8b91d2088e450daf1dda5d21969

See more details on using hashes here.

Provenance

The following attestation bundles were made for zixy-0.4.0rc0-cp310-abi3-win32.whl:

Publisher: release.yml on Quantinuum/zixy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file zixy-0.4.0rc0-cp310-abi3-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for zixy-0.4.0rc0-cp310-abi3-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 d74ce620e2e4a24b33901d7726b55508f2d17581680f3d4ca204536c75897e55
MD5 6c70f05ce66a2fc28108c2432de788a6
BLAKE2b-256 eeb0541e3852fdf1e00fce8924fee32b0d85a2200e734fc56e73baa9b9ed4bf7

See more details on using hashes here.

Provenance

The following attestation bundles were made for zixy-0.4.0rc0-cp310-abi3-musllinux_1_2_x86_64.whl:

Publisher: release.yml on Quantinuum/zixy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file zixy-0.4.0rc0-cp310-abi3-musllinux_1_2_i686.whl.

File metadata

File hashes

Hashes for zixy-0.4.0rc0-cp310-abi3-musllinux_1_2_i686.whl
Algorithm Hash digest
SHA256 c763867c10217db3e984d4e7b86447890461ef67edad163afdd843a248ccd6aa
MD5 046c1a65dd6f35c317302f79aab14e64
BLAKE2b-256 1191428d0147f8dc8135e98ee4455f10dc14e65bbce0b869784ac0ce9105c9ec

See more details on using hashes here.

Provenance

The following attestation bundles were made for zixy-0.4.0rc0-cp310-abi3-musllinux_1_2_i686.whl:

Publisher: release.yml on Quantinuum/zixy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file zixy-0.4.0rc0-cp310-abi3-musllinux_1_2_armv7l.whl.

File metadata

File hashes

Hashes for zixy-0.4.0rc0-cp310-abi3-musllinux_1_2_armv7l.whl
Algorithm Hash digest
SHA256 438c765689432092c2875de3fe753bc475d7a49cf305dc01db68709d1897d794
MD5 3ae02810eae58b3cab0f93736a8041ef
BLAKE2b-256 b62833ee35b9eeb63f47bc1e7fa3ef0579f879d1010541ff66628a48e07c3fba

See more details on using hashes here.

Provenance

The following attestation bundles were made for zixy-0.4.0rc0-cp310-abi3-musllinux_1_2_armv7l.whl:

Publisher: release.yml on Quantinuum/zixy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file zixy-0.4.0rc0-cp310-abi3-musllinux_1_2_aarch64.whl.

File metadata

File hashes

Hashes for zixy-0.4.0rc0-cp310-abi3-musllinux_1_2_aarch64.whl
Algorithm Hash digest
SHA256 4873e05193fad9cf0b8dadc1fd3d0afb26beb05ec58d2494370d2623dec29c9a
MD5 69ca0e6996bdad160861afe422fc7f06
BLAKE2b-256 60d0d84b1f2c9ac4729af270913b71e3b6074d64db4fbe585e4188a05088618c

See more details on using hashes here.

Provenance

The following attestation bundles were made for zixy-0.4.0rc0-cp310-abi3-musllinux_1_2_aarch64.whl:

Publisher: release.yml on Quantinuum/zixy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 f0fada37ebdb5e5231a1223f2dc8f2dcfc7d60ec46b2a3c980d142ec6e1aadd2
MD5 7d38a725a4b9e02a3a307c3061d1eaac
BLAKE2b-256 7e20979e9ebe7387e9aa11816c0ce8a73b3e95b4eee24c60e81b68cb8e9dd914

See more details on using hashes here.

Provenance

The following attestation bundles were made for zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: release.yml on Quantinuum/zixy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_s390x.manylinux2014_s390x.whl.

File metadata

File hashes

Hashes for zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_s390x.manylinux2014_s390x.whl
Algorithm Hash digest
SHA256 6fb1619696be590e7e2fb32ed20cd4213152ca088dbf1812b53fe6c01cb4cc9f
MD5 c5d1dcd9e85bbbc82c71d66c8a009c56
BLAKE2b-256 fec356c61f6cfc3cba7c4ba10cdbcc632c77d60fe731dc2c9166a09e37fe6a96

See more details on using hashes here.

Provenance

The following attestation bundles were made for zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_s390x.manylinux2014_s390x.whl:

Publisher: release.yml on Quantinuum/zixy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl.

File metadata

File hashes

Hashes for zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
Algorithm Hash digest
SHA256 3f3393a383e0761de4ee79c584343ce343f5ce5f96da07ab788fcfbb98f79c15
MD5 8a5405024d03ab43fe45642f27be236c
BLAKE2b-256 a30b231c4a3b8b5ebf124d618925f85c5b192561a4291fcf04b3cc7db45a7154

See more details on using hashes here.

Provenance

The following attestation bundles were made for zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl:

Publisher: release.yml on Quantinuum/zixy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl.

File metadata

File hashes

Hashes for zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
Algorithm Hash digest
SHA256 398de01abfaa3b54c7e1c95daaa6e9b50f32f7550865688e8c39ff8a518d10b8
MD5 fe7fa12e7481b55cd15557383bd8dd1f
BLAKE2b-256 26532ba999541b9be69826cc747dc62e87d4dfb671c63e5014d524302fb2275a

See more details on using hashes here.

Provenance

The following attestation bundles were made for zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl:

Publisher: release.yml on Quantinuum/zixy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 ba4dcf73c1bc8388c26111052ab47c24e2c756e0dfddd329a6b58e518905e506
MD5 4f34248f099731e969940b0faa2cb4dc
BLAKE2b-256 16664edf0105025682e3470f66a997357a463c8b94ae2c6abb757e2e55d147ff

See more details on using hashes here.

Provenance

The following attestation bundles were made for zixy-0.4.0rc0-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl:

Publisher: release.yml on Quantinuum/zixy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file zixy-0.4.0rc0-cp310-abi3-manylinux_2_5_i686.manylinux1_i686.whl.

File metadata

File hashes

Hashes for zixy-0.4.0rc0-cp310-abi3-manylinux_2_5_i686.manylinux1_i686.whl
Algorithm Hash digest
SHA256 a0931d093e4c696c35f8dfd738fcb01c460e98ced01d75d862cda777f19cadd2
MD5 88acfc58dbf5b6fa0e2b35289f7cc3cb
BLAKE2b-256 63e6d7bd02870c8845596ce2a15f71525e353ecd10699f8b9ac61f04c15f1539

See more details on using hashes here.

Provenance

The following attestation bundles were made for zixy-0.4.0rc0-cp310-abi3-manylinux_2_5_i686.manylinux1_i686.whl:

Publisher: release.yml on Quantinuum/zixy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file zixy-0.4.0rc0-cp310-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for zixy-0.4.0rc0-cp310-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 58d3cdc0fc0aab60a23f930326fc0a8d8ee3ae995ce077d13b817d98d05695be
MD5 075153214291d5319cf2645b4c8708ec
BLAKE2b-256 3388a8cf6ba7457347244434ea4f7b545bdbdd9cb88cbe37fe204337d223ed8a

See more details on using hashes here.

Provenance

The following attestation bundles were made for zixy-0.4.0rc0-cp310-abi3-macosx_11_0_arm64.whl:

Publisher: release.yml on Quantinuum/zixy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

0.4.0rc0 This release

14 files

0.3.2

14 files

0.3.1

14 files

0.3.0

14 files

0.2.2

14 files

0.2.1

14 files

0.2.0

14 files

0.1.0

13 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page