Something I'd really like Math.js to do is to be able to simplify expressions.
Say I had "abx + c = y", I'd like to substitute values into a,b and c and get something like "5x - 1 = y" back. But Math.js won't allow you to have these kinds of "symbolic" variables in their expressions - trying to eval statements such as the ones above will just return an error saying x and y are undefined. Huge bummer in my view.
Anyone know about easy solutions to this problem? I may end up doing it server-side before I render the equations I need, but I'd really like to use someone else's open source project rather than try to figure this stuff out myself...
@nicolewhite algebra.js looks really interesting. I hadn't seen it before. Maybe we can somehow join forces (I'm the author or math.js). If you're interested just drop me a mail or open a discussion on github.
@pachydermic you can use math.parse("abx + c = y") which returns an expression tree. You can perform transformations on this tree. See docs: http://mathjs.org/docs/expressions/expression_trees.html. There is an early implementation of algebraic differentiation (not yet public): https://github.com/josdejong/mathjs/pull/411. Next step is to implement functions simplify and integrate. It all looks very promising.
Say I had "abx + c = y", I'd like to substitute values into a,b and c and get something like "5x - 1 = y" back. But Math.js won't allow you to have these kinds of "symbolic" variables in their expressions - trying to eval statements such as the ones above will just return an error saying x and y are undefined. Huge bummer in my view.
Anyone know about easy solutions to this problem? I may end up doing it server-side before I render the equations I need, but I'd really like to use someone else's open source project rather than try to figure this stuff out myself...