Skip to main content

PyPI OS License: MIT CI Bindings codecov

MQT QuSAT - A Tool for Utilizing SAT in Quantum Computing

A tool for utilizing satisfiablity testing (SAT) techniques in quantum computing developed by the Chair for Design Automation at the Technical University of Munich based on methods proposed in:

  • [1] L. Berent, L. Burgholzer, and R. Wille. Towards a Satisfiability Encoding for Quantum Circuits. 2022.

QuSAT is part of the Munich Quantum Toolkit (MQT) and builds upon our quantum functionality representation (QFR).

The project is in active development and can currently be used to

  • Encode Clifford circuits in SAT
  • Check the equivalence of Clifford circuits using SAT

If you have any questions, feel free to contact us via quantum.cda@xcit.tum.de or by creating an issue on GitHub.

Towards a Satisfiability Encoding for Quantum Circuits

The results from the paper can be reproduced by first building the project as described below and then executing the resulting qusat_test executable in the build directory. In order to replicate the full range of results, the test/test_satencoder.cpp needs to be modified before building the project. The corresponding lines to be changed are marked with a // Paper Evaluation: comment.

Running the executable, produces several .json files containing the experimental data. The python script /results/visualizer.py can be used to plot the respective data.

Note that, as we use a randomized procedure to generate input data, the exact experimental data will slightly vary every time the benchmarks are run. The experimental data used in the paper is available in /results directory.

System Requirements

Building (and running) is continuously tested under Linux, MacOS, and Windows using the latest available system versions for GitHub Actions. However, the implementation should be compatible with any current C++ compiler supporting C++17 and a minimum CMake version of 3.14.

The SMT Solver Z3 >= 4.8.3 has to be installed and the dynamic linker has to be able to find the library. This can be accomplished in a multitude of ways:

  • Under Ubuntu 20.04 and newer: sudo apt-get install libz3-dev
  • Under macOS: brew install z3
  • Alternatively: pip install z3-solver and then append the corresponding path to the library path (LD_LIBRARY_PATH under Linux, DYLD_LIBRARY_PATH under macOS), e.g. via
    export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$(python -c "import z3; print(z3.__path__[0]+'/lib')")
    
  • Download pre-built binaries from https://github.com/Z3Prover/z3/releases and copy the files to the respective system directories
  • Build Z3 from source and install it to the system

Configuration and Build

To start off, clone this repository using

git clone https://github.com/cda-tum/qusat --recursive

Note the --recursive flag. It is required to also clone all the required submodules. If you happen to forget passing the flag on your initial clone, you can initialize all the submodules by executing git submodule update --init --recursive in the main project directory.

The project uses CMake as the main build configuration tool. Building a project using CMake is a two-stage process. First, CMake needs to be configured by calling

cmake -S . -B build -DBUILD_QUSAT_TESTS=ON -DZ3_ROOT=/path/to/z3/

This tells CMake to search the current directory . (passed via -S) for a CMakeLists.txt file and process it into a directory build (passed via -B). If your installation of Z3 is recent enough, the Z3_ROOT can typically be omitted.

After configuring with CMake, the library can be built by calling

cmake --build build

This tries to build the project in the build directory (passed via --build). Some operating systems and developer environments explicitly require a configuration to be set, which is why the --config flag is also passed to the build command. The flag --parallel <NUMBER_OF_THREADS> may be added to trigger a parallel build.

Reference

If you use our tool for your research, we would appreciate if you refer to it by citing the appropriate publication:

@inproceedings{berent2022sat,
      title={Towards a SAT Encoding for Quantum Circuits: A Journey From Classical Circuits to Clifford Circuits and Beyond},
      author={Lucas Berent and Lukas Burgholzer and Robert Wille},
      year={2022},
      booktitle={International Conference on Theory and Applications of Satisfiability Testing}
}

Metadata

Release files for mqt-qusat 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for mqt-qusat 1.0.0
File Size Uploaded
mqt.qusat-1.0.0.tar.gz 2.3 MB Details

Built distributions (wheels)

Table of built distributions (wheels) for mqt-qusat 1.0.0
File
mqt.qusat-1.0.0-cp311-cp311-win_amd64.whl CPython 3.11 CPython 3.11 Windows x86-64 Details
mqt.qusat-1.0.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.11 CPython 3.11 Linux glibc 2.17+ x86-64 Details
mqt.qusat-1.0.0-cp311-cp311-macosx_11_0_arm64.whl CPython 3.11 CPython 3.11 macOS 11.0+ ARM64 Details
mqt.qusat-1.0.0-cp310-cp310-win_amd64.whl CPython 3.10 CPython 3.10 Windows x86-64 Details
mqt.qusat-1.0.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.10 CPython 3.10 Linux glibc 2.17+ x86-64 Details
mqt.qusat-1.0.0-cp310-cp310-macosx_11_0_arm64.whl CPython 3.10 CPython 3.10 macOS 11.0+ ARM64 Details
mqt.qusat-1.0.0-cp39-cp39-win_amd64.whl CPython 3.9 CPython 3.9 Windows x86-64 Details
mqt.qusat-1.0.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.9 CPython 3.9 Linux glibc 2.17+ x86-64 Details
mqt.qusat-1.0.0-cp39-cp39-macosx_11_0_arm64.whl CPython 3.9 CPython 3.9 macOS 11.0+ ARM64 Details
mqt.qusat-1.0.0-cp38-cp38-win_amd64.whl CPython 3.8 CPython 3.8 Windows x86-64 Details
mqt.qusat-1.0.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.8 CPython 3.8 Linux glibc 2.17+ x86-64 Details
mqt.qusat-1.0.0-cp38-cp38-macosx_11_0_arm64.whl CPython 3.8 CPython 3.8 macOS 11.0+ ARM64 Details
mqt.qusat-1.0.0-cp37-cp37m-win_amd64.whl CPython 3.7 CPython 3.7 pymalloc Windows x86-64 Details
mqt.qusat-1.0.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.7 CPython 3.7 pymalloc Linux glibc 2.17+ x86-64 Details

Total release size: 104.3 MB

Release files / mqt.qusat-1.0.0.tar.gz

Download URL mqt.qusat-1.0.0.tar.gz
Size 2.3 MB
Tags Source
SHA-256 checksum
How to use checksums
4743c95836dc6e7a29c3f8dffec063358136c2a135b143e62dbc7a0f814f9084
BLAKE2b-256 checksum
How to use checksums
0f13c2cf22e795ea8eb116b22d84b1cd037c30b3586f3f3ca2724c092e1ce940
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.15

Release files / mqt.qusat-1.0.0-cp311-cp311-win_amd64.whl

Download URL mqt.qusat-1.0.0-cp311-cp311-win_amd64.whl
Size 7.5 MB
Tags CPython 3.11 Windows x86-64
SHA-256 checksum
How to use checksums
87325ba7998961a42de9999a68d5482b291d9a10d16762fe6da1fd3f6e89dc6a
BLAKE2b-256 checksum
How to use checksums
6c2497c8c48ae7489e2af15b9375494e6830d031d49714fc075dce8372e7d569
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.15

Release files / mqt.qusat-1.0.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL mqt.qusat-1.0.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 12.6 MB
Tags CPython 3.11 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
9a97c873bdf53638c93744d7bfe0a09fa2f3a96302e77fdf41b48168b22ca3a1
BLAKE2b-256 checksum
How to use checksums
19194cb35790ec2ed2634af8f016e34e080462395aaaf8d328ef2dcbe4deab5c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.15

Release files / mqt.qusat-1.0.0-cp311-cp311-macosx_11_0_arm64.whl

Download URL mqt.qusat-1.0.0-cp311-cp311-macosx_11_0_arm64.whl
Size 376.5 kB
Tags CPython 3.11 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
12ca4df3821027b2a04dca46f7269dd0b076f3d531a1022cf3f2d32f9c46c514
BLAKE2b-256 checksum
How to use checksums
0a4940d4d409b572661848a56b881afdbfe91f32a8a8b8d1b8ff88b396f5aede
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.15

Release files / mqt.qusat-1.0.0-cp310-cp310-win_amd64.whl

Download URL mqt.qusat-1.0.0-cp310-cp310-win_amd64.whl
Size 7.5 MB
Tags CPython 3.10 Windows x86-64
SHA-256 checksum
How to use checksums
c7da665779138758b7b01f4676e4a174578b30bc964b96bd0bc2d707846e9330
BLAKE2b-256 checksum
How to use checksums
b668dd5fd949c9e8764aafbe76bc0aac715ecc2f06fc57cd0a3ce6c949b8ac73
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.15

Release files / mqt.qusat-1.0.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL mqt.qusat-1.0.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 12.6 MB
Tags CPython 3.10 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
eb579676a6250fefc12ca1b6290f6bf15475fdaa284977c1f2ca38d498f7dc3c
BLAKE2b-256 checksum
How to use checksums
270a1ce9602cceb130597ae4a5092a64c8df38d56702e3724a6c5ae280f01250
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.15

Release files / mqt.qusat-1.0.0-cp310-cp310-macosx_11_0_arm64.whl

Download URL mqt.qusat-1.0.0-cp310-cp310-macosx_11_0_arm64.whl
Size 376.5 kB
Tags CPython 3.10 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
fb519f0964f7513b0b401601a1ef8da2ed7e645b36c82263aed90a4594dfd6cb
BLAKE2b-256 checksum
How to use checksums
dc6377264dc72dd21c76322b2137c19251d57ad8506003ebcf93b34db2dc8617
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.15

Release files / mqt.qusat-1.0.0-cp39-cp39-win_amd64.whl

Download URL mqt.qusat-1.0.0-cp39-cp39-win_amd64.whl
Size 7.5 MB
Tags CPython 3.9 Windows x86-64
SHA-256 checksum
How to use checksums
6d6df38aebd0111b8ad44f576a6f0d2337c7bc42168ad1a8a07d3febadff006d
BLAKE2b-256 checksum
How to use checksums
2a79463ad1b66447496a0497b6dca765f150c5dfb2a815bea46b4fb5229d42bc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.15

Release files / mqt.qusat-1.0.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL mqt.qusat-1.0.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 12.6 MB
Tags CPython 3.9 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
a645857fb6ebf989e7c64a6dc800966bc0a3ecaea9f7e4f014d8da8def2d1e65
BLAKE2b-256 checksum
How to use checksums
d35d143b652ff8bf11c13509b50e71813c0457a7b9a007a475b85ab3c31e2df5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.15

Release files / mqt.qusat-1.0.0-cp39-cp39-macosx_11_0_arm64.whl

Download URL mqt.qusat-1.0.0-cp39-cp39-macosx_11_0_arm64.whl
Size 376.6 kB
Tags CPython 3.9 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
9993c87ec0e4356a7f35b255bd94115822607b25feccd9933337b9437fc1e851
BLAKE2b-256 checksum
How to use checksums
c4b78b2c2fce5620e2e6ca6fc25490fd11502fb9e1906e766fcd5c372ec6494e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.15

Release files / mqt.qusat-1.0.0-cp38-cp38-win_amd64.whl

Download URL mqt.qusat-1.0.0-cp38-cp38-win_amd64.whl
Size 7.5 MB
Tags CPython 3.8 Windows x86-64
SHA-256 checksum
How to use checksums
752f5ab124aef48b90fac46878309ccce8ce2b5ab549242c873007c102347d6c
BLAKE2b-256 checksum
How to use checksums
211d6a778e64fbb5e5005e204018bd055b0427cb3357e062ae33aa5cd44e615a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.15

Release files / mqt.qusat-1.0.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL mqt.qusat-1.0.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 12.6 MB
Tags CPython 3.8 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
f980831c4b5ad4e75fdcdbc501d3b6fe9a687105cbb4b722365783b489c44a64
BLAKE2b-256 checksum
How to use checksums
d04218592ca97cbf0f4f79570b6e8cca4f2290622b18ca33aca9320e61408750
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.15

Release files / mqt.qusat-1.0.0-cp38-cp38-macosx_11_0_arm64.whl

Download URL mqt.qusat-1.0.0-cp38-cp38-macosx_11_0_arm64.whl
Size 376.6 kB
Tags CPython 3.8 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
b528a58872e57a7898d760d75be503f2642e1693c3e0c75d47aee58de7c722d8
BLAKE2b-256 checksum
How to use checksums
b8d8addcb3e7e09ade6b323886995306e7114d5dd14015731dbad40a840e36ca
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.15

Release files / mqt.qusat-1.0.0-cp37-cp37m-win_amd64.whl

Download URL mqt.qusat-1.0.0-cp37-cp37m-win_amd64.whl
Size 7.5 MB
Tags CPython 3.7 CPython 3.7 pymalloc Windows x86-64
SHA-256 checksum
How to use checksums
28c8529dab382e8c30b7a8f1339b3051ceaec6a319d238a9311b22d65d7f3285
BLAKE2b-256 checksum
How to use checksums
2c74816493a3d97a83d66d8f5c618a6e7369f32732a165ace3377289bccde0cc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.15

Release files / mqt.qusat-1.0.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL mqt.qusat-1.0.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 12.6 MB
Tags CPython 3.7 CPython 3.7 pymalloc Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
72646dfab3af1b23cd196b6270c6f248c576621833fecf10e6b1c05fdda0fdcd
BLAKE2b-256 checksum
How to use checksums
ccff7773ba544850e7d257ae6717eebf94fcad4b1ef9bfdf4c4a96ed9cd1db3c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.15

Release history Release notifications | RSS feed

1.5.0

11 release files

1.4.0

43 release files

1.2.0

31 release files

1.1.0

16 release files

This release

1.0.0 This release

15 release files

0.1.1

19 release files

0.0.0

19 release 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