Skip to main content

QForestMath

A small wrapper for basic arithmetic operations using QISkit.

Installation

Install QForestMath using pip, the python package management tool: pip install QForestMath

Prerequisites

Please ensure that you have qiskit installed before you try to run any programs using QForestMath, as all functionality involves the use of various qiskit modules such as QuantumRegister, ClassicalRegister, and CompostiteGate.

Getting Started

Functions:

add.add(addend, addend, circ)

subtract.subtract(minuend, subtrahend, circ)

multiply.multiply(multiplicand, multiplier, accumulator, ancillary, circ, anc_index)

divide.divide(dividend, divisor, accumulator, ancillary, circ, anc_index)

Description

QForestMath abstracts the process of constructing quantum circuits for elementary arithmetic operations by substituting them with function calls.

Every function in the library is meant to be used as a smaller part of a larger quantum circuit, and hence does not return any values, but simply adds an appropriate gate sequence to the QuantumCircuit object's QASM string.

The addition and subtraction functions are implemented using the quantum Fourier transform, and the multiplication and division functions are implemented using repeated addition and subtraction, repsectively. The GCD function uses a combination of these operations to acheive the equivalent result.

Authors

Akash Rao Mohit Gaggar Sashwat Anagolum

License

This project is licensed under the MIT License.

Metadata

Release files for QForestMath 0.0.4

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

Source distribution (sdist)

Source distribution for QForestMath 0.0.4
File Size Uploaded
QForestMath-0.0.4.tar.gz 4.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for QForestMath 0.0.4
File Interpreter ABI Platform
QForestMath-0.0.4-py3-none-any.whl Python 3 none any Details

Total release size: 11.9 kB

Release files / QForestMath-0.0.4.tar.gz

Download URL QForestMath-0.0.4.tar.gz
Size 4.2 kB
Tags Source
SHA-256 checksum
How to use checksums
f0a0fd21ace19419796691b7070dd0da8e1ae73c988839c45b81e12875304371
BLAKE2b-256 checksum
How to use checksums
c5fbc6019d8c1b590290c30dfdd43ea5278b84f069cca518c423635a2d18b386
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.12.1 pkginfo/1.4.2 requests/2.19.1 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.6

Release files / QForestMath-0.0.4-py3-none-any.whl

Download URL QForestMath-0.0.4-py3-none-any.whl
Size 7.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
1a27ce57576b1622192b1c249b6bbe243064c5c176b32fe8668eb78e98807f33
BLAKE2b-256 checksum
How to use checksums
8c8cdca0745a8763d219c1169b3b9586932c8761c7ec78e012cd62a13a53d27f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.12.1 pkginfo/1.4.2 requests/2.19.1 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.6

Release history Release notifications | RSS feed

This release

0.0.4 This release

2 release files

0.0.2

2 release files

0.0.1

2 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