Skip to main content

Object-oriented continued fractions with Python.

Project description

CI CodeQL Analysis Codecov Ruff pdm-managed License: GPL v3 Docs PyPI version Downloads

continuedfractions

A simple extension of the Python fractions.Fraction standard library class for working with (finite, simple) continued fractions as Python objects.

Install from PyPI:

pip install -U continuedfractions

or the main branch of this repo:

pip install -U git+https://github.com/sr-murthy/continuedfractions

The documentation now consists only of an API reference. All other previous documentation has been removed to reduce maintenance.

The continuedfractions package is aimed at users interested in:

  • working with (finite, simple) continued fractions as Python objects, in an intuitive object-oriented way
  • making stateful computations involving key properties such as elements/coefficients, convergents, semiconvergents, remainders, and others
  • operating on them as rationals and instances of the fractions.Fraction standard library class
  • testing approximations for irrational numbers
  • exploring other related objects such as rational points in the plane, enumerations of rational numbers, mediants, and special sequences of rational numbers such as Farey sequences

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

continuedfractions-1.12.0.tar.gz (59.5 kB view details)

Uploaded Source

Built Distribution

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

continuedfractions-1.12.0-py3-none-any.whl (61.3 kB view details)

Uploaded Python 3

File details

Details for the file continuedfractions-1.12.0.tar.gz.

File metadata

  • Download URL: continuedfractions-1.12.0.tar.gz
  • Upload date:
  • Size: 59.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.11

File hashes

Hashes for continuedfractions-1.12.0.tar.gz
Algorithm Hash digest
SHA256 784be183fab3ac308b26200dd305b64df6bcd475a2edc8245a4eb17469c5a4ec
MD5 20c98c55f0e5d8ed57f4a87e35b44d8e
BLAKE2b-256 079c3046651c4099cfa91c7fe33827fc4d6ecf7683d0613e0aa4843b62391eb1

See more details on using hashes here.

File details

Details for the file continuedfractions-1.12.0-py3-none-any.whl.

File metadata

File hashes

Hashes for continuedfractions-1.12.0-py3-none-any.whl
Algorithm Hash digest
SHA256 438dad4d1a2eed8cc32c8fcad1e4681f30a857f8ee0c8fc094abe220eb5a6c47
MD5 badecb84054047a2882fcecae29cca0f
BLAKE2b-256 5bd4dbb4dbcc485f605224eb8be5e2b2ded4f002701c4a83ecb6fee0b2b6bc2b

See more details on using hashes here.

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