I'm looking at making a Function parser in C++ that will take sloppily written functions, clean them up, and evaluate them. Uses of this would include writing simple calculators, graphing calculators, and the like.

As I see it, there would be three main classes:
variables (constants, intrinsic, user defined)
functions (intrinsic, user defined, single & multi-argument, default-argument)
operators (intrinsic, user defined, precedence optionally set by user)

There should be some way to make additional evaluations of a given function (read: parse a function so that a smaller amount of work has to be done to evaluate it a second time).

Anything else you would want to add would be excellent. I am looking for people to give me ideas on what to include, and possibly people to help me code it. I will definately need some guidance on syntax. I have done a function parser in VB with some of the above capabilities, but I have a feeling C++ will be *slightly* faster. Not only that, but I have a feeling it is an excellent way to acquaint myself with the syntax used.