Interpreted languages like Python, PHP, Ruby have an eval function that makes it easy to evaluate expressions. One common need in financial and scientific applications is to parse and evaluate formulas given as strings in compiled languages like C++, Java, C#, Pascal. This is a challenge even for experienced developers. It is immense effort to develop and test and can easily take weeks to write well tested proven code. Math Parser for Java parses and evaluates mathematical expressions with only a few lines of code. This package allows your users to enter a formula as a string, and instantly evaluate it. Math Parser for Java supports user defined variables, constants, and functions. A number of common mathematical functions and constants are included.
Small size (under 50KB as jar archive)
Fast parse and evaluation
Extendable and configurable architecture
Support for strings, vectors and complex numbers
Support for implicit multiplication
Optimization of constant sub-expressions
Allows declared or undeclared variables
Supports Boolean expressions, Excel like IF function
High precision using double
Includes common math functions and operators
Java 1.4 compatible
Supports i18n, translation
Extensive documentation
Math parser can be used in engineering, financial applications, games, anywhere you need the user enter a mathematical formula as a string to be parsed and evaluated.
Formula parser's internal logic can be externalized and it can be used to represent the parsed tree structure of a mathematical expression for visualization, education purposes.
Math parser comes for many languages:
JbcParser is Math parser for Java
bcParserX is the Math Expression parser COM component to parse and evaluate expressions in COM compatible languages such as Visual C++, Visual Basic and .NET
bcParser.NET is the Math Parser for .NET platform. It is implemented in C#.
TbcParser is Math Parser for Delphi, C++ Builder
Visit bestcode.com for more information on math parser libraries for many languages.
|