Home » Archimedes archive » Acorn Computing » 1994 11 subscription disc.adf » 9411s » BeebDisk/FracTri
BeebDisk/FracTri
This website contains an archive of files for the Acorn Electron, BBC Micro, Acorn Archimedes, Commodore 16 and Commodore 64 computers, which Dominic Ford has rescued from his private collection of floppy disks and cassettes.
Some of these files were originally commercial releases in the 1980s and 1990s, but they are now widely available online. I assume that copyright over them is no longer being asserted. If you own the copyright and would like files to be removed, please contact me.
Tape/disk: | Home » Archimedes archive » Acorn Computing » 1994 11 subscription disc.adf » 9411s |
Filename: | BeebDisk/FracTri |
Read OK: | ✔ |
File size: | 0355 bytes |
Load address: | 0000 |
Exec address: | 0000 |
Duplicates
There is 1 duplicate copy of this file in the archive:
- Archimedes archive » Acorn Computing » 1994 11 subscription disc.adf » 9411s » BeebDisk/FracTri
- AEW website » mu » mu_5_25_discs_Micro_User_12_09_D-MU12_09.ssd » FracTri
File contents
10 MODE 0 15 PRINT "Fractal Demonstation" 20 PRINT ''"1. Triangle" 30 PRINT '"2. Random plotted triangle" 40 PRINT '"3. Lots of triangles" 50 ON GET-48 GOTO 60,120,330 60 MODE 0:PLOT 69,640,0 70 PROCplot 80 : 90 MOVE 0,0:GCOL 0,0:DRAW 1280,0 100 : 110 END 120 P=3 130 MODE0 140 DIM X(10),Y(10) 150 PROCpoints 160 : 170 R=RND(P):X=X(R):Y=Y(R) 180 REPEAT 190 Q=RND(P):A=X(Q):B=Y(Q) 200 X=(X-A)/2+A:Y=(Y-B)/2+B 210 PLOT 69,X,Y-100 220 UNTIL INKEY-1 230 : 240 DEFPROCpoints 250 R=500 260 A=1 270 FOR N=0 TO 360 STEP 360/P 280 X(A)=R*SIN(RAD(N))+640:Y(A)=R*COS(RAD(N))+512 290 A=A+1 300 NEXT 310 ENDPROC 320 : 330 MODE 0 340 FOR X=0 TO 1280 STEP 2 350 IF RND(10)=1 THEN GCOL 0,0 ELSE GCOL 0,1 360 PLOT 69,X,0 370 NEXT 380 PROCplot 390 END 400 : 410 DEFPROCplot 420 FOR Y%=4 TO 1024 STEP 4 430 FOR X%=0 TO 1280 STEP 2 440 A%=POINT(X%,Y%-4) 450 B%=POINT(X%-2,Y%-4) 460 C%=POINT(X%+2,Y%-4) 470 D%=A%+B%+C%:IF D%=3 THEN E%=0 480 IF D%=1 THEN E%=1 490 IF D%=2 THEN E%=0 500 IF D%=0 THEN E%=0 510 GCOL 0,E% 520 PLOT 69,X%,Y% 530 NEXT, 540 ENDPROC
� 0 � "Fractal Demonstation" � ''"1. Triangle" $ � '"2. Random plotted triangle" ( � '"3. Lots of triangles" 2 � �-48 � �T|@,�Dx@,�DJA < � 0:� 69,640,0 F �plot P : Z � 0,0:� 0,0:� 1280,0 d : n � x P=3 � �0 � � X(10),Y(10) � �points � : � R=�(P):X=X(R):Y=Y(R) � � � Q=�(P):A=X(Q):B=Y(Q) � X=(X-A)/2+A:Y=(Y-B)/2+B � � 69,X,Y-100 � � �-1 � : � ��points � R=500 A=1 � N=0 � 360 � 360/P * X(A)=R*�(�(N))+640:Y(A)=R*�(�(N))+512 " A=A+1 , � 6 � @ : J � 0 T � X=0 � 1280 � 2 ^ � �(10)=1 � � 0,0 � � 0,1 h � 69,X,0 r � | �plot � � � : � ��plot � � Y%=4 � 1024 � 4 � � X%=0 � 1280 � 2 � A%=�X%,Y%-4) � B%=�X%-2,Y%-4) � C%=�X%+2,Y%-4) � D%=A%+B%+C%:� D%=3 � E%=0 � � D%=1 � E%=1 � � D%=2 � E%=0 � � D%=0 � E%=0 � � 0,E% � 69,X%,Y% �, � �
00000000 0d 00 0a 08 20 eb 20 30 0d 00 0f 1d 20 f1 20 22 |.... . 0.... . "| 00000010 46 72 61 63 74 61 6c 20 44 65 6d 6f 6e 73 74 61 |Fractal Demonsta| 00000020 74 69 6f 6e 22 0d 00 14 16 20 f1 20 27 27 22 31 |tion".... . ''"1| 00000030 2e 20 54 72 69 61 6e 67 6c 65 22 0d 00 1e 24 20 |. Triangle"...$ | 00000040 f1 20 27 22 32 2e 20 52 61 6e 64 6f 6d 20 70 6c |. '"2. Random pl| 00000050 6f 74 74 65 64 20 74 72 69 61 6e 67 6c 65 22 0d |otted triangle".| 00000060 00 28 1e 20 f1 20 27 22 33 2e 20 4c 6f 74 73 20 |.(. . '"3. Lots | 00000070 6f 66 20 74 72 69 61 6e 67 6c 65 73 22 0d 00 32 |of triangles"..2| 00000080 1c 20 ee 20 a5 2d 34 38 20 e5 20 8d 54 7c 40 2c |. . .-48 . .T|@,| 00000090 8d 44 78 40 2c 8d 44 4a 41 0d 00 3c 13 20 eb 20 |.Dx@,.DJA..<. . | 000000a0 30 3a f0 20 36 39 2c 36 34 30 2c 30 0d 00 46 0a |0:. 69,640,0..F.| 000000b0 20 f2 70 6c 6f 74 0d 00 50 06 20 3a 0d 00 5a 19 | .plot..P. :..Z.| 000000c0 20 ec 20 30 2c 30 3a e6 20 30 2c 30 3a df 20 31 | . 0,0:. 0,0:. 1| 000000d0 32 38 30 2c 30 0d 00 64 06 20 3a 0d 00 6e 06 20 |280,0..d. :..n. | 000000e0 e0 0d 00 78 08 20 50 3d 33 0d 00 82 07 20 eb 30 |...x. P=3.... .0| 000000f0 0d 00 8c 12 20 de 20 58 28 31 30 29 2c 59 28 31 |.... . X(10),Y(1| 00000100 30 29 0d 00 96 0c 20 f2 70 6f 69 6e 74 73 0d 00 |0).... .points..| 00000110 a0 06 20 3a 0d 00 aa 19 20 52 3d b3 28 50 29 3a |.. :.... R=.(P):| 00000120 58 3d 58 28 52 29 3a 59 3d 59 28 52 29 0d 00 b4 |X=X(R):Y=Y(R)...| 00000130 06 20 f5 0d 00 be 19 20 51 3d b3 28 50 29 3a 41 |. ..... Q=.(P):A| 00000140 3d 58 28 51 29 3a 42 3d 59 28 51 29 0d 00 c8 1c |=X(Q):B=Y(Q)....| 00000150 20 58 3d 28 58 2d 41 29 2f 32 2b 41 3a 59 3d 28 | X=(X-A)/2+A:Y=(| 00000160 59 2d 42 29 2f 32 2b 42 0d 00 d2 11 20 f0 20 36 |Y-B)/2+B.... . 6| 00000170 39 2c 58 2c 59 2d 31 30 30 0d 00 dc 0a 20 fd 20 |9,X,Y-100.... . | 00000180 a6 2d 31 0d 00 e6 06 20 3a 0d 00 f0 0d 20 dd f2 |.-1.... :.... ..| 00000190 70 6f 69 6e 74 73 0d 00 fa 0a 20 52 3d 35 30 30 |points.... R=500| 000001a0 0d 01 04 08 20 41 3d 31 0d 01 0e 18 20 e3 20 4e |.... A=1.... . N| 000001b0 3d 30 20 b8 20 33 36 30 20 88 20 33 36 30 2f 50 |=0 . 360 . 360/P| 000001c0 0d 01 18 2a 20 58 28 41 29 3d 52 2a b5 28 b2 28 |...* X(A)=R*.(.(| 000001d0 4e 29 29 2b 36 34 30 3a 59 28 41 29 3d 52 2a 9b |N))+640:Y(A)=R*.| 000001e0 28 b2 28 4e 29 29 2b 35 31 32 0d 01 22 0a 20 41 |(.(N))+512..". A| 000001f0 3d 41 2b 31 0d 01 2c 06 20 ed 0d 01 36 06 20 e1 |=A+1..,. ...6. .| 00000200 0d 01 40 06 20 3a 0d 01 4a 08 20 eb 20 30 0d 01 |..@. :..J. . 0..| 00000210 54 15 20 e3 20 58 3d 30 20 b8 20 31 32 38 30 20 |T. . X=0 . 1280 | 00000220 88 20 32 0d 01 5e 1e 20 e7 20 b3 28 31 30 29 3d |. 2..^. . .(10)=| 00000230 31 20 8c 20 e6 20 30 2c 30 20 8b 20 e6 20 30 2c |1 . . 0,0 . . 0,| 00000240 31 0d 01 68 0d 20 f0 20 36 39 2c 58 2c 30 0d 01 |1..h. . 69,X,0..| 00000250 72 06 20 ed 0d 01 7c 0a 20 f2 70 6c 6f 74 0d 01 |r. ...|. .plot..| 00000260 86 06 20 e0 0d 01 90 06 20 3a 0d 01 9a 0b 20 dd |.. ..... :.... .| 00000270 f2 70 6c 6f 74 0d 01 a4 16 20 e3 20 59 25 3d 34 |.plot.... . Y%=4| 00000280 20 b8 20 31 30 32 34 20 88 20 34 0d 01 ae 16 20 | . 1024 . 4.... | 00000290 e3 20 58 25 3d 30 20 b8 20 31 32 38 30 20 88 20 |. X%=0 . 1280 . | 000002a0 32 0d 01 b8 11 20 41 25 3d b0 58 25 2c 59 25 2d |2.... A%=.X%,Y%-| 000002b0 34 29 0d 01 c2 13 20 42 25 3d b0 58 25 2d 32 2c |4).... B%=.X%-2,| 000002c0 59 25 2d 34 29 0d 01 cc 13 20 43 25 3d b0 58 25 |Y%-4).... C%=.X%| 000002d0 2b 32 2c 59 25 2d 34 29 0d 01 d6 1e 20 44 25 3d |+2,Y%-4).... D%=| 000002e0 41 25 2b 42 25 2b 43 25 3a e7 20 44 25 3d 33 20 |A%+B%+C%:. D%=3 | 000002f0 8c 20 45 25 3d 30 0d 01 e0 12 20 e7 20 44 25 3d |. E%=0.... . D%=| 00000300 31 20 8c 20 45 25 3d 31 0d 01 ea 12 20 e7 20 44 |1 . E%=1.... . D| 00000310 25 3d 32 20 8c 20 45 25 3d 30 0d 01 f4 12 20 e7 |%=2 . E%=0.... .| 00000320 20 44 25 3d 30 20 8c 20 45 25 3d 30 0d 01 fe 0b | D%=0 . E%=0....| 00000330 20 e6 20 30 2c 45 25 0d 02 08 0f 20 f0 20 36 39 | . 0,E%.... . 69| 00000340 2c 58 25 2c 59 25 0d 02 12 07 20 ed 2c 0d 02 1c |,X%,Y%.... .,...| 00000350 06 20 e1 0d ff |. ...| 00000355