Login   Register  
PHP Classes
elePHPant
Icontem

Big Number Calculator: Add arbitrary precision numbers in pure PHP

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Info   View files View files (4)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Last Updated Ratings Unique User Downloads Download Rankings  
2009-04-15 (5 years ago) RSS 2.0 feedNot enough user ratingsTotal: 1,056 This week: 1All time: 3,271 This week: 1,442Up
Version License PHP version Categories  
bignumbercalculator 1.0GNU Lesser General Publ...5PHP 5, Math
Description Author  

This class can be used to add arbitrary precision numbers in pure PHP.

It takes two decimal numbers represented as strings of unlimited length and performs an addition digit by digit.

The result is another decimal number represented as a string.

Innovation Award  
PHP Programming Innovation award nominee
December 2006
Number 5


Prize: One subscription to the PDF edition of the magazine by PHP Architect
Arbitrary precision numbers can be used to perform mathematical operations without loosing the precision of the results.

PHP applications can use the bcmath extension to perform arbitrary precision operations. However, this extension is not always available in all PHP installations.

This class provides a pure PHP based solution to perform basic operations with arbitrary precision numbers. It can be used in environments where bcmath extension is not available.


Manuel Lemos
Picture of Protung Dragos
Name: Protung Dragos is available for providing paid consulting. Contact Protung Dragos .
Classes: 10 packages by
Country: Germany Germany
Age: 31
All time rank: 343 in Germany Germany
Week rank: 23 Up2 in Germany Germany Up
Innovation award
Innovation award
Nominee: 3x

  Files folder image Files  
File Role Description
Plain text file calculator.php Class Main class
Accessible without login Plain text file example.php Example Example of usage
Accessible without login Plain text file license.txt Lic. License file
Accessible without login Plain text file readme.txt Doc. Documentation

 Version Control Unique User Downloads Download Rankings  
 0%Total:1,056All time:3,271
 This week:1This week:1,442Up