Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/xethron/bignum

A smart wrapper for bcmath that allows
https://github.com/xethron/bignum

Last synced: 3 months ago
JSON representation

A smart wrapper for bcmath that allows

Awesome Lists containing this project

README

        

# Bignum library for PHP
[![codecov](https://codecov.io/gh/Xethron/bignum/graph/badge.svg?token=77SL86KV17)](https://codecov.io/gh/Xethron/bignum)

Intelligent wrapper for BCMath.

## Why use this library?
BCMath is a great library, but it has some shortfalls.
This library aims to address those shortfalls.

### Features
* Adds serialisation of numbers:
* Serialises Floats
* Serialises Strings
* Understands Scientific Notation
* Throws exceptions for invalid values
* Adds Rounding
* All results are rounded

## Installation
The recommended way to install this is through composer:

```bash
composer require "xethron/bignum"
```

## Usage
```php