Classic Computer Magazine Archive ANTIC VOL. 5, NO. 6 / OCTOBER 1986

Help!


ACOUSTIC 830

The old Atari 830 rubber-cup acoustic modem was mistakenly called an 835 in BAAUG Speaks Out (August, 1986). The Atari 835 was actually a direct-connect modem that plugged straight into your phone jack and your computer-the predecessor of the 1030.

FILE MASTER

If File Master (Antic. August 1986) is not working properly for you, change the 100 in line 2625 to a 90. The problem occurs in some combinations of DOSs and disk drives.

Also, we discovered after publication that File Master is apparently based closely on a public domain program which was originated in 1981 by Stacy Goff of the Eugene (OR) Atari Computer Enthusiasts.

PRO FORTRAN-77
A number of Fortran-knowledgeable readers disagreed with the Sieve of Eratosthenes speed test which clocked Prospero Pro Fortran-77 (Antic. August 1986) at 11 minutes and 8 seconds. It turns out that the dissenters are correct, and Antic is grateful to everyone who alerted us to the error.

The reviewer insisted that he ran his test many times, always with the same result. But when he sent us the Fortran source code he wrote for the test, we took a close look and discovered a one-character mistake! Unfortunately this is the maddening kind of bug that can sometimes creep into the work of even the most experienced software developers, such as our reviewer.

We've reprinted the corrected Pro Fort ran-77 Sieve test below. Look at the line right below line 50. This line starts a DO loop which uses the integer K as a counter. The snail-paced original program contained a J as the counter.

Since the line right below the start of the loop was testing for IFLG( K), the program took a long time to find a match.

The corrected version runs in less than three seconds-considerably faster than the 11 minutes reported in the review. In fact, Pro Fortran-77 runs at virtually a dead heat with the 2:53 seconds turned in by Digital Research's Alcyon C.


        PROGRAM SIEVE
C  THIS IS THE 'Corrected' SIEVE PROGRAM FOR TESTING FORTRAN

       LOGICAL*2 IFLG (8191)
       INTEGER*2 ICT,ITER.I.IPRIME

       WRITE (*,100)
100    FORMAT(' SEIVE is INTERATIONS '/)
       CALL TIME(IHOURS,MINS,ISECS,IHUND)
       WRITE (*,200) IHOURS. MINS, ISECS IHUND
200    FORMAT(' START TIME=',I2,':',I2,':',I2,'.',I2/)
       DO 20 ITR = 1,9,1
         ICT=0
         DO 30 I= 0,8190,1
           IFLG(I)= .TRUE.
   30    CONTINUE
         DO 40 I= 0,8190,1
           IF (IFLG(I)) THEN
   50        IPRIME = I+I+3
             DO 60 K=I+IPRIME,8190,IPRIME
               IFLG(K) = .FALSE.
   60        CONTINUE
             ICT=ICT+1
           ENDIF
   40    CONTINUE
   20  CONTINUE
       CALL TIME(IHOURS,MINS,ISECS,IHUND)
       WRITE(*,300) IHOURS,MINS,ISECS,IHUND
300    FORMAT(' STOP TIME=',I2,':',I2,':',I2,'.',I2/)
       WRITE (*,400)
400    FORMAT(' THAT''S ALL FOLKS')

       END