Re: TI Programmers: I'm BEGGING you to write a symbolic ma


[Prev][Next][Index][Thread]

Re: TI Programmers: I'm BEGGING you to write a symbolic manipulation program . . .



On Wed, 01 Oct 1997 22:48:10 GMT, mja@algonet.se (Jimmy Merdell)
wrote:

>On Wed, 01 Oct 1997 20:34:13 GMT, jeffreyd@voicenet.com (Richard)
>wrote:
>
>>Not really. To do a derivated all you need to do is read the equation
>>into a tree, take the derivative of the tree working down(performing
>>the chain rule alot!) and then simplify. The simplify is probably the
>>hardest part. If I was better at asm and had more free time, I would
>>probably try it myslef.
>>
>>Integrals on the other hand...
>
>Derivate isn't very hard, but as you say, integrals is a bitch. And
>simplifying won't get easy either. A very important thing you need
>to think about before making a symbolc manipulation program
>is HOW should an expression be stored? For example, how
>would you store the expression
>
> 5x+Sqrt(e^(5+x))/(3x^3-2x^2+3)+pi/4
>
>The format of an expression is, I think, the first thing you should
>consider when making a symbolc manipulation program. And
>then create routines to manipulate with such an expression -
>NOT easy at all.
>
>Jimmy Merdell <mja@algonet.se>
>http://www.algonet.se/~mja
>IRC: Yarin

An expression should be held in a binary tree.  all the non leaf nodes
are operands and the leaves are either a variable or constant. As an
example:

3 * cos( X ^ X ) is

                *

        /               \

        3               cos

                        |

                        ^

                /               \

                X               X

simplification involve checkin for a long list of things such as are
there to * exponents with the same base, multiplying two constants or
two of the same variable together. there are alot of cases, but the
algorithms for each are fairly simple.


Richard


References: