Just Enough Maple for CalculusWorksheet by Mike May, S.J. - maymk@slu.eduEdited by Russell Blyth - blythrd@slu.eduThis worksheet is intended to give you just enough Maple to let you run the Maple worksheets for Calculus. We start with worksheets and move to documents later.Click on the first gray triangle to get started (clicking on the triangles toggles sections opened and closed).Executing sections:The Maple worksheets contain executable lines where Maple does mathematics. These lines begin with a red input prompt (a ">"). To execute a command or group of commands, place the cursor anywhere in the command line or lines and hit the "enter" or "return" key. Maple will execute the code and move the cursor down to the next input section.Execute the code sections below now.QyY+SSdhbnN3ZXJHNiItSSIrRyUqcHJvdGVjdGVkRzYkIiIiRipGKkYkRio=QyQ+SShhbnN3ZXIyRzYiLCYtSSJeRyUqcHJvdGVjdGVkRzYkIiIjRisiIiIjIiIkIiIlRixGLA==answer3 := 2^2+3/4;Notice that in Maple commands end with a semicolon and values are assigned to a variable with the ":=" symbol. You should also notice that the Maple input can either appear in a 1-D (like you would type into a calculator, for example, the answer3 input line) or a 2-D layout (like you would write on a piece of paper, for example, the answer2 input line).LUklbXJvd0c2Iy9JK21vZHVsZW5hbWVHNiJJLFR5cGVzZXR0aW5nR0koX3N5c2xpYkdGJzYjLUkjbWlHRiQ2JVEhRicvJSdpdGFsaWNHUSV0cnVlRicvJSxtYXRodmFyaWFudEdRJ2l0YWxpY0YnTyping in commands:Since this is a math course, the worksheets you do will have exercises embedded in them. You need to be able to type in your own commands. By default, Maple puts the mathematics you type into the standard arrangement you would use writing by hand (that is, Maple defaults to 2-D mode). One starts a power with the ^ (shift 6) key, and uses the right arrow to get out of the exponent and also to get out of the denominator of a fraction. At the input prompts below, enter the commandsmyanswer := 1 + 2;myanswer2 := LUklbXJvd0c2Iy9JK21vZHVsZW5hbWVHNiJJLFR5cGVzZXR0aW5nR0koX3N5c2xpYkdGJzYnLUkjbWlHRiQ2JVEhRicvJSdpdGFsaWNHUSV0cnVlRicvJSxtYXRodmFyaWFudEdRJ2l0YWxpY0YnLUklbXN1cEdGJDYlLUkjbW5HRiQ2JFEiM0YnL0YzUSdub3JtYWxGJy1GOTYkUSIyRidGPC8lMXN1cGVyc2NyaXB0c2hpZnRHUSIwRictSSNtb0dGJDYwUScmcGx1cztGJ0Y8LyUmZmVuY2VHUSZmYWxzZUYnLyUqc2VwYXJhdG9yR0ZKLyUpc3RyZXRjaHlHRkovJSpzeW1tZXRyaWNHRkovJShsYXJnZW9wR0ZKLyUubW92YWJsZWxpbWl0c0dGSi8lJ2FjY2VudEdGSi8lJWZvcm1HUSZpbmZpeEYnLyUnbHNwYWNlR1EwbWVkaXVtbWF0aHNwYWNlRicvJSdyc3BhY2VHRmZuLyUobWluc2l6ZUdRIjFGJy8lKG1heHNpemVHUSlpbmZpbml0eUYnLUkmbWZyYWNHRiQ2KC1GOTYkUSI0RidGPC1GOTYkUSI1RidGPC8lLmxpbmV0aGlja25lc3NHUSIxRicvJStkZW5vbWFsaWduR1EnY2VudGVyRicvJSludW1hbGlnbkdGXXAvJSliZXZlbGxlZEdGSi1GRTYwUSI7RidGPEZIL0ZMRjFGTUZPRlFGU0ZVRlcvRmVuUSQwZW1GJy9GaG5RL3RoaWNrbWF0aHNwYWNlRidGaW5GXG8=to assign the value of 3 to the variable myanswer and 49/5 to myanswer2. (Notice that there is no space in myanswer.)QyQ+SSlteWFuc3dlckc2Ii1JIitHJSpwcm90ZWN0ZWRHNiQiIiIiIiNGKg==QyQ+SSlteWFuc3dlckc2IiwmLUkiXkclKnByb3RlY3RlZEc2JCIiJCIiIyIiIiMiIiUiIiZGLUYtSometimes you will want to type the input in using 1-D mode. (You can tell which mode you are in by looking at the cursor. The cursor slants, like italics, in 2-D mode, and is straight up and down in 1-D mode. Put your cursor on the prompt below, switch to Maple input mode with the Insert menu, and enter the commandmyanswer3 := 3^2+4/5;LUklbXJvd0c2Iy9JK21vZHVsZW5hbWVHNiJJLFR5cGVzZXR0aW5nR0koX3N5c2xpYkdGJzYjLUkjbWlHRiQ2JVEhRicvJSdpdGFsaWNHUSV0cnVlRicvJSxtYXRodmFyaWFudEdRJ2l0YWxpY0YnFor some of the exercises you will want to use a series of commands. This raises two practical questions:1) How do you put more than one command line in a section with a single input prompt? (Hitting return executes the line.)2) How do you insert more input prompts in the middle of a worksheet?The easiest way to put two lines of input in a single prompt is to start in 1-D Maple input mode, and type a shift-return at the end of the first line. You can also start in 2-D mode, shift to 1-D mode, type shift return, then return to 2-D mode.You insert a new input prompt by either going to the Insert menu, and choosing "Execution Group...", then "After Cursor", or by typing flower-J (control-J on a PC), where "flower" is the Mac command key.Enter the command sequence:answer1 := 1 +3;answer1;on two lines at the single cursor below. Then insert two execution groups below it and reenter the commands in separate execution groups.Adding text:When doing mathematics exercises, it is important to answer the question asked, rather than simply showing some uninterpreted computations. Raw Maple output will never be considered a sufficient answer. Thus you need to be able to add explanatory comments to your computations, even if it is simply, "The answer is ..."To add a text section, either insert an execution group and convert it to text with flower-t (control-t on a PC), or use the Insert menu to insert a Text paragraph.Annotate your work in the previous section with the comment that "1 + 3 = 4".LUklbXJvd0c2Iy9JK21vZHVsZW5hbWVHNiJJLFR5cGVzZXR0aW5nR0koX3N5c2xpYkdGJzYjLUkjbWlHRiQ2JVEhRicvJSdpdGFsaWNHUSV0cnVlRicvJSxtYXRodmFyaWFudEdRJ2l0YWxpY0YnCutting and Pasting:Some of the exercises involve adapting several lines of code from a prior example, with only minor modifications. Obviously you could retype everything, but that is too much work. The easier method is to highlight the material you want to copy, copy it with either the Copy command from the Edit menu or the flower-c (control-c on a PC) key, move the cursor to where you want the material put, paste the material in with either the Paste command from the Edit menu or the flower-v (control-v on a PC) key, edit the changes you wantCopy the two command line section that assigns a value to answer1 above. Paste it in below and modify it to assign a value to answer2.Saving and printing:When you start a prepared worksheet, you should get a warning message that the worksheet is locked and changes cannot be saved. Instead you should choose "save as" from the file menu, pick a new name for the worksheet (a name that identifies the worksheet as yours), and save your work. You should then print the worksheet so that you can turn it in.LUklbXJvd0c2Iy9JK21vZHVsZW5hbWVHNiJJLFR5cGVzZXR0aW5nR0koX3N5c2xpYkdGJzYjLUkjbWlHRiQ2JVEhRicvJSdpdGFsaWNHUSV0cnVlRicvJSxtYXRodmFyaWFudEdRJ2l0YWxpY0YnYou may sometimes have problems printing a Maple file. (This is most likely to happen if the file has lots of complicated graphics.) It is then useful to export the Maple file to another application and print from the other format. We will look at turning the worksheet into a web page that can be printed from a web browser. 1) Go to the desktop of your machine and make a new folder. Label it MapleForWeb.2) From Maple, go to the File menu and select "Export as, HTML..."3) Save the file in the folder with an appropriate name.4) Open the HTML file in a browser and print from there.LUklbXJvd0c2Iy9JK21vZHVsZW5hbWVHNiJJLFR5cGVzZXR0aW5nR0koX3N5c2xpYkdGJzYjLUkjbWlHRiQ2JVEhRicvJSdpdGFsaWNHUSV0cnVlRicvJSxtYXRodmFyaWFudEdRJ2l0YWxpY0YnLUklbXJvd0c2Iy9JK21vZHVsZW5hbWVHNiJJLFR5cGVzZXR0aW5nR0koX3N5c2xpYkdGJzYjLUkjbWlHRiQ2JVEhRicvJSdpdGFsaWNHUSV0cnVlRicvJSxtYXRodmFyaWFudEdRJ2l0YWxpY0Yn