Java Math expression evaluators

Very often in a corporate enivronment, you are in need of performing calculations; Be it in reports or general graphs. One is better off letting the business customer(who understands the business better) deciding on the calculations and changing these calculations. I had one such need in the last few days and where in symbols where involved. I wanted to store the calculations in the database and provide the customer with a UI. And then evaluate these mathematical expressions during run time. I ended up finding 3 mathematical expression evaluators in java and here they are

Each varying in complexity. JEP seems really cool and if u need really complex calculations that need to be performed than it works like a charm. For the simple calculations that you require Java Math expression evaluator seems good enough, which is what I decided to go with. Works really well.

The earlier perl implementation had calculations embeded in the code and these changed every year. Support this was a freaking pain in the rear end. Feels good not to touch the code and have the flexibility to change the calculations at the same time. Everyones happy πŸ™‚ 

BTW I did not look @ jbcparser as it needed to be purchased.

Advertisements

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s