Has anyone ever delved into computer algebra?

October 30, 2008 07:47AM
So I've written this parser program that will parse text containing an expression in infix notation and put it into a tree structure that resembles polish notation.

So, my program converts this:

6x+sin(2x+3)/(x^4-5)

into this:

+
*
6
x
/
sin
+
*
2
x
3
-
^
x
4
5


My question is this: how can I implement an algorithm to simplify the expression in the tree? For example

2+x+3 would evaluate to x+5
2x+6x would evaluate to 8x

I've looked all over the internet for algorithms to do this and such. I don't want to take the time to look through a huge open source program, and all the books on amazon that cover this stuff are over fifty bucks. Does anyone have any experience in this?
Subject Author Posted

Has anyone ever delved into computer algebra?

Tiberius Odgen October 30, 2008 07:47AM

Parse your set of vars

torak October 30, 2008 09:47AM

pretty much..

Jib October 30, 2008 10:41AM

Yes

Tiberius Odgen October 30, 2008 11:26AM

Three stacks

Rade October 30, 2008 12:51PM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 32
Record Number of Users: 2 April 29, 2024
Record Number of Guests: 258 May 03, 2024