qulib


Namequlib JSON
Version 0.2 PyPI version JSON
download
home_pageNone
SummaryNone
upload_time2024-10-20 22:59:50
maintainerNone
docs_urlNone
authorNone
requires_python>=3.6
licenseNone
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # qulib

qulib is a Python library designed for working with quantum computing gates and registers. It provides basic operations to create, manipulate, and work with quantum states and gates using Python.

## Features

- Simple interface built using NumPy.
- Handles application of gates.
- Two qbit gates include: SWAP, CNOT.

## Installation

You can install qulib using pip:

```bash
pip install qulib
```

Usage

Here’s a simple example of how to create a quantum register and apply a gate:

```python

from qulib import QRegister
from qulib.Gates import X

# Create a quantum register with 2 qubits
qreg = QRegister(2)

# Apply an X gate (NOT gate) to all the qubits
qreg.apply_gate(X())

# Display the basis states of the quantum register
print(qreg)

# Mesure the sates by firing shots
print(qreg.mesure(shots=1000))
```

Requirements
- Python 3.6+
- NumPy

## Running Tests

qulib uses pytest for testing. To run tests, install pytest and run:

```bash

pytest
```

## Contributing

Feel free to submit issues, fork the repository, and make pull requests. Contributions are welcome!



            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "qulib",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.6",
    "maintainer_email": null,
    "keywords": null,
    "author": null,
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/24/aa/93823878212d12c01938397bd30cc407712acbef0d40fca8adb492ea9c43/qulib-0.2.tar.gz",
    "platform": null,
    "description": "# qulib\n\nqulib is a Python library designed for working with quantum computing gates and registers. It provides basic operations to create, manipulate, and work with quantum states and gates using Python.\n\n## Features\n\n- Simple interface built using NumPy.\n- Handles application of gates.\n- Two qbit gates include: SWAP, CNOT.\n\n## Installation\n\nYou can install qulib using pip:\n\n```bash\npip install qulib\n```\n\nUsage\n\nHere\u2019s a simple example of how to create a quantum register and apply a gate:\n\n```python\n\nfrom qulib import QRegister\nfrom qulib.Gates import X\n\n# Create a quantum register with 2 qubits\nqreg = QRegister(2)\n\n# Apply an X gate (NOT gate) to all the qubits\nqreg.apply_gate(X())\n\n# Display the basis states of the quantum register\nprint(qreg)\n\n# Mesure the sates by firing shots\nprint(qreg.mesure(shots=1000))\n```\n\nRequirements\n- Python 3.6+\n- NumPy\n\n## Running Tests\n\nqulib uses pytest for testing. To run tests, install pytest and run:\n\n```bash\n\npytest\n```\n\n## Contributing\n\nFeel free to submit issues, fork the repository, and make pull requests. Contributions are welcome!\n\n\n",
    "bugtrack_url": null,
    "license": null,
    "summary": null,
    "version": "0.2",
    "project_urls": null,
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "4dbf93717dc76b40698ab093166bd5d1203d7ab421f57e2713baf06607cc3d53",
                "md5": "47e884e7e8baaf5f33d09842e40211e1",
                "sha256": "c77199ed26e2c627a3f16d0e0421a6eafb8c0f5612ff71cf339438ef8d48a047"
            },
            "downloads": -1,
            "filename": "qulib-0.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "47e884e7e8baaf5f33d09842e40211e1",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.6",
            "size": 4566,
            "upload_time": "2024-10-20T22:59:49",
            "upload_time_iso_8601": "2024-10-20T22:59:49.242445Z",
            "url": "https://files.pythonhosted.org/packages/4d/bf/93717dc76b40698ab093166bd5d1203d7ab421f57e2713baf06607cc3d53/qulib-0.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "24aa93823878212d12c01938397bd30cc407712acbef0d40fca8adb492ea9c43",
                "md5": "cc0b28046d8a707801c9c9ca73d311d7",
                "sha256": "a1fcf3c5f4bdb3a201ac1ab8683bbdce36eb6fd7da560b82d8f813ee27136614"
            },
            "downloads": -1,
            "filename": "qulib-0.2.tar.gz",
            "has_sig": false,
            "md5_digest": "cc0b28046d8a707801c9c9ca73d311d7",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.6",
            "size": 4124,
            "upload_time": "2024-10-20T22:59:50",
            "upload_time_iso_8601": "2024-10-20T22:59:50.855385Z",
            "url": "https://files.pythonhosted.org/packages/24/aa/93823878212d12c01938397bd30cc407712acbef0d40fca8adb492ea9c43/qulib-0.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-10-20 22:59:50",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "qulib"
}
        
Elapsed time: 0.64907s