{VERSION 5 0 "IBM INTEL NT" "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 }{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 }} {SECT 0 {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 23 "restart: with (linal g):" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 56 "LesliePlot.mws \+ BIOL763/MATH523/SCCC411B" }}{PARA 0 "" 0 "" {TEXT -1 28 "Ralph H oward, USC Math Dept." }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 235 "This is a Maple work sheet to plot age structure in a population with three a ge classes. First enter the three net fecundity per year by editing t he following. (The values used here are those from the example on pag e 53 of the text)." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 30 "F1:= \+ 0 ; F2:= .8 ; F3:= 2.2;" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 132 "Nex t enter the rates for the age classes 1 and 2 by editing the following . (Again this is from the example on page 53 of the text.)" }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 20 "s1:= .5 ; s2:= .6;" }}} {EXCHG {PARA 0 "" 0 "" {TEXT -1 182 "Enter the number of generations t hat are to be ploted. (In many examples anything much larger than 50) is going to lead to graphs where the interesting information is hard \+ to see. " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 29 "N1:=20; N2:= 50; N3:= 30;" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 181 "Enter the num ber of generations that are to be ploted. (In many examples anything \+ much larger than 50) is going to lead to graphs where the interesting \+ information is hard to see. " }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 12 "NumGen:= 20;" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 74 "We now form the Leslie matrix and the initial vector of age distributions." }}} {EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 75 "L:=matrix([[F1,F2,F3],[s1,0, 0],[0,s2,0]]);\nPopDist:=matrix(3,1,[N1,N2,N3]);" }}}{EXCHG {PARA 0 " " 0 "" {TEXT -1 77 "Initialize some variables for saving the populatio n sizes of the age classes." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 49 "plotlist1:=NULL;plotlist2:=NULL; plotlist3:=NULL;" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 89 "The following loop computes the values ag e distributions of the first NumGen generations." }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 186 "for t from 0 to NumGen do\nplotlist1:= plotl ist1, [t, PopDist[1,1]];\nplotlist2:= plotlist2, [t, PopDist[2,1]];\np lotlist3:= plotlist3, [t, PopDist[3,1]];\n PopDist:=multiply(L,PopDist );\nod:" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 104 "Number in age class 1 = black graph\nNumber in age class 2 = red graph\nNumber in age class 3 = blue graph" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 93 "plot([[p lotlist1],[plotlist2],[plotlist3]], labels=['Time','Number'],color=[bl ack,red,blue]);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}} {MARK "0 0 0" 23 }{VIEWOPTS 1 1 0 1 1 1803 1 1 1 1 }{PAGENUMBERS 0 1 2 33 1 1 }