Home » Personal collection » Acorn ADFS disks » Archimedes » Dominic_3.ADF » Files/Programs/Mandlebrot

Files/Programs/Mandlebrot

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 » Personal collection » Acorn ADFS disks » Archimedes » Dominic_3.ADF
Filename: Files/Programs/Mandlebrot
Read OK:
File size: 015B bytes
Load address: FFFFFB45
Exec address: FA846B2C
Duplicates

There are 2 duplicate copies of this file in the archive:

File contents
   10 REM >Mandlebrot
   20 MODE 15:INPUT"X Minimum";xm
   30 INPUT"Y Minimum";ym
   40 INPUT"X Maximum";xmax
   50 INPUT"Y Maximum";ymax
   60 FORXS=0TO1200STEP2:FORYS=0TO1200STEP2
   70 PROCcalculate(xm+((xmax-xm)/1200)*XS,ym+((ymax-ym)/1200)*YS)
   80 MOVEXS,YS:GCOL0,I:DRAWXS,YS:NEXT,
   90 GOTO 90
 1000 DEFPROCcalculate(X,Y):I=0:U=X:V=Y
 1010 UN=U*V*X:V=U^2-V^2-Y:U=UN
 1020 IF U^2+V^2<=4 THEN I=I+1:IF I<>75 THEN 1010
 1030 ENDPROC

 � >Mandlebrot
 � 15:�"X Minimum";xm
 �"Y Minimum";ym
( �"X Maximum";xmax
2 �"Y Maximum";ymax
< �XS=0�1200�2:�YS=0�1200�2
F> �calculate(xm+((xmax-xm)/1200)*XS,ym+((ymax-ym)/1200)*YS)
P �XS,YS:�0,I:�XS,YS:�,
Z � �DZ@
�! ��calculate(X,Y):I=0:U=X:V=Y
� UN=U*V*X:V=U^2-V^2-Y:U=UN
�( � U^2+V^2<=4 � I=I+1:� I<>75 � �drC
 �
�
00000000  0d 00 0a 12 20 f4 20 3e  4d 61 6e 64 6c 65 62 72  |.... . >Mandlebr|
00000010  6f 74 0d 00 14 19 20 eb  20 31 35 3a e8 22 58 20  |ot.... . 15:."X |
00000020  4d 69 6e 69 6d 75 6d 22  3b 78 6d 0d 00 1e 14 20  |Minimum";xm.... |
00000030  e8 22 59 20 4d 69 6e 69  6d 75 6d 22 3b 79 6d 0d  |."Y Minimum";ym.|
00000040  00 28 16 20 e8 22 58 20  4d 61 78 69 6d 75 6d 22  |.(. ."X Maximum"|
00000050  3b 78 6d 61 78 0d 00 32  16 20 e8 22 59 20 4d 61  |;xmax..2. ."Y Ma|
00000060  78 69 6d 75 6d 22 3b 79  6d 61 78 0d 00 3c 1e 20  |ximum";ymax..<. |
00000070  e3 58 53 3d 30 b8 31 32  30 30 88 32 3a e3 59 53  |.XS=0.1200.2:.YS|
00000080  3d 30 b8 31 32 30 30 88  32 0d 00 46 3e 20 f2 63  |=0.1200.2..F> .c|
00000090  61 6c 63 75 6c 61 74 65  28 78 6d 2b 28 28 78 6d  |alculate(xm+((xm|
000000a0  61 78 2d 78 6d 29 2f 31  32 30 30 29 2a 58 53 2c  |ax-xm)/1200)*XS,|
000000b0  79 6d 2b 28 28 79 6d 61  78 2d 79 6d 29 2f 31 32  |ym+((ymax-ym)/12|
000000c0  30 30 29 2a 59 53 29 0d  00 50 1a 20 ec 58 53 2c  |00)*YS)..P. .XS,|
000000d0  59 53 3a e6 30 2c 49 3a  df 58 53 2c 59 53 3a ed  |YS:.0,I:.XS,YS:.|
000000e0  2c 0d 00 5a 0b 20 e5 20  8d 44 5a 40 0d 03 e8 21  |,..Z. . .DZ@...!|
000000f0  20 dd f2 63 61 6c 63 75  6c 61 74 65 28 58 2c 59  | ..calculate(X,Y|
00000100  29 3a 49 3d 30 3a 55 3d  58 3a 56 3d 59 0d 03 f2  |):I=0:U=X:V=Y...|
00000110  1e 20 55 4e 3d 55 2a 56  2a 58 3a 56 3d 55 5e 32  |. UN=U*V*X:V=U^2|
00000120  2d 56 5e 32 2d 59 3a 55  3d 55 4e 0d 03 fc 28 20  |-V^2-Y:U=UN...( |
00000130  e7 20 55 5e 32 2b 56 5e  32 3c 3d 34 20 8c 20 49  |. U^2+V^2<=4 . I|
00000140  3d 49 2b 31 3a e7 20 49  3c 3e 37 35 20 8c 20 8d  |=I+1:. I<>75 . .|
00000150  64 72 43 0d 04 06 06 20  e1 0d ff                 |drC.... ...|
0000015b
Files/Programs/Mandlebrot.m0
Files/Programs/Mandlebrot.m1
Files/Programs/Mandlebrot.m2
Files/Programs/Mandlebrot.m4
Files/Programs/Mandlebrot.m5