xsamx

44 Reputation

2 Badges

18 years, 181 days

MaplePrimes Activity


These are questions asked by xsamx

I'm continuing to work on my Maplet with the question bank, and can succesfully read in files outside of the Maplet using the readline command and parse. However, this is limiting in the fact that the user has to type in the name of the file in a Maple command line. I would like to use the FileDialog to have them select the file with the questions and answers. It's easy to use RunDialog with to run the FileDialog, but once they've selected the file, how can I assign that "string," say, ["E:\questionbank.txt"] to a variable that I can use outside of the actual Maplet code? I need to throw it to the readline procedure I created so it can read each line and parse them, etc.
My goal is to have users question banks in text files, and then read the data (both text and Maple procedures) in, through the readline function. The problem is, when I use that function, they come out as strings. For instance, if the first line of my file default.txt is diff(x^2,x) then the command readline("default.txt"); will display "diff(x^2,x)" I've tried using the convert function, but I can't find a type that will change it to a procedure. convert(aString,symbol) puts it as a symbol, but when I assign a variable to that symbol all it does it spit the symbol back out, it doesn't execute it. And if I use type(aString,procedure), it makes a procedure which displays the string. I need to remove the double quotes somehow and turn what's inside into a full-fledged Maple procedure. Any ideas?
How would I go about doing this? cat() doesn't seem to work well inside MathML[Export], and I can't think of a way to insert spaces, so text would run up against each other, like findthederivativeofx^2 Right now I'm using a text box above and seperate MathMLViewer below for the symbols, but I would really like to combine them into one. Any ideas? Thanks.
1) How do I view the source code of, say, (Student[Calculus1][AntiderivativeTutor])(); 2) I'm using a Maplet where a student will enter an expression into a MathMLEditor. I then want to compare this expression to one that the computer has already generated, to see if they can identify the inside function in a composite function, for instance. Once they enter their expression into the Editor, I use a Get command to extract it, and MathML[Import] to turn it into Maple expression to compare it with the computer-generated one. This works fine with functions like 1/x^9 (which you can type in easily into the editor), but really causes problems with ln(x) or sin(x). If you type in "sin(x)" into the Editor, MathML[Import] will interpret that as
When using the Plotter element in a Maplet, one of the options is (copied from the help file): delay = posint The delay in milliseconds between frames. The default value for this option is 100. So far, if I set this above 1000, the animation will not play. 1000 works and anything below it. Does this mean I cannot have my animation play slower than one second intervals between frames? If this is the upper limit, does anyone have a suggestion for how to get around this? One thing I was thinking was using the Student[Calculus1][ApproximateInt] command (this is what I'm animating) with the partition value set at different intervals corresponding to a function, t, 2*t, 4*t, etc., just like the actual animation does. But I could have my plotter updated manually using a time delay function that Will gave me previously on here. That's a lot of extra code, though; delaying the plot speed even more would work much better.
1 2 Page 1 of 2