{"id":21056024,"url":"https://github.com/xp-framework/math","last_synced_at":"2026-01-04T18:05:52.897Z","repository":{"id":2858235,"uuid":"47654724","full_name":"xp-framework/math","owner":"xp-framework","description":"Big number handling","archived":false,"fork":false,"pushed_at":"2024-03-24T12:16:07.000Z","size":55,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-04-25T14:02:23.343Z","etag":null,"topics":["bc","math","php","xp-framework"],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/xp-framework.png","metadata":{"files":{"readme":"README.md","changelog":"ChangeLog.md","contributing":null,"funding":null,"license":null,"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}},"created_at":"2015-12-08T22:56:46.000Z","updated_at":"2021-10-21T15:22:25.000Z","dependencies_parsed_at":"2024-02-25T14:32:56.576Z","dependency_job_id":"46de68cf-6072-4c40-b1d0-6daa90aaa0ed","html_url":"https://github.com/xp-framework/math","commit_stats":null,"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xp-framework%2Fmath","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xp-framework%2Fmath/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xp-framework%2Fmath/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xp-framework%2Fmath/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/xp-framework","download_url":"https://codeload.github.com/xp-framework/math/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244931629,"owners_count":20534012,"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":["bc","math","php","xp-framework"],"created_at":"2024-11-19T16:48:21.439Z","updated_at":"2026-01-04T18:05:52.892Z","avatar_url":"https://github.com/xp-framework.png","language":"PHP","readme":"Math\n====\n\n[![Build status on GitHub](https://github.com/xp-framework/math/workflows/Tests/badge.svg)](https://github.com/xp-framework/math/actions)\n[![XP Framework Module](https://raw.githubusercontent.com/xp-framework/web/master/static/xp-framework-badge.png)](https://github.com/xp-framework/core)\n[![BSD Licence](https://raw.githubusercontent.com/xp-framework/web/master/static/licence-bsd.png)](https://github.com/xp-framework/core/blob/master/LICENCE.md)\n[![Requires PHP 7.4+](https://raw.githubusercontent.com/xp-framework/web/master/static/php-7_4plus.svg)](http://php.net/)\n[![Supports PHP 8.0+](https://raw.githubusercontent.com/xp-framework/web/master/static/php-8_0plus.svg)](http://php.net/)\n[![Latest Stable Version](https://poser.pugx.org/xp-framework/math/version.svg)](https://packagist.org/packages/xp-framework/math)\n\nBig number handling\n\nAPI: BigInt\n-----------\n\n```php\npublic class math.BigInt extends math.BigNum {\n  public math.BigInt __construct(int|float|string|parent $in)\n\n  public math.BigNum add(int|float|string|parent $other)\n  public math.BigNum subtract(int|float|string|parent $other)\n  public math.BigNum multiply(int|float|string|parent $other)\n  public math.BigNum divide(int|float|string|parent $other)\n  public math.BigNum add0(int|float|string|parent $other)\n  public math.BigNum subtract0(int|float|string|parent $other)\n  public math.BigNum multiply0(int|float|string|parent $other)\n  public math.BigNum divide0(int|float|string|parent $other)\n  public math.BigNum power(int|float|string|parent $other)\n  public math.BigNum modulo(int|float|string|parent $other)\n  public math.BigNum bitwiseAnd(int|float|string|parent $other)\n  public math.BigNum bitwiseOr(int|float|string|parent $other)\n  public math.BigNum bitwiseXor(int|float|string|parent $other)\n  public math.BigNum shiftRight(int|float|string|parent $shift)\n  public math.BigNum shiftLeft(int|float|string|parent $shift)\n  public int byteValue()\n  public int intValue()\n  public float floatValue()\n}\n```\n\nAPI: BigFloat\n-------------\n\n```php\npublic class math.BigFloat extends math.BigNum {\n  public math.BigFloat __construct(int|float|string|parent $in)\n\n  public math.BigNum add(int|float|string|parent $other)\n  public math.BigNum subtract(int|float|string|parent $other)\n  public math.BigNum multiply(int|float|string|parent $other)\n  public math.BigNum divide(int|float|string|parent $other)\n  public math.BigNum power(int|float|string|parent $other)\n  public math.BigFloat ceil()\n  public math.BigFloat floor()\n  public math.BigFloat round([int $precision= 0])\n  public int compare(int|float|string|parent $other, ?int $precision= null)\n  public bool equals(int|float|string|parent $other, ?int $precision= null)\n  public int intValue()\n  public float floatValue()\n}\n```","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxp-framework%2Fmath","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fxp-framework%2Fmath","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxp-framework%2Fmath/lists"}