hyqerionmath


Namehyqerionmath JSON
Version 0.3.0 PyPI version JSON
download
home_pageNone
SummaryA Python library with mathematical utility functions like isprime, get_nth_prime, and finding primes in ranges.
upload_time2025-04-07 15:06:14
maintainerNone
docs_urlNone
authorNone
requires_python>=3.7
licenseMIT License Copyright (c) 2025 Hyqerion199 Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
keywords math prime primality primes nth prime hyqerion utilities number theory
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # HyqerionMath

[![PyPI version](https://badge.fury.io/py/hyqerionmath.svg)](https://badge.fury.io/py/hyqerionmath) <!--Replace 'hyperionmath' if your PyPI name is different-->
[![Python versions](https://img.shields.io/pypi/pyversions/hyqerionmath.svg)](https://pypi.org/project/hyqerionmath/) <!-- Replace 'hyqerionmath' if your PyPI name is different -->
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT) <!-- Link assumes MIT License -->

A Python library providing supplementary mathematical utility functions, focusing on prime numbers.

## Overview

HyqerionMath aims to offer helpful, well-tested math functions that extend Python's built-in `math` module. It's designed to be simple, efficient, and easy to use, currently providing several functions for working with prime numbers.

## Features

HyqerionMath includes:

*   **`isprime(number: int) -> bool`**: Efficiently checks if a given integer `number` is a prime number. Returns `True` if prime, `False` otherwise. Raises `TypeError` for non-integer input.
*   **`get_nth_prime(n: int) -> int`**: Finds the *n*-th prime number (1-based index). e.g., `get_nth_prime(1)` is 2, `get_nth_prime(5)` is 11. Raises `TypeError` if `n` is not an integer, `ValueError` if `n` is not positive.
*   **`get_primes_in_index_range(start_index: int, end_index: int) -> List[int]`**: Returns a list containing primes from the `start_index`-th prime to the `end_index`-th prime (inclusive, 1-based). e.g., `get_primes_in_index_range(3, 6)` returns `[5, 7, 11, 13]`. Raises `TypeError` or `ValueError` for invalid indices.
*   **`find_primes_between(lower_bound: int, upper_bound: int) -> List[int]`**: Returns a sorted list of all prime numbers `p` such that `lower_bound <= p <= upper_bound`. e.g., `find_primes_between(10, 30)` returns `[11, 13, 17, 19, 23, 29]`. Raises `TypeError` for non-integer bounds. Returns an empty list if `upper_bound < 2` or `lower_bound > upper_bound`.

*(More features may be added in the future!)*

## Installation

You can install HyqerionMath directly from PyPI (once published):

```bash
pip install hyqerionmath

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "hyqerionmath",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.7",
    "maintainer_email": null,
    "keywords": "math, prime, primality, primes, nth prime, hyqerion, utilities, number theory",
    "author": null,
    "author_email": "Hyqerion <hyqerion199@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/9c/87/3df1563c39e94f68e39be7998f2eff590fe7bc5cfe1e26776a83396d2d3b/hyqerionmath-0.3.0.tar.gz",
    "platform": null,
    "description": "# HyqerionMath\r\n\r\n[![PyPI version](https://badge.fury.io/py/hyqerionmath.svg)](https://badge.fury.io/py/hyqerionmath) <!--Replace 'hyperionmath' if your PyPI name is different-->\r\n[![Python versions](https://img.shields.io/pypi/pyversions/hyqerionmath.svg)](https://pypi.org/project/hyqerionmath/) <!-- Replace 'hyqerionmath' if your PyPI name is different -->\r\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT) <!-- Link assumes MIT License -->\r\n\r\nA Python library providing supplementary mathematical utility functions, focusing on prime numbers.\r\n\r\n## Overview\r\n\r\nHyqerionMath aims to offer helpful, well-tested math functions that extend Python's built-in `math` module. It's designed to be simple, efficient, and easy to use, currently providing several functions for working with prime numbers.\r\n\r\n## Features\r\n\r\nHyqerionMath includes:\r\n\r\n*   **`isprime(number: int) -> bool`**: Efficiently checks if a given integer `number` is a prime number. Returns `True` if prime, `False` otherwise. Raises `TypeError` for non-integer input.\r\n*   **`get_nth_prime(n: int) -> int`**: Finds the *n*-th prime number (1-based index). e.g., `get_nth_prime(1)` is 2, `get_nth_prime(5)` is 11. Raises `TypeError` if `n` is not an integer, `ValueError` if `n` is not positive.\r\n*   **`get_primes_in_index_range(start_index: int, end_index: int) -> List[int]`**: Returns a list containing primes from the `start_index`-th prime to the `end_index`-th prime (inclusive, 1-based). e.g., `get_primes_in_index_range(3, 6)` returns `[5, 7, 11, 13]`. Raises `TypeError` or `ValueError` for invalid indices.\r\n*   **`find_primes_between(lower_bound: int, upper_bound: int) -> List[int]`**: Returns a sorted list of all prime numbers `p` such that `lower_bound <= p <= upper_bound`. e.g., `find_primes_between(10, 30)` returns `[11, 13, 17, 19, 23, 29]`. Raises `TypeError` for non-integer bounds. Returns an empty list if `upper_bound < 2` or `lower_bound > upper_bound`.\r\n\r\n*(More features may be added in the future!)*\r\n\r\n## Installation\r\n\r\nYou can install HyqerionMath directly from PyPI (once published):\r\n\r\n```bash\r\npip install hyqerionmath\r\n",
    "bugtrack_url": null,
    "license": "MIT License\r\n        \r\n        Copyright (c) 2025 Hyqerion199\r\n        \r\n        Permission is hereby granted, free of charge, to any person obtaining a copy\r\n        of this software and associated documentation files (the \"Software\"), to deal\r\n        in the Software without restriction, including without limitation the rights\r\n        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\r\n        copies of the Software, and to permit persons to whom the Software is\r\n        furnished to do so, subject to the following conditions:\r\n        \r\n        The above copyright notice and this permission notice shall be included in all\r\n        copies or substantial portions of the Software.\r\n        \r\n        THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\r\n        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\r\n        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\r\n        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\r\n        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\r\n        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\r\n        SOFTWARE.\r\n        ",
    "summary": "A Python library with mathematical utility functions like isprime, get_nth_prime, and finding primes in ranges.",
    "version": "0.3.0",
    "project_urls": null,
    "split_keywords": [
        "math",
        " prime",
        " primality",
        " primes",
        " nth prime",
        " hyqerion",
        " utilities",
        " number theory"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "55790da8317716b67ffaaf5f5392555559d71f01b57685da254ebcb95385436a",
                "md5": "6c42744ae8f87a07b20192b4af9fdc04",
                "sha256": "1ec73503929f34f11a6d380a6e334c35c2bbe4144f90469c15792e605cc6bbf1"
            },
            "downloads": -1,
            "filename": "hyqerionmath-0.3.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "6c42744ae8f87a07b20192b4af9fdc04",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.7",
            "size": 5862,
            "upload_time": "2025-04-07T15:06:13",
            "upload_time_iso_8601": "2025-04-07T15:06:13.021593Z",
            "url": "https://files.pythonhosted.org/packages/55/79/0da8317716b67ffaaf5f5392555559d71f01b57685da254ebcb95385436a/hyqerionmath-0.3.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "9c873df1563c39e94f68e39be7998f2eff590fe7bc5cfe1e26776a83396d2d3b",
                "md5": "3d9affcc03586cc892c370398e97aa8e",
                "sha256": "fa42a1a145a3e1fd03d0fbecf55800cde9c68a855fdb604d8edb275aee34edf3"
            },
            "downloads": -1,
            "filename": "hyqerionmath-0.3.0.tar.gz",
            "has_sig": false,
            "md5_digest": "3d9affcc03586cc892c370398e97aa8e",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.7",
            "size": 4925,
            "upload_time": "2025-04-07T15:06:14",
            "upload_time_iso_8601": "2025-04-07T15:06:14.357313Z",
            "url": "https://files.pythonhosted.org/packages/9c/87/3df1563c39e94f68e39be7998f2eff590fe7bc5cfe1e26776a83396d2d3b/hyqerionmath-0.3.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-04-07 15:06:14",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "hyqerionmath"
}
        
Elapsed time: 0.42689s