{VERSION 6 0 "IBM INTEL NT" "6.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 "" -1 256 "" 1 14 0 0 0 0 0 1 0 0 0 0 0 0 0 0 } {PSTYLE "Normal" -1 0 1 {CSTYLE "" -1 -1 "Times" 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 "Normal" -1 256 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 }} {SECT 0 {EXCHG {PARA 256 "" 0 "" {TEXT 256 4 "Demo" }{TEXT -1 85 "\nSe lect function\nselect point\nselect delta x\nplot fucntion and associa ted secant line" }}{PARA 0 "> " 0 "" {MPLTEXT 1 0 21 "restart;\nwith(p lots):" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 196 "f := x -> x^2: \+ # select function\na := 1: # select point (x-coordinate)\ndx : = 0.2: # select Delta x\nxint := 2: # interval for graphin g\nyint := 2: # interval for graphing" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 281 "b := a + dx:\nm := (f(b)-f(a))/dx:\nG1 := plot( [f(x), f(a) + m*(x-a)], x=(a-xint)..(a+xint),\nview = [a-xint..a+xint, f(a)-yint..f(a)+yint], color=[red,blue], scaling = constrained):\nG2 : = plot([[a,f(a)],[b,f(b)]],style=point,symbol=circle,thickness=4,\ncol or=black):\ndisplay(G1,G2);\nm;" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 27 "# Tangent line at a point." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 182 "f := x -> x^2;\nc := -1/2;\ng(x) := f(c) + D(f)(c)*( x-c);\nplot([f(x),g(x)], x = c-xint..c+xint, view = [c-xint..c+xint,f( c)-yint..f(c)+yint], color=[red,blue], scaling = constrained);\n" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}}{MARK "6" 0 }{VIEWOPTS 1 1 0 1 1 1803 1 1 1 1 }{PAGENUMBERS 0 1 2 33 1 1 }