PHP Classes
elePHPant
Icontem

Expressions: Parse, convert and evaluate math expressions

Recommend this page to a friend!
  Info   View files View files (9)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Last Updated Ratings Unique User Downloads Download Rankings
2012-07-08 (4 years ago) RSS 2.0 feedNot enough user ratingsTotal: 345 This week: 1All time: 6,654 This week: 1,047Up
Version License PHP version Categories
expressions 1.0BSD License5.0Algorithms, PHP 5, Math
Description Author

This package can parse, convert and evaluate math expressions.

There is a convertor class that can parse a string with a math expression with infix format (operators in the middle of the operands) to postfix format (operators after operands), as well to expression tree of objects.

An evaluator class can evaluate a math expression from a postfix string or expression or an expression tree of objects.

Currently the evaluation supports addition, subtraction, multiplication and division of integer operator numbers, as well parenthesis to group expressions to be evaluated first.

Picture of Alex Dan
Name: Alex Dan <contact>
Classes: 1 package by
Country: Romania Romania

  Files folder image Files  
File Role Description
Files folder imageConfig (2 files)
Files folder imageLib (1 file, 1 directory)
Accessible without login Plain text file main.php Example Expression Example script

 Version Control Unique User Downloads Download Rankings  
 0%
Total:345
This week:1
All time:6,654
This week:1,047Up