Skip to main content

Сompiler of classical algorithms into oracles for quantum computing

Project description

Сompiler of classical algorithms into oracles for quantum computing

Achievements:

  • CRC32 hash function (4 byte input) - 411 qubits.

Architecture:

  1. Parsing source code in AST (planned).
  2. Construction of a single large expression.
  3. Construction of an even larger logical expression for each bit of the output result of the algorithm.
  4. Expression optimization (minimizing unique logic operations and qubit allocations).
  5. Generation of a quantum circuit from a DAG of logical operations.

Authors:

  • Alexander Averyanov - author
  • Evgeny Kiktenko - mentor
  • Dmitry Ershov - helped with the optimizer design

Example:

import quantpiler

a = quantpiler.Expr("a", 3)
b = a.argument("b", 2)
add = a + b
xor = add ^ 0b100
and_const = xor & 0b111

circ = and_const.compile()
qc = quantpiler.circuit_to_qiskit(circ)

qc.draw('mpl')

Resulting circuit

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

quantpiler-0.3.1.tar.gz (61.2 kB view hashes)

Uploaded Source

Built Distributions

quantpiler-0.3.1-pp310-pypy310_pp73-manylinux_2_28_x86_64.whl (2.5 MB view hashes)

Uploaded PyPy manylinux: glibc 2.28+ x86-64

quantpiler-0.3.1-pp39-pypy39_pp73-manylinux_2_28_x86_64.whl (2.5 MB view hashes)

Uploaded PyPy manylinux: glibc 2.28+ x86-64

quantpiler-0.3.1-pp38-pypy38_pp73-manylinux_2_28_x86_64.whl (2.5 MB view hashes)

Uploaded PyPy manylinux: glibc 2.28+ x86-64

quantpiler-0.3.1-cp312-none-win_amd64.whl (1.7 MB view hashes)

Uploaded CPython 3.12 Windows x86-64

quantpiler-0.3.1-cp312-none-win32.whl (1.5 MB view hashes)

Uploaded CPython 3.12 Windows x86

quantpiler-0.3.1-cp312-cp312-manylinux_2_28_x86_64.whl (2.5 MB view hashes)

Uploaded CPython 3.12 manylinux: glibc 2.28+ x86-64

quantpiler-0.3.1-cp311-none-win_amd64.whl (1.7 MB view hashes)

Uploaded CPython 3.11 Windows x86-64

quantpiler-0.3.1-cp311-none-win32.whl (1.5 MB view hashes)

Uploaded CPython 3.11 Windows x86

quantpiler-0.3.1-cp311-cp311-manylinux_2_28_x86_64.whl (2.6 MB view hashes)

Uploaded CPython 3.11 manylinux: glibc 2.28+ x86-64

quantpiler-0.3.1-cp310-none-win_amd64.whl (1.7 MB view hashes)

Uploaded CPython 3.10 Windows x86-64

quantpiler-0.3.1-cp310-none-win32.whl (1.5 MB view hashes)

Uploaded CPython 3.10 Windows x86

quantpiler-0.3.1-cp310-cp310-manylinux_2_28_x86_64.whl (2.6 MB view hashes)

Uploaded CPython 3.10 manylinux: glibc 2.28+ x86-64

quantpiler-0.3.1-cp39-none-win_amd64.whl (1.7 MB view hashes)

Uploaded CPython 3.9 Windows x86-64

quantpiler-0.3.1-cp39-none-win32.whl (1.5 MB view hashes)

Uploaded CPython 3.9 Windows x86

quantpiler-0.3.1-cp39-cp39-manylinux_2_28_x86_64.whl (2.6 MB view hashes)

Uploaded CPython 3.9 manylinux: glibc 2.28+ x86-64

quantpiler-0.3.1-cp38-none-win_amd64.whl (1.7 MB view hashes)

Uploaded CPython 3.8 Windows x86-64

quantpiler-0.3.1-cp38-none-win32.whl (1.5 MB view hashes)

Uploaded CPython 3.8 Windows x86

quantpiler-0.3.1-cp38-cp38-manylinux_2_28_x86_64.whl (2.6 MB view hashes)

Uploaded CPython 3.8 manylinux: glibc 2.28+ x86-64

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