\START\ \COMMENT=Program file dated 02/06/94, 08:48 \NAME=CHAOS1 \FILE=chaos1.85P AxesOn RectGC SimulG GridOff LabelOff y1=x Lbl Menu1 ClLCD Outpt(3,8,"CHAOS!!!") Outpt(4,6,"by Ken Monks") Menu(1,"f(x)",GETf,2,"x0,k",GETx0,3,"Graph",Menu3,4,"Orbit",ORBIT,5,"Exit",DONE) Lbl GETf ClLCD InpSt "Enter function (of x)",fst \St>Eq\(fst,y2) Goto Menu1 Lbl GETx0 ClLCD Prompt x0 Prompt K Goto Menu1 Lbl ORBIT 0\->\ANS {K+1,2}\->\dim ANS x0\->\T For(i,0,K) i\->\ANS(i+1,1) T\->\ANS(i+1,2) T\->\x y2\->\T End ClLCD Pause ANS Goto Menu1 Lbl Menu3 Menu(1,"Plot",PLOT,2,"ZIN",ZI,3,"ZOUT",ZO,4,"SHIFT",SHIFT,5,"Esc",Menu1) Lbl ZI ZIn Goto GRAN Lbl ZO ZOut Goto GRAN Lbl SHIFT 0\->\KEY While KEY\<>\105 getKy\->\KEY If KEY==25 or KEY==24 or KEY==26 or KEY==34 :Then xMax-xMin\->\xW yMax-yMin\->\yW If KEY==25 :Then 0\->\Dx .25\->\Dy Else :If KEY==24 :Then \(-)\.25\->\Dx 0\->\Dy Else :If KEY==26 :Then .25\->\Dx 0\->\Dy Else :If KEY==34 :Then 0\->\Dx \(-)\.25\->\Dy Else 0\->\Dx 0\->\Dy End End End End xMin+Dx*xW\->\xMin xMax+Dx*xW\->\xMax yMin+Dy*xW\->\yMin yMax+Dy*xW\->\yMax DispG End End Goto GRAN Lbl PLOT FnOn 1,2 ClDrw Goto GRAN Lbl GRAN x0\->\x Line(x,0,x,y2) x0\->\x For(i,0,K) Line(x,y2,y2,y2) y2\->\x Line(x,x,x,y2) End Pause Input Goto Menu3 Lbl DONE ClLCD \STOP\