Skip to main content

Mini OEIS in Python with PARI/GP support

Project description

oeis-code

CI codecov PyPI version Python versions Package format License: MIT

Mini OEIS in Python with PARI/GP support.

Installation

pip install oeis-code

PARI/GP Support (Optional)

To use the PARI/GP backend, you need cypari2. Note that this requires PARI/GP development headers installed on your system.

Debian/Ubuntu:

sudo apt install build-essential python3-dev libgmp-dev libpari-dev pari-gp
pip install cypari2

Fedora:

sudo dnf install pari-devel
pip install cypari2

macOS (using Homebrew):

brew install pari
pip install cypari2

Usage

from oeis_code import get

# Get the 10th Fibonacci number
get("A000045", 10)  # Returns 55

Contributing

  • Create a new file in oeis_code/sequences/
  • Use the @register("Axxxxxx") decorator
  • Implement the sequence(n) function

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

oeis_code-0.1.0.tar.gz (7.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

oeis_code-0.1.0-py3-none-any.whl (9.0 kB view details)

Uploaded Python 3

File details

Details for the file oeis_code-0.1.0.tar.gz.

File metadata

  • Download URL: oeis_code-0.1.0.tar.gz
  • Upload date:
  • Size: 7.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for oeis_code-0.1.0.tar.gz
Algorithm Hash digest
SHA256 fb86023e475513721a485caaa1e82266f9652e788ab65080f5a0df1192aef4a1
MD5 28126194c79584ae7c4bd7399f2e92c4
BLAKE2b-256 9cebd95361693e5788ab047d0e1ba81b38c6f25b2b771f7ea4397dc23d23db4a

See more details on using hashes here.

Provenance

The following attestation bundles were made for oeis_code-0.1.0.tar.gz:

Publisher: publish.yml on oeistools/oeis-code

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file oeis_code-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: oeis_code-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 9.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for oeis_code-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 8d6cf07b935beaa2bf6d39a0853256221f953db777892a77c14f8813c5ba05ce
MD5 66c355d7452c50e0186ccc9fc9f8eadf
BLAKE2b-256 2392f9f80656755fc890e3f374cf9bff87e1d1fcdee1c90cdcedf83c9d09e233

See more details on using hashes here.

Provenance

The following attestation bundles were made for oeis_code-0.1.0-py3-none-any.whl:

Publisher: publish.yml on oeistools/oeis-code

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page