{VERSION 3 0 "IBM INTEL NT" "3.0" } {USTYLETAB {CSTYLE "Maple Input" -1 0 "Courier" 0 1 255 0 0 1 0 1 0 0 1 0 0 0 0 }{CSTYLE "" -1 256 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 } {CSTYLE "" -1 257 "" 0 14 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 258 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 259 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 260 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 261 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 262 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 263 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 264 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 265 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 }{CSTYLE "" -1 266 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 267 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 268 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 269 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 270 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 271 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 272 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 }{CSTYLE "" -1 273 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 274 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 275 "" 0 1 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0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 }0 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "M aple Output" 0 11 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 }3 3 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 11 12 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 }1 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }} {SECT 0 {EXCHG {PARA 0 "" 0 "" {TEXT 295 31 "PLOTTING TWO DIMENSIONAL \+ GRAPHS" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 147 "We have to start by loading the packages that allow us to graph f unctions and equations. Just put the cursor after the semicolon and p ress return:" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 12 "with(plots);" }}{PARA 12 "" 1 "" {TEXT -1 0 "" } }}{EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 0 " " }}{PARA 0 "" 0 "" {TEXT -1 113 "Suppose we are given a function, say y = f(x), to graph. The Maple syntax for graphing a function is as f ollows:" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 18 " plot(" }{TEXT 258 15 "expression_in_x" }{TEXT -1 3 ", " }{TEXT 260 0 "" }{TEXT -1 2 "x=" }{TEXT 261 24 "lower limit..upper limit" }{TEXT -1 2 ");" }}{PARA 0 "" 0 "" {TEXT 259 0 "" }}{PARA 0 " " 0 "" {TEXT -1 21 "where you supply the " }{TEXT 262 17 "expression_i n_x, " }{TEXT -1 4 "the " }{TEXT 263 12 "lower limit," }{TEXT -1 9 " a nd the " }{TEXT 264 11 "upper limit" }{TEXT -1 117 ". Note that the e xpression is separated from the limits on x by a comma, and that the c ommand ends with a semicolon." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }} {PARA 0 "" 0 "" {TEXT -1 76 "Let's try graphing the function y = x^3/( x^4 + 1) over the interval [-3, 3]." }}{PARA 0 "" 0 "" {TEXT -1 0 "" } }}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 26 "plot(x^3/(x^4+1),x=-3..3); " }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 133 "Note that Maple automatically chooses an appropriate range for y. If we want to specify a range for y, we may include the code 'y = " }{TEXT 275 11 "lower limit" }{TEXT -1 4 " .. " }{TEXT 276 11 "upper li mit" }{TEXT -1 88 "' after the range for x. Be sure to separate the x range from the y range with a comma." }}{PARA 0 "" 0 "" {TEXT -1 0 " " }}{PARA 0 "" 0 "" {TEXT 277 23 "For your information: " }{TEXT -1 347 "If you graph a function that includes discontinuities, Maple will try to \"connect\" the branches of the graph (in much the same way as your graphing calculator). If you want the see the graph without the asymptotes, you can include in the 'plot' command the phrase 'discont = true'--remember to separate the pieces of the plot command with com mas." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }{TEXT 287 0 "" }{TEXT 288 11 "Polar P lots" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 245 " We may also use Maple to graph polar equations as well. (Note: The G reek characters are not available in Maple as characters--we have to s pell out the word; ie, we will use 'theta' to represent that Greek cha racter.) Suppose we want to graph:" }}{PARA 0 "" 0 "" {TEXT -1 0 "" } }{PARA 0 "" 0 "" {TEXT -1 76 " \+ r = 1 + 4 cos 5(theta)" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 234 "for theta = 0 to theta = 2 Pi. IMPORT ANT: Maple uses Pi to represent the mathematical constant 3.14159.... and pi to represent the Greek letter. If you want to refer to the nu mber 3.14159... you must use Pi with a capital letter. " }{TEXT 265 366 "(NOTE: Multiplication in Maple must be defined explicitly; ie, ' xy' will be interpreted by Maple as a single variable name, while 'x*y ' will be interpreted by Maple as the variable x times the variable y. The same is true with numbers and letters: '5x' will be interpreted as a variable name, while '5*x' will be interpreted as the number 5 t imes the variable x.)" }{TEXT -1 41 " What happens if we input the fo llowing?" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 37 "plot(1+4*cos(5*Theta),Theta=0..2*Pi);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 173 "This didn't gi ve us the expected polar graph. Maple interprets the \"plot\" command as a rectangular graph. To graph polar coordinates, we use 'polarplo t' instead of 'plot':" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 42 "polarplot(1+4*cos(5*Theta),Theta=0. .2*Pi);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 13 "Much better!!" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 " " {TEXT -1 0 "" }{TEXT 289 0 "" }{TEXT 290 0 "" }{TEXT 291 16 "Paramet ric Plots" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 105 "Maple also graphs parametric equations. Suppose we have a set of parametric equations given in the form:" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 38 " \+ x = " }{TEXT 268 4 "x(t)" }}{PARA 0 "" 0 "" {TEXT -1 38 " \+ y = " }{TEXT 269 4 "y(t)" }}{PARA 0 "" 0 "" {TEXT -1 43 " from t = " }{TEXT 266 12 "lower limit " }{TEXT -1 7 "to t = " }{TEXT 267 12 "upper limit." } {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 82 "We can use the 'plot' command, with a slight difference. The s yntax has the form:" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 " " {TEXT -1 24 " plot( [ " }{TEXT 270 12 "x(t), y(t), " }{TEXT -1 4 "t = " }{TEXT 271 27 "lower limit .. upper limit " }{TEXT -1 4 "] );" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 48 "(Note: The extra spaces are not necessary, but " }{TEXT 272 33 "the square brackets are required." }{TEXT -1 1 ")" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 13 "Try graphing:" }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 45 " \+ x = 6 sin 3t" }}{PARA 0 "" 0 "" {TEXT -1 44 " \+ y = 8 cos t" }}{PARA 0 "" 0 "" {TEXT -1 50 " t = 0 to t = 2 Pi" }}{PARA 0 " " 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 117 "Don't forget to p ut in '*' for multiplication any time you intend to multiply. The syn tax for the trig functions is:" }}{PARA 0 "" 0 "" {TEXT -1 36 " \+ sin(" }{TEXT 273 10 "expression" }{TEXT -1 14 ") cos(" }{TEXT 274 10 "expression" }{TEXT -1 12 ") e tc." }}{PARA 0 "" 0 "" {TEXT -1 55 "Replace the ??? below with the app ropriate expressions." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 27 "plot([?? ?,???,t=???..???]);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }{TEXT 292 0 "" }{TEXT 293 0 "" }{TEXT 294 37 "Plot ting Functions Defined Implicitly" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }} {PARA 0 "" 0 "" {TEXT -1 95 "Next, suppose we have a function defined \+ implicitly. The syntax for the command is as follows:" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 37 " \+ implicitplot(" }{TEXT 278 19 "equation in x and y" }{TEXT -1 6 ", \+ x = " }{TEXT 279 11 "lower limit" }{TEXT -1 4 " .. " }{TEXT 280 13 "up per limit, " }{TEXT -1 4 "y = " }{TEXT 281 12 "lower limit " }{TEXT -1 3 ".. " }{TEXT 282 12 "upper limit)" }{TEXT -1 1 ";" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 19 "Let's try plotting: " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 67 " \+ x cos y + y cos x = 1 " }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 40 "for x and y both between -2 Pi and 2 Pi." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 62 "implicitplot(x*cos(y)+y*cos( x)=1,x=-2*Pi..2*Pi,y=-2*Pi..2*Pi);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 560 "Of course, one of a calculus teacher's favorite types of problems to assign is \"find the area of the region between this curve and tha t curve.\" Your first step is to figure out what the graphs of these \+ curves look like. Of course, you want to see both these curves on the same graph. This is a little harder to do in Maple than simply plott ing a curve. You need to name the various plots you want to use, then use the 'display' command. For example, suppose we want to graph the functions y = x^3 - 4x^2 + 3x and y = x^2 - x on the same graph. We \+ define:" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 40 " graph1 := plot (" }{TEXT 283 12 "expressio n, " }{TEXT -1 4 "x = " }{TEXT 284 12 "lower limit " }{TEXT -1 2 ".." }{TEXT 285 12 " upper limit" }{TEXT -1 2 "):" }}{PARA 0 "" 0 "" {TEXT -1 40 " graph2 := plot (" }{TEXT 256 10 "expres sion" }{TEXT -1 6 ", x = " }{TEXT 257 11 "lower limit" }{TEXT 286 1 " \+ " }{TEXT -1 2 ".." }{TEXT 258 12 " upper limit" }{TEXT -1 2 "):" }} {PARA 0 "" 0 "" {TEXT -1 50 " display(\{graph1, graph2\});" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 22 "Some things to notice:" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }} {PARA 0 "" 0 "" {TEXT -1 123 " 1) To define a va riable, such as I've done with 'graph1,' we use a colon followed by an equals sign." }}{PARA 0 "" 0 "" {TEXT -1 119 " 2 ) When we defined our graph variables, we ended each line with a colo n rather than a semicolon." }}{PARA 0 "" 0 "" {TEXT -1 88 " \+ 3) The 'display' command has curly braces inside the paren theses." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 67 "Let's try it (remember: you have to press return after every line) :" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 38 "graph1:=plot(x^3-4*x^2+3*x,x=-10..10):" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 30 "graph2:=plot(x^2-x,x=-10..10):" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 25 "display(\{graph1,graph2\}); " }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 136 "Oops--it's kind of hard to see the region between the curves, if \+ there is any. We can control this by adding limits on the values of y :" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 48 "graph1:=plot(x^3-4*x^2+3*x,x=-10..10,y=-15..15):" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 40 "graph2:=plot(x^2-x,x=-10..10 ,y=-15..15):" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 25 "display(\{g raph1,graph2\});" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 " " 0 "" {TEXT -1 146 "This is nice, but suppose we want to be able to t ell which graph is which. We can change the color by adding a color c ommand to the plot command:" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 58 "graph1:=plot(x^3-4*x^2+3*x,x =-10..10,y=-15..15,color=red):" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 51 "graph2:=plot(x^2-x,x=-10..10,y=-15..15,color=blue):" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 25 "display(\{graph1,graph2\}); " }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 139 "Note that we can add as many functions to a graph as we want--jus t define each graph as we did above, then add it to the 'display' comm and." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 128 " To graph multiple polar, parametric, and implicit functions on the sam e graph works in the same manner as what we've just done. " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}}{MARK "0 0 0" 31 }{VIEWOPTS 1 1 0 1 1 1803 }