Skip to main content

A library to simulate quantum computations

Project description

Quantum Computing Simulator


A python library to simulate quantum programs and circuits.

Table of Contents

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

This library is self contained, and optionally uses matplotlib for plotting graphs.

Installing

This library can be installed from pypi using pip:

$ pip install quantumcomputingsim

To make sure everything installed properly, import the main and only module in python:

from quantum import *

Usage

Go through example.ipynb for a comprehensive guide on using this library

Sample workflow:

entangler = qprogram(
    nqbits = 2,
    name = "Entangler"
)
entangler.addgates(0, [HGATE, CNOT0])
entangler.compile()

Compiler result:

Compiling Entangler...

Entangler
q0(0) ⮕  -----[ h ]--⌈ c0 c0 ⌉-------
q1(0) ⮕  ------------⌊ c0 c0 ⌋-------


Compilation of Entangler complete!

and to run the program:

entangler.run(graph = True)

and view bloch spheres for qubits:

plotbloch(HGATE * [0, 1])

Authors

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

quantumcomputingsim-1.0.7.tar.gz (14.1 kB view details)

Uploaded Source

File details

Details for the file quantumcomputingsim-1.0.7.tar.gz.

File metadata

  • Download URL: quantumcomputingsim-1.0.7.tar.gz
  • Upload date:
  • Size: 14.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.6

File hashes

Hashes for quantumcomputingsim-1.0.7.tar.gz
Algorithm Hash digest
SHA256 f85d3a98ae3424aa8860c2a6c6f0b17c0a3b4e8d905760b8205a2c1cba60fae7
MD5 4858451d70fcd7b20d4545b59908ad84
BLAKE2b-256 33135222cadca8a931170adedd3768587cd38e2995a137998c5b178619b90753

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