There are quite a few algebra solvers and simplifiers on the web (for example, the decent one at algebra.com). However, I'm looking for something I can plug into C# as part of a larger project (I'm making my own calculator, but obviously I'd ask permission etc.).
Ideally, I'd use code like:
String s = MathLib.Simplify("5x*(500/x^2*(sqrt(3)/4)+1)+2x^2+(sqrt(3)/2)*x^2");
And 's' would simplify down to: "1082.532/x+5*x+2.866*x^2"
(3dp accuracy there, but one could change that if need be).
Solving for a particular variable would be nice too. I need something lightweight, and fast too (calculations such as the above would preferably be under 5ms or so including the startup latency).
After some research, programs like Sage, Octave or Mathematica are probably overkill (my app will only be a small <200k exe probably). Dotnumerics.com or Mathdotnet.com may be suitable, but the former doesn't seem to mention algebraic simplification, and the lack of documentation and examples in the latter is a turn off. I'm wondering if there are any appropriate alternatives as well. A large list can be found here: http://en.wikipedia.org/wiki/Comparison_of_computer_algebra_systems
sqrt
and on the right you round it to a 4 digit decimal. – Ormiston