jmdavis@ihuxy.UUCP (Davis) (11/07/86)
I have written a program in machine language (for the APPLE) that calls the BASIC parsing and evaluation routines so that I am able to type in a function through an INPUT statement and evaluate it as though the function was entered as a DEF FN statement. (There are some important differences, see below). I have a need for a similar feature for the IBM PC. Such a program would allow someone to enter a function through an INPUT statement and have the BASIC program plot the function (for example). The advantage of this method over modifying the BASIC program to take the function and insert it into the BASIC program appending a DEF FN infront of it is that any change to a BASIC program erases current values of the variables (at least in APPLESOFT). This is UNDESIRABLE for a plotting program since the graphing parameters would need to be re-entered everytime the function was changed. Please send any thoughts that you might have on how to do this to me via E-Mail (since I rarely read this group). The answer does not need to be executable in BASIC but a BASIC solution is desirable for ease of porting. ( I hear that Turbo-Pascal has/sells a function evaluation package.) If there is sufficient interest if how to do this then I will post solutions to the net. Thanks Mike Davis ihnp4!ihuxy!jmdavis