{"id":15444541,"url":"https://github.com/cariad/vinculum","last_synced_at":"2025-03-28T08:13:56.464Z","repository":{"id":64497895,"uuid":"576200890","full_name":"cariad/vinculum","owner":"cariad","description":"Python package for large numbers with high precision","archived":false,"fork":false,"pushed_at":"2023-09-25T14:02:44.000Z","size":541,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-03T03:48:03.955Z","etag":null,"topics":["data-science","fractions","mathematics","python"],"latest_commit_sha":null,"homepage":"https://cariad.github.io/vinculum/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cariad.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"cariad"}},"created_at":"2022-12-09T08:46:44.000Z","updated_at":"2023-09-25T09:02:49.000Z","dependencies_parsed_at":"2024-10-01T19:41:45.063Z","dependency_job_id":null,"html_url":"https://github.com/cariad/vinculum","commit_stats":{"total_commits":20,"total_committers":1,"mean_commits":20.0,"dds":0.0,"last_synced_commit":"9247219627b68699bfcdf338893fa22babd18b9a"},"previous_names":[],"tags_count":13,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cariad%2Fvinculum","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cariad%2Fvinculum/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cariad%2Fvinculum/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cariad%2Fvinculum/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cariad","download_url":"https://codeload.github.com/cariad/vinculum/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245991585,"owners_count":20706129,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["data-science","fractions","mathematics","python"],"created_at":"2024-10-01T19:41:42.106Z","updated_at":"2025-03-28T08:13:56.403Z","avatar_url":"https://github.com/cariad.png","language":"Python","funding_links":["https://github.com/sponsors/cariad"],"categories":[],"sub_categories":[],"readme":"# Vinculum\n\n[![codecov](https://codecov.io/gh/cariad/vinculum/branch/main/graph/badge.svg?token=qo774jjX0W)](https://codecov.io/gh/cariad/vinculum)\n\n**Vinculum** is a Python package for handling large numbers with high precision.\n\n## Examples\n\nNumbers are recorded as rational fractions rather than floating-point decimals, so `1.2 - 1.0` really does equal `0.2`.\n\nUsing native `float`:\n\n```python\na = 1.2\nb = 1.0\nc = a - b\n\nprint(c)  # 0.19999999999999996\n```\n\nUsing Vinculum [`Rational`](https://cariad.github.io/vinculum/rational/):\n\n```python\nfrom vinculum import Rational\n\na = Rational.from_float(1.2)\nb = Rational.from_float(1.0)\nc = a - b\n\nprint(c)            # 1/5\nprint(c.decimal())  # 0.2\n```\n\nA `Rational` can be rendered to any arbitrary number of decimal places, but repeating digits will be noted and rendered with overhead dots:\n\n\n```python\nfrom vinculum import Rational\n\nprint(Rational(1146408, 364913).decimal(max_dp=999))\n# 3.141592653591403978482542414219279663919893234825835199074847977463121346731\n# 96076873117702027606580198567877822933137487565529317947017508282796173334466\n# 02340831924321687635134949974377454352133248198885761811719505745205021470871\n# 13914823533280535360483183662955279751612028072444664892727855680669090988811\n# 03167056257244877546154836906331098097354711945038954490522398489502977422015\n# 65852682694231227717291518800371595421374409790826854620142335296358310062946\n# 51053812826618947529959195753508370488308172084853101972250920082320991578814\n# 67637491676098138460400150172780909422245850380775691740223012060408919386264\n# 67130521521568154601233718721996749910252580752124478985401999928750140444434\n# 70087390693124114514966581075489226199121434424095606350006713929073505191648\n# 42030840227670705072167886592146621249448498683247787828879760381241556206547\n# 86209315645098968795301893876074571199162540112300740176425613776434382989918\n# 14487288751017365783077062203867771222181725507175682971009528298525950020963\n\nprint(Rational(1, 3).decimal())\n# 0.̇3\n```\n\nNote that the latter output is `0.̇3` with a dot and not `0.3`.\n\nFull documentation is online at **[cariad.github.io/vinculum](https://cariad.github.io/vinculum/)**.\n\n## Installation\n\n**Vinculum** requires Python 3.11 or later:\n\n```console\npip install vinculum\n```\n\n## Support\n\nPlease raise bugs, feature requests and ask questions at [github.com/cariad/vinculum/issues](https://github.com/cariad/vinculum/issues).\n\n## The Project\n\n**Vinculum** is \u0026copy; 2022-2023 Cariad Eccleston and released under the [MIT License](https://github.com/cariad/vinculum/blob/main/LICENSE) at [github.com/cariad/vinculum](https://github.com/cariad/vinculum).\n\n## The Author\n\nHello! 👋 I'm **Cariad Eccleston** and I'm a freelance backend and infrastructure engineer in the United Kingdom. You can find me at [cariad.earth](https://cariad.earth), [github/cariad](https://github.com/cariad), [linkedin/cariad](https://linkedin.com/in/cariad) and on the Fediverse at [@cariad@hachyderm.io](https://hachyderm.io/@cariad).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcariad%2Fvinculum","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcariad%2Fvinculum","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcariad%2Fvinculum/lists"}