Skip to content

Qudit Computing | Quantum Simulations | PIP Package

License

Notifications You must be signed in to change notification settings

Ordoptimus/pyqudit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PyQudit

PyPIVersion Docs GitLanguage PyPIFormat PyPIImplementation GitIssues License

PyQudit is a Python package for using generalised and universal versions of quantum gates, in N-dimensions. Enables building simple quantum circuit simulations on qudit logic using higher dimensional gates.

Getting Started

Concept

Mainstream QuantumComputing uses qubits which operate in a two dimensional Hilber space. Qudits are their higher dimensional equivalents with better informaiton density and potential for higher efficiency. PyQudit includes the qudit versions of fundamental quantum gates, useable over any dimension* as specified by the user. It can be used to understand the behaviour of qudit gates as also to build higher dimensional circuits for experimentation.

*refer gate functions

Install

The latest stable version of PyQudit is available on PyPI and can be installed with pip. It is recommeded to install in your quantum computing python environment, alongside existing packages.

pip install pyqudit

Build Locally

Alternatively, you can build the package wheel from source and then install it via pip.

pip3 install --upgrade pip
pip3 install --upgrade setuptools
git clone https://github.com/Ordoptimus/pyqudit.git
cd pyqudit
python3 setup.py bdist_wheel

Replace [version] with the latest version as seen in the wheel file in /bdist_wheel

pip3 install dist/pyqudit-[version]-py3-none-any.whl

Use

import pyqudit.qudit as pq

Use dir(pq) to show all package methods.

Sample

>>> import pyqudit.qudit as pq
>>> d = int(input('Enter Dimensions: '))
Enter Dimensions: 3
>>> print("\n---CX's Pauli Matrix---")
>>> print(pq.CXd_pauli(d))
---CX's Pauli Matrix---
[[1 0 0 0 0 0 0 0 0]
 [0 1 0 0 0 0 0 0 0]
 [0 0 1 0 0 0 0 0 0]
 [0 0 0 0 0 1 0 0 0]
 [0 0 0 1 0 0 0 0 0]
 [0 0 0 0 1 0 0 0 0]
 [0 0 0 0 0 0 0 1 0]
 [0 0 0 0 0 0 0 0 1]
 [0 0 0 0 0 0 1 0 0]]

Documentation

Refer the official documentation for detailed examples and syntax.

About

Qudit Computing | Quantum Simulations | PIP Package

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages