{VERSION 5 0 "SUN SPARC SOLARIS" "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 "2D Output" 2 20 "" 0 1 0 0 255 1 0 0 0 0 0 0 0 0 0 1 } {CSTYLE "" -1 256 "" 1 14 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }{PSTYLE "Normal " -1 0 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }0 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "Text Output" -1 2 1 {CSTYLE "" -1 -1 "Courier" 1 10 0 0 255 1 0 0 0 0 0 1 3 0 3 0 }1 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "Warning" 2 7 1 {CSTYLE "" -1 -1 "" 0 1 0 0 255 1 0 0 0 0 0 0 1 0 0 0 }0 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "Maple O utput" 0 11 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 3 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "Maple Plot" 0 13 1 {CSTYLE "" -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 256 1 {CSTYLE "" -1 -1 "" 1 14 0 0 0 0 0 1 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }{PSTYLE "" 0 257 1 {CSTYLE " " -1 -1 "" 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }3 0 0 -1 -1 -1 0 0 0 0 0 0 -1 0 }} {SECT 0 {PARA 256 "" 0 "" {TEXT -1 0 "" }}{PARA 257 "" 0 "" {TEXT 256 44 "Testing the L picture for fractal generation" }{TEXT -1 1 "\n" }} {PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 380 " In \+ order to make fractals with iterated function systems it is nice to h ave a test procedure to make sure you have picked your affine maps cor rectly (and to help you adjust them later if necessary.) The procedure TESTMAP below, takes a list of affine functions as its input, and the result is a mapping -L picture like the ones in the fractal blueprint s from Peitgen's book." }}{PARA 0 "" 0 "" {TEXT -1 209 " Before tr ying to generate fractal examples you should load the subroutines in t his file, either by hitting through the entire document, or by choosing Edit/Execute/Worksheet from the menu toolbar." }}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 234 "restart:with(plots):Digits:=4:\n#e very time you start a new fractal save and close your\n#previous fract als work. Then return to this window\n#and restart; otherwise you ar e likely to overwhelm\n#Maple and crash! Also, save frequently." }} {PARA 7 "" 1 "" {TEXT -1 50 "Warning, the name changecoords has been r edefined\n" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 1143 "TESTMAP:=pr oc(funclist) #this procedure lets you test a list of\n \+ #functions in your iterated function system\n local num,#the num ber of functions\n i, #dummy index\n F, #current funct ion in list\n S, #corners of unit square\n L, #corners of letter L\n Sq, #unit square\n Llet, #letter L\n \+ AS, #transf of square corners\n ASq,#transf of square\n \+ AL, #transf of L corners\n ALlet, #transf of letter L\n \+ Pics; #a list of pictures\nS:=[[0,0],[0,1],[1,1] ,[1,0]];\nL:=[[ .1,.9],[.1,.65],[.2,.65],[.2,.675],[.125,.675],[.125,.9]]:\nSq:=polygo nplot(S): #polygonplot connects the dots!\nLlet:=polygonplot(L):\n n um:=nops(funclist):\n for i from 1 to num do\n F:=funclist[i]: \+ #select ith map\n AS[i]:=map(F,S):\n AL[i]:=map(F,L):\n AS q[i]:=polygonplot(AS[i]):\n ALlet[i]:=polygonplot(AL[i]):\n \+ #a plot of the transformed square and letter:\n Pics[i]:=display( \{ASq[i],ALlet[i]\}):\n od:\n#finally, display the unit square and a ll its images:\ndisplay(\{Sq, seq(Pics[i],i=1..num)\},scaling=constrai ned,\ntitle=`fractal template`);\nend:\n\n " }}}{PARA 0 "" 0 " " {TEXT -1 46 "Here is the standard affine map, which encodes" }} {EXCHG {PARA 11 "" 1 "" {XPPEDIT 18 0 "AFFINE1(matrix([[x], [y]])) = x *matrix([[a], [b]])+y*matrix([[c], [d]])+matrix([[e], [f]]);" "6#/-%(A FFINE1G6#-%'matrixG6#7$7#%\"xG7#%\"yG,(*&F,\"\"\"-F(6#7$7#%\"aG7#%\"bG F1F1*&F.F1-F(6#7$7#%\"cG7#%\"dGF1F1-F(6#7$7#%\"eG7#%\"fGF1" }{TEXT -1 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 43 "or, in the alternate matri x representation:" }}}{EXCHG {PARA 11 "" 1 "" {XPPMATH 20 "6#/-%(AFFIN E1G6#-%'matrixG6#7$7#%\"xG7#%\"yG,&*&-F(6#7$7$%\"aG%\"cG7$%\"bG%\"dG\" \"\"F'F:F:-F(6#7$7#%\"eG7#%\"fGF:" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 97 "AFFINE1:=proc(X,a,b,c,d,e,f)\nRETURN(evalf([a*X[1]+c* X[2]+e,\n b*X[1]+d*X[2]+f]));\nend:" }}}{EXCHG {PARA 0 "> \+ " 0 "" {MPLTEXT 1 0 0 "" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 " " }}}{PARA 13 "" 1 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 198 "No w if you open a new file you can use these procedures to test a templa te and generate a fractal. Every time you restart you will need to re turn to this window to re-enter the procedures you need." }}}{MARK "6 \+ 0 0" 776 }{VIEWOPTS 1 1 0 1 1 1803 1 1 1 1 }{PAGENUMBERS 0 1 2 33 1 1 }