davedelong/DDMathParser

Get parsed equation?

rmehta33 opened this issue · 3 comments

Hi,

Is there a way to return the "parsed" version of a string, and then evaluate that parsed form? Essentially I'm using this library to calculate values for a graph and since I'm usually only ever changing a variable or two, is there a way to do this efficiently?

Thanks

Yes, you'd create an Expression, which is the parsed form of the string. Once you have the Expression, you can ask it to evaluate, passing in any values for the variables the expression contains.

Perfect thanks!