{VERSION 5 0 "APPLE_PPC_MAC" "5.0" } {USTYLETAB {CSTYLE "Maple Input" -1 0 "Courier" 0 1 255 0 0 1 0 1 0 0 1 0 0 0 0 1 }{CSTYLE "2D Math" -1 2 "Times" 0 1 0 0 0 0 0 0 2 0 0 0 0 0 0 1 }{CSTYLE "2D Comment" 2 18 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 } {CSTYLE "" -1 256 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 257 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 258 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 259 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 260 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 } {CSTYLE "" -1 261 "" 0 1 0 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 0 }{CSTYLE "" -1 263 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 264 "" 0 1 0 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 0 } {CSTYLE "" -1 266 "" 0 1 0 0 0 0 0 0 1 0 0 0 0 0 0 0 }{CSTYLE "" -1 267 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 268 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 269 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 270 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 } {CSTYLE "" -1 271 "" 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 272 "" 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1 0 1 {CSTYLE "" -1 -1 "Tim es" 1 12 0 0 0 1 2 2 2 2 2 2 1 1 1 1 }1 1 0 0 0 0 1 0 1 0 2 2 0 1 } {PSTYLE "Heading 1" -1 3 1 {CSTYLE "" -1 -1 "Times" 1 18 0 0 0 1 2 1 2 2 2 2 1 1 1 1 }1 1 0 0 8 4 1 0 1 0 2 2 0 1 }{PSTYLE "Maple Plot" -1 13 1 {CSTYLE "" -1 -1 "Times" 1 12 0 0 0 1 2 2 2 2 2 2 1 1 1 1 }3 1 0 0 0 0 1 0 1 0 2 2 0 1 }{PSTYLE "List Item" -1 14 1 {CSTYLE "" -1 -1 "T imes" 1 12 0 0 0 1 2 2 2 2 2 2 1 1 1 1 }1 1 0 0 3 3 1 0 1 0 2 2 14 5 } {PSTYLE "Author" -1 19 1 {CSTYLE "" -1 -1 "Times" 1 12 0 0 0 1 2 2 2 2 2 2 1 1 1 1 }3 1 0 0 8 8 1 0 1 0 2 2 0 1 }{PSTYLE "Title" -1 256 1 {CSTYLE "" -1 -1 "Times" 1 18 0 0 0 1 2 1 2 2 2 2 1 1 1 1 }3 1 0 0 12 12 1 0 1 0 2 2 19 1 }} {SECT 0 {EXCHG {PARA 256 "" 0 "" {TEXT -1 16 "Lecture 8 Part b" }} {PARA 19 "" 0 "" {TEXT -1 0 "" }}}{SECT 1 {PARA 3 "" 0 "" {TEXT -1 25 "Space curves and surfaces" }}{EXCHG {PARA 0 "" 0 "" {TEXT -1 21 "Exec ute the commands " }{TEXT 267 11 "with(plots)" }{TEXT -1 5 " and " } {TEXT 268 15 "with(plottools)" }{TEXT -1 114 " to see some of the many other ploting procedures in Maple. I will illustrate a few more below : First note that a " }{TEXT 271 5 "curve" }{TEXT -1 36 " in three spa ce may be specified by " }{TEXT 275 20 "parametric equations" }{TEXT -1 2 ": " }}{PARA 0 "" 0 "" {TEXT -1 30 "\n \+ " }{TEXT 269 22 "x=f(t), y=g(t), z=h(t)" }{TEXT -1 13 " \nor simply " }}{PARA 0 "" 0 "" {TEXT -1 7 " " }}{PARA 0 "" 0 "" {TEXT 270 44 " [f(t),g(t),h(t)]" }{TEXT -1 1 " " }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 53 "where t i s in some interval: Here's a simple example:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 12 "with(plots):" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 77 "spacecurve([cos(t),sin(t),t],t=0..6*Pi,color=black, t hickness=3,axes=normal);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 2 "A " } {TEXT 272 7 "surface" }{TEXT -1 66 " in three space may be defined by \+ parametric equations of the form" }}{PARA 0 "" 0 "" {TEXT -1 26 " \n \+ " }{TEXT 273 30 "x = f(s,t), y=g(s,t), z=h(s,t) " }{TEXT -1 2 " \n" }}{PARA 0 "" 0 "" {TEXT -1 74 "where s and t lies \+ in some region in the plane: Here we map the rectangle " }{TEXT 274 15 "[0,Pi] x [-1,1]" }{TEXT -1 23 " to half of a cylinder:" }}{PARA 0 "> " 0 "" {MPLTEXT 1 0 78 "plot3d([cos(s),sin(s),t], s=0..2*Pi,t=-1..1 , scaling=constrained,axes=normal);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 18 "Here's a helicoid:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 97 "plot3d([r*cos(s),r*sin(s),s], r=0..1,s=0..6*Pi,grid=[15,45],style= patch,shading=zhue, axes=box); " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{SECT 1 {PARA 3 "" 0 "" {TEXT -1 49 "Surfaces in cylindrical and spherical coordinates" }} {EXCHG {PARA 0 "" 0 "" {TEXT -1 17 "One can also use " }{TEXT 257 8 "s pherica" }{TEXT -1 5 "l or " }{TEXT 258 23 "cylindrical coordinates" } {TEXT -1 10 " with the " }{TEXT 259 6 "plot3d" }{TEXT -1 46 " procedur e: Here is an example of each: See " }{TEXT 264 7 "?coords" }{TEXT -1 6 " and " }{TEXT 265 15 "?plot3d[coords]" }{TEXT -1 128 " for more details on each of the coordinate systems. There are over 30 differen t types of coordinate systems supported by Maple." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 15 "Recall that in " }{TEXT 262 21 "spherical coordinates" }{TEXT -1 47 " there are three paramete rs usually denoted by " }{XPPEDIT 18 0 "rho;" "6#%$rhoG" }{TEXT -1 2 " , " }{XPPEDIT 18 0 "theta;" "6#%&thetaG" }{TEXT -1 6 ", and " } {XPPEDIT 18 0 "phi;" "6#%$phiG" }{TEXT -1 98 ". If you have forgotten look it up in your calculus book. Most commonly surfaces are of the f orm " }{XPPEDIT 18 0 "rho = f(theta,phi);" "6#/%$rhoG-%\"fG6$%&thetaG% $phiG" }{TEXT -1 17 ". In our example " }{XPPEDIT 18 0 "rho = 1;" "6#/ %$rhoG\"\"\"" }{TEXT -1 1 "." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 123 "plot3d(1, theta=0..2*Pi, ph i=0..Pi,style=patchnogrid,coords=spherical, scaling = constrained, tit le=\"Sphere of Radius 1\");\n" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 4 "F or " }{TEXT 263 23 "cylindrical coordinates" }{TEXT -1 21 " the variab le are r, " }{XPPEDIT 18 0 "theta;" "6#%&thetaG" }{TEXT -1 44 ", and z . Usually the surface is give by r = " }{XPPEDIT 18 0 "f(theta,z);" "6 #-%\"fG6$%&thetaG%\"zG" }{TEXT -1 24 ". In our example r = 2. " }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 122 "plot3d(2,theta=0..2*Pi, z=- 1..1,style=patchnogrid, coords=cylindrical, scaling=constrained, title =\"Cylinder of Radius 2\");" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" } }{PARA 0 "" 0 "" {TEXT -1 40 "We can put these in the same plot using \+ " }{TEXT 256 7 "display" }{TEXT -1 18 ": Remember to use " }{TEXT 260 7 "display" }{TEXT -1 14 " you need the " }{TEXT 261 5 "plots" }{TEXT -1 82 " package which we already loaded above. To spice things up we a dd the plane z = 0." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 260 "P1:=plot3d(1, theta=0..2*Pi, phi=0..Pi,s tyle=patch,coords=spherical, scaling = constrained, color = red):\n\nP 2:=plot3d(2,theta=0..2*Pi, z=-1..1,style=patch, coords=cylindrical, sc aling=constrained, color = green):\n\nP3:=plot3d(0,x=-3..3,y=-3..3, co lor = white):\n" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 67 "display( [P1,P2,P3], title=\"Sphere Inside Cylinder Cut By A Plane\");" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}}{SECT 1 {PARA 3 "" 0 " " {TEXT -1 8 "Tubeplot" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{EXCHG {PARA 0 "" 0 "" {TEXT 266 9 "Tubeplots" }{TEXT -1 100 " are plots of t ubes about one or more space curves: First let's make a unit circle in the x-y plane:" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "> \+ " 0 "" {MPLTEXT 1 0 47 "Curve:=[cos(theta),sin(theta),0],theta=0..2*Pi ;" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 48 "spacecurve(Curve, axes = normal, color = black);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 246 "No w we put a tube of radius 1/4 around the circle to make a torus: Note \+ that numpoints and tubepoints control the number of points plotted alo ng the curve and the number of points around the tube. Change the valu es and you can see what they mean." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 104 "tubeplot(Curve,radius=1/4, numpoints=20, tubepoints= 10,scaling=constrained, style=patch, axes = normal);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 91 "The tub e radius can be made to depend on the curve's parameter as in the foll owing example:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 144 "tubeplot ([cos(theta),sin(theta),0],theta=0..(2.5)*Pi,radius=theta/8, numpoints =40, tubepoints=20,scaling=constrained, style=patch, axes = none);" }} }{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}}{SECT 1 {PARA 3 "" 0 " " {TEXT -1 32 "Three dimensional implicit plots" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{EXCHG {PARA 0 "" 0 "" {TEXT -1 87 "This refers to the ploting of surfaces that are solution sets of equations of the form \+ " }}{PARA 0 "" 0 "" {TEXT -1 23 "\n " }{TEXT 291 11 "f(x,y,z)=0 " }{TEXT -1 1 "\n" }}{PARA 0 "" 0 "" {TEXT -1 144 "that cannot be solved for one variable in terms of the other two. These a re the three dimensional analogues of curves in the plane of the form \+ " }{TEXT 331 10 "f(x,y) = 0" }{TEXT -1 24 " which are plotted with " } {TEXT 330 11 "implictplot" }{TEXT -1 65 " . For example let's see wha t the surface \n\n " }{TEXT 292 1 " " }{XPPEDIT 256 0 "x^2+y^2-z^2 = 1;" "6#/,(*$%\"xG\"\"#\"\"\"*$%\"yGF'F(*$%\"zGF'! \"\"F(" }{TEXT -1 14 " \n\nlooks like:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 21 "restart:\nwith(plots):" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 121 "implicitplot3d(x^2 + y^2 - z^2 = 1 ,x=-3..3,y=-3..3 ,z=-3..3, grid=[20,20,20],\nstyle=patchcontour, contours=20,axes=box); " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}}{SECT 1 {PARA 3 " " 0 "" {TEXT -1 19 "Packages are tables" }}{EXCHG {PARA 0 "" 0 "" {TEXT -1 36 "Note that you don't have to execute " }{TEXT 332 11 "with (plots)" }{TEXT -1 37 " to be able to use a command such as " }{TEXT 335 7 "display" }{TEXT -1 4 " or " }{TEXT 336 12 "implicitplot" } {TEXT -1 8 " in the " }{TEXT 333 5 "plots" }{TEXT -1 46 " package. You may instead use the long forms " }{TEXT 337 14 "plots[display]" } {TEXT -1 4 " or " }{TEXT 338 19 "plots[implicitplot]" }{TEXT -1 62 " w ithout loading plots. Similarly you don't have to execute " }{TEXT 340 12 "with(linalg)" }{TEXT -1 8 " to use " }{TEXT 341 3 "det" } {TEXT -1 37 ", you may instead use the long form l" }{TEXT 342 10 "ina lg[det]" }{TEXT -1 2 ". " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 " " 0 "" {TEXT -1 31 "Note that packages behave like " }{TEXT 334 6 "tab les" }{TEXT -1 178 " with the indices of the table consisting of the n ames of the procedures in the table and the corresponding enty is the \+ actual procedure. (Actually some packages are written as " }{TEXT 339 7 "modules" }{TEXT -1 56 " but still can be accessed like tables.) Some examples:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 8 "restart: " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 21 "type(det, procedure);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 20 "type(linalg, table);" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 28 "type(linalg[det],procedure); " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 41 "A:=matrix(2,2,[1,2,3,4] );\nlinalg[det](A);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 59 "plot s[implicitplot](x^2-(y-1)*(y+1)*y = 0,x=-2..2,y=-2..2);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 74 "Here's another example of the use of the \+ long form of a package procedure:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 28 "combinat[powerset](\{1,2,3\});" }}}{EXCHG {PARA 0 "> \+ " 0 "" {MPLTEXT 1 0 0 "" }}}}{SECT 1 {PARA 3 "" 0 "" {TEXT -1 24 "The \+ option filled = true" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 8 "restart:" }}}{EXCHG {PARA 14 "" 0 "" {TEXT -1 233 "If the filled option is set to true, the area between th e curve and the x-axis is given a solid color. This option is valid on ly with the following commands: plot, contourplot, implicitplot, listc ontplot, polarplot, and semilogplot. " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 52 "plot(sin(x), x=0..2*Pi, filled = true, color=green); " }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 38 "Here's an example due to Vedr an Cacic." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 92 "plot(arcsin(ab s(x)-1)-Pi/2, x=-3..3, y=-4..3,filled=true, color=red, scaling = const rained);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 30 "This also due to Vedr an Cacic:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 90 "plot(sqrt(2*ab s(x)-x^2), x=-3..3, y=-4..3,filled=true, color= red, scaling = constra ined);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 42 "And Vedran's goal was t his lovely picture:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 154 "plo t(\{arcsin(abs(x)-1)-Pi/2,sqrt(2*abs(x)-x^2)\}, x=-3..3,\ny=-4..3,fill ed=true, color=red, scaling = constrained, axes=boxed, xtickmarks=[],y tickmarks=[]);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 45 "Actually it wor ks like this for implicitplot:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 84 "plots[implicitplot](x^2+y^2=1, x=-2..2,y=-2..2, scaling = cons trained, filled=true);" }}}}{SECT 1 {PARA 3 "" 0 "" {TEXT -1 36 "The p ackage plottools -- stop lights" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{EXCHG {PARA 0 "" 0 "" {TEXT -1 200 "T he package plottools has a number of useful procedures. I will illustr ate just a few of them, The commands are more or less self-explanatory . Use help if you want more details. Note that the command " }{TEXT 293 7 "display" }{TEXT -1 56 " must be used to display some of the plo ts so generated." }}}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 8 "restart;" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 12 "with(plots):" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 16 "with(plottools);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 47 "Click a nd rotate as usual to get a better look." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 34 "display(icosahedron([0,0,0],0.8));" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 88 "f := icosahedron([0,0,0],0.8), dodecahedr on([1,1,1],0.5):\nplots[display](f,style=patch);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 80 "DD:=disk([0,0],4, color=green, scaling = cons trained):\ndisplay(DD, axes = none);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 162 "L:=[green,yellow,red]: display([seq(disk([1,i],.45, colour=L[i]),i=1..3)],scaling=constrained, axes = boxed, xtickmarks=[] , ytickmarks=[], title = \"Stop Lights\");" }}}}{SECT 1 {PARA 3 "" 0 " " {TEXT -1 36 "The procedures animate and animate3d" }}{EXCHG {PARA 0 "" 0 "" {TEXT -1 67 "Below I give several examples. In the first we h ave an expression " }{TEXT 314 6 "F(x,t)" }{TEXT -1 7 " where " } {TEXT 315 1 "t" }{TEXT -1 55 " is considered as a parameter. For each \+ fixed value of " }{TEXT 316 1 "t" }{TEXT -1 31 " we get a different fu ntion of " }{TEXT 317 1 "x" }{TEXT -1 33 ". After executing the proce dure " }{TEXT 310 7 "animate" }{TEXT -1 4 " or " }{TEXT 311 9 "animate 3d" }{TEXT -1 138 " one must click on the plot and then at the top of \+ the worksheet various buttons will appear. If you select under the rig htmost help menu " }{TEXT 309 13 "show balloons" }{TEXT -1 124 " and \+ then run your cursor over the various buttons it will tell what the mo st important ones are for. If you click on the " }{TEXT 318 14 "black triangle" }{TEXT -1 49 " the animation wiill begin. If you click on t he " }{TEXT 319 12 "black square" }{TEXT -1 19 " it will stop. The " }{TEXT 320 23 "arrow going in a circle" }{TEXT -1 56 " at the right is to make the animation run continuously." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 8 "restart:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 12 "with(plots):" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 99 "animate( x ^2*t,x=-1..1,t=-2..2,frames=20, scaling=constrained,color=red, thickne ss = 3,axes=boxed);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 36 "You may an imate curves and surfaces:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 129 "animate( [u*sin(t),u*cos(t),t=-Pi..Pi],u=1..8,view=[-8..8,-8..8], \ncolor=blue, scaling = constrained, axes = none, thickness = 3);" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 75 "animate3d([u*t*sin(x),u*t*co s(x),t],x=0..2*Pi,t=0..2,u=.25..4,frames = 20);" }}}{EXCHG {PARA 0 "> \+ " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 199 "Here' s an example to show how the tangent line to y = x^2 changes as we mov e along the curve. Recall that the equation of the tangent line to y = f(x) at the point (a, f(a)) is y = f'(a)(x-a) + f(a)." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 171 "P1:=plot(x^2,x=-1..1, color = red, thickness = 3):\nP2:=animate(2*a*(x-a) + a^2, x = -2..2,a=-1..1, col or = green, thickness = 3):\ndisplay(\{P1,P2\}, scaling = constrained) ;" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 96 "To make the above reverse it self we may replace the variable a by sin(b) and let b go from 0 to " }{XPPEDIT 18 0 "2*Pi;" "6#*&\"\"#\"\"\"%#PiGF%" }{TEXT -1 59 ". Then s in(b) will go from 0 to 1 , 1 to -1 and back to 0.\n" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 133 "a:=sin(b);\nP2:=animate(2*a*(x-a) + a^2, x = -2..2,b=0..2*Pi, color = green, thickness = 3):\ndisplay(\{P1,P2 \}, scaling = constrained);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{PARA 0 "" 0 "" {TEXT -1 21 "Look at the help for " }{TEXT 312 7 "animate" }{TEXT -1 5 " and " }{TEXT 313 9 "animate3d" }{TEXT -1 19 " for more examples." }}}{SECT 1 {PARA 3 "" 0 "" {TEXT -1 39 "Us e of matrixplot and insequence = true" }}{PARA 0 "" 0 "" {TEXT -1 0 " " }}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 8 "restart:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 28 "with(plots): \nwith(linalg):\n" }}} {EXCHG {PARA 0 "" 0 "" {TEXT 343 13 "matrixplot(A)" }{TEXT -1 97 " dis plays matrix in a graphical forn. Here's an example. First let A be a \+ random 10 by 10 matrix." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 21 " A:=randmatrix(10,10):" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 39 "Now we d isplay the matrix as a surface." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 26 "matrixplot(A, axes=boxed);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 46 "Or it can be done as a \"histogram\" as follows:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 43 "matrixplot(A,axes=boxed,heights=his togram);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 102 "Here's an interestin g animation of a collection of matrices. First we create a table of ma trixplots. " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 113 "for j from 1 to 30 do \n P[j]:=matrixplot(matrix(5,5, [seq(sin(i)*j,i=1..25)]), \+ axes=box, heights=histogram):\nod:\n" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 26 "Next we display them with " }{TEXT 344 17 "insequence = true" } {TEXT -1 151 ". If you click on the plot you will see that it is an an imation and can be started by clicking on the triangle and stopped by \+ clicking on the square. " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 45 "display([seq(P[j],j=1..30)],insequence=true);" }}}{EXCHG {PARA 0 " " 0 "" {TEXT -1 115 "More generally given any sequence of plots, say,s eq( P[i], i=a..b), then one may animate them by using the command " } {TEXT 345 50 "display ( [seq(P[i],i=a..b)], insequence = true) ." } {TEXT -1 136 " Sometimes one can form an animation this way that is di fficult to form using the command animate or animate3d.\n\nHere's anot her example:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 141 "for i from 1 to 100 do\nPq[i]:=plot([[i,i]], style = point, symbol = circle, col or = red):\nod:\ndisplay([seq(Pq[i],i=1..100)],insequence=true);" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}}{SECT 1 {PARA 3 "" 0 " " {TEXT -1 21 "Ploting vector fields" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{EXCHG {PARA 0 "" 0 "" {TEXT -1 14 "The procedure " }{TEXT 294 9 "fi eldplot" }{TEXT -1 35 " allows one to draw a picture of a " }{TEXT 295 12 "vector field" }{TEXT -1 59 " in the plane: Recall that a vecto r field assigns a vector " }{TEXT 296 14 "[f(x,y),g(x,y)" }{TEXT -1 16 "] to each point " }{TEXT 297 5 "(x,y)" }{TEXT -1 149 " in the plan e: Here are some simple examples: The first is a constant vector field . This may be thought of as a steady wind blowing across the plain." } }}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 21 "restart:\nwith(plots):" }} }{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 53 "fieldplot( [1,1],x=-10..10, y=-10..10, axes = boxed);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 202 "Th e next example describes a fluid, say, moving in a counter-clockwise m anner. Note that each vector has the same length. So if the vectors in dicate velocity, all particles are moving at the same speed." }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 77 "fieldplot([-y/sqrt(x^2+y^2), x/sqrt(x^2+y^2)], x=-5..5,y=-5..5, axes = boxed);" }}}{EXCHG {PARA 0 " " 0 "" {TEXT -1 14 "The procedure " }{TEXT 304 8 "gradplot" }{TEXT -1 11 " plots the " }{TEXT 305 8 "gradient" }{TEXT -1 48 " of the functio n at each point. Recall that the " }{TEXT 306 8 "gradient" }{TEXT -1 8 " is the " }{TEXT 307 12 "vector field" }{TEXT -1 340 " obtained by \+ taking the partial derivatives with respect to x for the first compone nt and the partial with respect to y for the second component. The gra dient at each point (x,y) points in the direction of greatest rate of \+ increase. So you should follow the arrow to go up. \n\nTo see any plot better just use the mouse to increase its size. " }}}{EXCHG {PARA 0 " > " 0 "" {MPLTEXT 1 0 76 "p:=exp(-(x^2+y^2))*(5-x^2-y^2)+ exp(-(x-2)^2 -(y-2)^2)*((x-2)^2 + (y-2)^2-4);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 28 "gradplot(p,x=-3..4,y=-3..4);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 111 "We can see in this nex plot what the surface looks li ke. Not that from examining the plot of the gradient above" }}{PARA 0 "" 0 "" {TEXT -1 75 "we can identify one peak and one valley. This is \+ visible in the plot below." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 43 "plot3d(p, x = -3..4,y=-3..4, axes = boxed);" }}}{EXCHG {PARA 0 "> \+ " 0 "" {MPLTEXT 1 0 0 "" }}}}{SECT 1 {PARA 3 "" 0 "" {TEXT -1 34 "Plot ting level curves or contours" }}{EXCHG {PARA 0 "" 0 "" {TEXT -1 20 " Maple also can plot " }{TEXT 298 12 "level curves" }{TEXT -1 4 " or " }{TEXT 299 8 "contours" }{TEXT -1 74 " of a function of two variables. Here we use for an example the function " }{TEXT 308 9 "f(x,y) = " } {XPPEDIT 257 0 "x^2-y^2;" "6#,&*$%\"xG\"\"#\"\"\"*$%\"yGF&!\"\"" } {TEXT -1 159 ". The contours are colored from yellow to red. The yello w lines being the greatest in value. We first plot the graph of the fu nction to see what it looks like:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 21 "restart:\nwith(plots):" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 68 "plot3d(x^2-y^2,x=-3..3,y=-3..3, axes = boxed, style = patchcontour);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 14 "The procedure \+ " }{TEXT 300 11 "contourplot" }{TEXT -1 16 " projects these " }{TEXT 301 12 "level curves" }{TEXT -1 4 " or " }{TEXT 302 8 "contours" } {TEXT -1 16 " onto the plane." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 52 "contourplot(x^2-y^2,x=-3..3,y=-3..3, filled = true);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 14 "The procedure " }{TEXT 303 13 "contourplo t3d" }{TEXT -1 46 " raises the contours to the appropriate level:" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 68 "contourplot3d(x^2-y^2,x=-3.. 3,y=-3..3, filled = true, axes = boxed);" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 18 "To see more about " }{TEXT 346 11 "contourplot" }{TEXT -1 5 " and " }{TEXT 347 13 "contourplot3d" }{TEXT -1 20 " see the help page. " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}}{SECT 1 {PARA 3 "" 0 "" {TEXT -1 38 "Assignment 8 Due Wednesday, March 27 \n" }}{EXCHG {PARA 0 "" 0 "" {TEXT 290 9 "Problem 1" }{TEXT -1 2 ". " }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 4 "The " }{TEXT 349 7 "deltoid" } {TEXT -1 99 " plane curve with parameter a is the set of all points ( x,y) in the plane satisfying the equation " }}{PARA 0 "" 0 "" {TEXT -1 6 " " }}{PARA 0 "" 0 "" {TEXT -1 11 " (1) " }{XPPEDIT 18 0 "(x^2+y^2)^2-8*a*x*(x^2-3*y^2)+18*a^2*(x^2+y^2) = 27*a^4;" "6#/,( *$,&*$%\"xG\"\"#\"\"\"*$%\"yGF)F*F)F***\"\")F*%\"aGF*F(F*,&*$F(F)F**& \"\"$F**$F,F)F*!\"\"F*F5*(\"#=F**$F/F)F*,&*$F(F)F**$F,F)F*F*F**&\"#FF* *$F/\"\"%F*" }{TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 64 "and the same curve may be described by the parame tric equations:" }}{PARA 0 "" 0 "" {TEXT -1 13 "\n (2) " } {XPPEDIT 18 0 "x = a*(2*cos(t)+cos(2*t));" "6#/%\"xG*&%\"aG\"\"\",&*& \"\"#F'-%$cosG6#%\"tGF'F'-F,6#*&F*F'F.F'F'F'" }{TEXT -1 7 ", " } {XPPEDIT 18 0 "y = a*(2*sin(t)-sin(2*t));" "6#/%\"yG*&%\"aG\"\"\",&*& \"\"#F'-%$sinG6#%\"tGF'F'-F,6#*&F*F'F.F'!\"\"F'" }{TEXT -1 0 "" }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 39 "(a) Using equation (1) and the command " }{TEXT 350 12 "implicitplot" }{TEXT -1 7 " graph " }{TEXT 359 19 "in the same picture" }{TEXT -1 86 " the \+ deltoid curves with parameters a = 1, 2, and 3.\n\n(b) Using equations (2) and the " }{TEXT 351 4 "plot" }{TEXT -1 16 " command graph " } {TEXT 360 19 "in the same picture" }{TEXT -1 52 " the deltoid curves w ith parameters a = 1, 2, and 3." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }} {PARA 0 "" 0 "" {TEXT -1 83 "You will need to do some experimenting wi th the ranges of the plots and the option " }{TEXT 352 9 "numpoints" } {TEXT -1 174 " in question (a) to get a decent picture. Note that you \+ can copy and paste equations (1) and (2) and with some judicious editi ng can save yourself the trouble of typing them." }}{PARA 0 "" 0 "" {TEXT -1 1 " " }}}{EXCHG {PARA 0 "" 0 "" {TEXT 353 9 "Problem 2" } {TEXT -1 3 ". " }}{PARA 0 "" 0 "" {TEXT -1 30 "(a) The graph of the f unction " }{XPPEDIT 18 0 "g(x) = 10/(x^3-10*x-10*x^2+100);" "6#/-%\"gG 6#%\"xG*&\"#5\"\"\",**$F'\"\"$F**&F)F*F'F*!\"\"*&F)F**$F'\"\"#F*F/\"$+ \"F*F/" }{TEXT -1 173 " has three vertical asymptoes at the three roo ts of the denominator. Use solve to find the location of these three \+ asymptotes and then graph the function using the option " }{TEXT 354 14 "discont = true" }{TEXT -1 125 " to remove the vertical asymptotic \+ lines. Choose horizontal as well as vertical ranges to give a nice pic ture of the curves. " }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 " " {TEXT -1 26 "(b) Plot the graph of the " }{TEXT 356 18 "Nephroid of \+ Freeth" }{TEXT -1 20 ", the curve given " }{TEXT 362 20 "in polar co ordinates" }{TEXT -1 17 " by the equation " }{XPPEDIT 355 0 "r = 1+2*s in(theta/2);" "6#/%\"rG,&\"\"\"F&*&\"\"#F&-%$sinG6#*&%&thetaGF&F(!\"\" F&F&" }{TEXT -1 36 " . Note that you will need to take " }{XPPEDIT 18 0 "theta;" "6#%&thetaG" }{TEXT -1 19 " in the range 0 to " } {XPPEDIT 18 0 "4*Pi;" "6#*&\"\"%\"\"\"%#PiGF%" }{TEXT -1 26 " to get t he right picture." }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 " " 0 "" {TEXT 276 10 "Problem 3." }{TEXT -1 100 " Use Maple to make th e following picture. [The 13 stars in the original flag of the United \+ States.]" }}}{EXCHG {PARA 13 "" 1 "" {GLPLOT2D 116 123 123 {PLOTDATA 2 "64-%'CURVESG6%7(7$$\"\"!F)$\"\")F)7$$\"38+++CD&y(e!#=$\"3s*****f+$) 4>'!#<7$$!3/+++l^c5&*F/$\"3F+++%*p,4tF27$$\"3/+++l^c5&*F/F67$$!38+++CD &y(eF/F0F'-%'COLOURG6&%$RGBG$\"#5!\"\"F(F(-%&STYLEG6#%%LINEG-F$6%7(7$$ \"3#)*****H?iID$F2$\"3Q+++!=#>)>(F27$$\"3-+++bu%3%QF2$\"36+++'=v\"*Q&F 27$$\"3A+++'o0?I#F2$\"3w*****R<4s]'F27$$\"3J+++?(=T?%F2FY7$$\"30+++^pF lEF2FTFLF>FE-F$6%7(7$$\"36+++iq)3w&F2$\"3H+++EKXw\\F27$$\"3()*****RJs' [jF2$\"3,+++KiVnJF27$$\"3r*****faI)4[F2$\"3m******>-Z&G%F27$$\"3j***** zdV>r'F2F[p7$$\"3M+++5=5t^F2FfoF^oF>FE-F$6%7(7$$\"3$*******=@'*[pF2$\" 3-+++jnvV=F27$$\"3q*****4PZn`(F2$\"3r******\\o(RZ$!#>7$$\"3M+++-c!z*fF 2$\"31+++dPx_6F27$$\"3V+++O'=+!zF2Fdq7$$\"3<+++noFE-F$6%7 (7$$\"3#********p8^a'F2$!3%******z?MA[\"F27$$\"3o*****>&*)*G8(F2$!3?++ +-7D\"H$F27$$\"3S+++%=dSf&F2$!36+++9s@t@F27$$\"3K+++;-<'\\(F2F\\s7$$\" 3;+++[%Gt&fF2FgrF_rF>FE-F$6%7(7$$\"3!)******3'e=k%F2$!3I+++O_dRUF27$$ \"3c*****4'QkH_F2$!3o******HAf[gF27$$\"3=+++#4-3p$F2$!3.+++U#e0$\\F27$ $\"3G+++E^\"Hf&F2Fdt7$$\"3/+++dL2aSF2F_tFgsF>FE-F$6%7(7$$\"3)*******\\ '4_n\"F2$!3u*****>s#f'z&F27$$\"3(******>!\\*HE#F2$!3-+++;(4cg(F27$$\"3 !******\\LJ:C(F/$!3P+++Gdd(['F27$$\"3=+++mhEEEF2F\\v7$$\"3,+++)RCu3\"F 2FguF_uF>FE-F$6%7(7$$!3)*******\\'4_n\"F2Fbu7$$!3,+++)RCu3\"F2Fgu7$$!3 =+++mhEEEF2F\\v7$$!3!******\\LJ:C(F/F\\v7$$!3(******>!\\*HE#F2FguFgvF> FE-F$6%7(7$$!3!)******3'e=k%F2Fjs7$$!3/+++dL2aSF2F_t7$$!3G+++E^\"Hf&F2 Fdt7$$!3=+++#4-3p$F2Fdt7$$!3c*****4'QkH_F2F_tFiwF>FE-F$6%7(7$$!3#***** ***p8^a'F2Fbr7$$!3;+++[%Gt&fF2Fgr7$$!3K+++;-<'\\(F2F\\s7$$!3S+++%=dSf& F2F\\s7$$!3o*****>&*)*G8(F2FgrF[yF>FE-F$6%7(7$$!3$*******=@'*[pF2Fip7$ $!3<+++noFE-F$6%7(7$$!36+++iq)3w&F2Fao7$$!3M+++5=5t^F2Ffo7$$!3j** ***zdV>r'F2F[p7$$!3r*****faI)4[F2F[p7$$!3()*****RJs'[jF2FfoF_[lF>FE-F$ 6%7(7$$!3#)*****H?iID$F2FO7$$!30+++^pFlEF2FT7$$!3J+++?(=T?%F2FY7$$!3A+ ++'o0?I#F2FY7$$!3-+++bu%3%QF2FTFa\\lF>FEF#-%*AXESSTYLEG6#%%NONEG-%(SCA LINGG6#%,CONSTRAINEDG-%+AXESLABELSG6%Q!6\"F[^l-%%FONTG6#%(DEFAULTG-%%V IEWG6$F`^lF`^l" 1 2 0 1 10 0 2 9 1 1 1 1.000000 45.000000 45.000000 0 0 "Curve 1" "Curve 2" "Curve 3" "Curve 4" "Curve 5" "Curve 6" "Curve 7 " "Curve 8" "Curve 9" "Curve 10" "Curve 11" "Curve 12" "Curve 13" "Cur ve 14" }}}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 65 "Here are some hints: Te st each step by plotting the points using " }{TEXT 284 13 "style = poi nt" }{TEXT -1 8 " and or " }{TEXT 285 12 "style = line" }{TEXT -1 161 " before continuing to the next step.\n\n1. The following procedure w ill produce a list of n equally spaced points on a circle of radius r \+ centered at the origin :" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 109 "with(plots):\nCirclePoints:=proc(n,r) \nevalf([seq(r*[sin(i*(2*Pi /n)), cos(i*(2*Pi/n))], i=0..n)]); \nend proc:\n" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 83 "plot(CirclePoints(5,1),style = point, symbol \+ = circle, axes = none, color = black);" }}{PARA 13 "" 1 "" {GLPLOT2D 89 68 68 {PLOTDATA 2 "6)-%'CURVESG6#7(7$$\"\"!F)$\"\"\"F)7$$\"3/+++l^c 5&*!#=$\"3s*****z$*p,4$F/7$$\"38+++CD&y(eF/$!3e*****H%*p,4)F/7$$!38+++ CD&y(eF/F57$$!3/+++l^c5&*F/F0F'-%*AXESSTYLEG6#%%NONEG-%'SYMBOLG6#%'CIR CLEG-%'COLOURG6&%$RGBGF)F)F)-%&STYLEG6#%&POINTG-%+AXESLABELSG6$Q!6\"FP -%%VIEWG6$%(DEFAULTGFU" 1 5 4 1 10 0 2 6 1 1 2 1.000000 45.000000 45.000000 0 0 "Curve 1" }}}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 42 "2. Use the above procedure to make a list " }{TEXT 286 1 "L" }{TEXT -1 62 " \+ of 5 points on the unit circle. Then you may form a new list " }{TEXT 277 21 "W:=[L[1], L[3], ...,]" }{TEXT -1 36 " which when plotted with \+ the option " }{TEXT 289 12 "style = line" }{TEXT -1 146 " will produce a star. Number the points in the original circle and by hand trace ou t the star. This will show you how to complete the list for W. " }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 69 "3. The fo llowing procedure can be used to translate the star give by " }{TEXT 281 1 "W" }{TEXT -1 32 " from the origin to a new point " }{TEXT 282 1 "P" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 47 "translate:=proc(W,P )\n map(x->x+P,W);\nend proc:" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 30 "4. Now create the list , say, " }{TEXT 280 1 "X" }{TEXT -1 57 " of 13 points in a suitably sized circle. For each point " }{TEXT 279 8 "P = X[i]" }{TEXT -1 32 " in the list translate the star " }{TEXT 287 1 "W " }{TEXT -1 18 " to the new point " }{TEXT 283 1 "P" }{TEXT -1 48 " an d create a plot of this star. Call it, say, " }{TEXT 288 7 "Plot[i]" }{TEXT -1 39 ". Do this using a do loop. Finally use " }{TEXT 278 7 "d isplay" }{TEXT -1 72 " to show all these plots at the same time to cre ate the above picture.\n\n" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 1 " " } }}{EXCHG {PARA 0 "" 0 "" {TEXT 321 10 "Problem 4." }{TEXT -1 6 " \nUse " }{TEXT 358 14 "implicitplot3d" }{TEXT -1 65 " to graph the 6 surfac es in three space with equations given by " }{XPPEDIT 18 0 "x^2+a*y^2 +b*z^2 = 1;" "6#/,(*$)%\"xG\"\"#\"\"\"F)*&%\"aGF)*$)%\"yGF(F)F)F)*&%\" bGF)*$)%\"zGF(F)F)F)F)" }{TEXT -1 80 " where a is 1 or -1 and b is 0, 1 or -1. Make a title for each using the option" }}{PARA 0 "" 0 "" {TEXT -1 2 " " }}{PARA 0 "" 0 "" {TEXT -1 1 " " }{MPLTEXT 1 0 46 "tit le=convert(x^2 + a*y^2 + b*z^2 = 1,string)\n" }{TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 68 "with the appropriate value of a and b inserted. Use also the option " }{MPLTEXT 1 0 12 "axes = boxed" }{TEXT -1 10 ". You can " }{TEXT 357 10 "and should" }{TEXT -1 109 " do all 6 with a \+ pair of do loops. And don't forget to shrink each plot before printing . You may need to use " }{MPLTEXT 1 0 19 "print(display(...))" }{TEXT -1 54 " to get display to work properly inside two do loops. " }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}}{PARA 0 "" 0 "" {TEXT -1 0 "" }} {PARA 0 "" 0 "" {TEXT 322 0 "" }}}}{MARK "10 0 0" 21 }{VIEWOPTS 0 0 0 1 1 1803 1 1 1 1 }{PAGENUMBERS 0 1 2 33 1 1 }