| TIP: Click on subject to list as thread! | ANSI |
| echo: | |
|---|---|
| to: | |
| from: | |
| date: | |
| subject: | Converting infix to postfix |
Hello Mario!
Replying to a message of Mario Semo to Erik Huelsmann:
MS> a) The Art of Computer Programming. (Knuth). Part1 ?
MS> (Fundamental Algorithms). Page 336 talsk about preOrder, postOrder
MS> presentation of formulas extracted from the binary tree presentation
MS> of the formula.
MS> b) you have to parse the expression and build a parse tree and use
MS> postorder traversal methods.
I will check out your book recommendation. I think it will shed some light
on my case...
EH>> X*(X'*X)^(-1)*X'*y
EH>> X X ' X * -1 ^ X * y *
MS> to parse such expressions, i would use an LEX/YACC tool. I don't know
MS> if such a tool is available for Pascal. (the lexx/yacc i can write
MS> such a parser/scanner in a few lines of code).
I could probably get such a tool, but I don't know how to work them :-(, if
I would, I would probably have written a dll to stuff the parser in....
MS> But of course you can implement the parser for yourself. if you don't
MS> know how to write an lexical parser for an LR1 grammatic, i would
MS> suggest a book about compiler construction.
Figured this would be the fastest way, considering that I would have to
learn C for writing the dll...
MS> WARPED!, Mario
Bye, Erik!
*** I am slowly getting there, but Sibyl is getting me there faster :-)
*** Q's? e-mail me at ErikH{at}hcc-gron.idn.nl
---
* Origin: ORIGINal (2:500/19.1929)SEEN-BY: 50/99 270/101 620/243 711/401 409 410 413 430 808 809 934 955 SEEN-BY: 712/407 515 517 628 713/888 800/1 @PATH: 500/19 9 28/777 2/777 396/1 270/101 712/515 711/808 934 |
|
| SOURCE: echomail via fidonet.ozzmosis.com | |
Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.