Skip to main content

High-Level Quantum Computing Simulation in Python

Project description

pyqsim: High-Level Quantum Computing Simulation in Python

pyqsim is a Python library designed to simplify quantum computing simulation through high-level abstractions. It aims to make quantum programming more accessible and intuitive, bridging the gap between classical and quantum computing paradigms.

Features

  • High-Level Abstraction: Move beyond low-level circuit and qubit manipulations to a more intuitive programming model.
  • Automatic Inverse Operations: Objects automatically perform inverse operations upon deletion, maintaining quantum state consistency.
  • Familiar Programming Model: Use quantum data types similarly to classical types like int, making the transition to quantum computing smoother for classical programmers.
  • Eager Execution: Computations are performed immediately as Python functions are called, allowing for real-time interaction and debugging.
  • Quantum-Classical Hybrid Programming: Seamlessly mix quantum operations with classical programming constructs.

Installation

pip install pyqsim

Quick Start

Here's a simple example implementing Deutsch's algorithm:

import pyqsim
from pyqsim.gates import h, z

def oracle(x): return x  # Constant function

a = pyqsim.types.qint1_t()
z(oracle(h(a)))
result = pyqsim.gates.measure(a)
print("Constant" if result == 0 else "Balanced")

Advanced Usage

Check out the examples/ directory for more complex quantum algorithms implementations, including Grover's search algorithm.

Contributing

We welcome contributions! Please see our Contributing Guidelines for more details.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Contact

For any queries or support, please open an issue on our GitHub repository or contact me at cykim@snu.ac.kr.

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

pyqsim-0.0.3-py3-none-any.whl (7.3 kB view details)

Uploaded Python 3

File details

Details for the file pyqsim-0.0.3-py3-none-any.whl.

File metadata

  • Download URL: pyqsim-0.0.3-py3-none-any.whl
  • Upload date:
  • Size: 7.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.4

File hashes

Hashes for pyqsim-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 60adcb554dfc4510dc760293594ed09b0a55c3cab5b7ea03586220a09fb4d66b
MD5 e6cbd88afecda94aeda52d3cf12fe172
BLAKE2b-256 ef576b7b9f144d1b3c79bf61ab7222c3193c6b554f2ec70b62868c3600c9b18f

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