C     .TITLE TPULSE
C
C  25 FEB 74 - PAUL HENDERSON
C
C  TEST PROGRAM FOR SUBROUTINE 'PULSE'.
C
      INTEGER IVECT(200)
      REAL PICT (4,2),PIC (2,20),KTHETA
      COMMON /LIMITS/XMIN,XMAX,YMIN,YMAX
C
   1  XMIN = -1.
      XMAX = +1.
      YMIN = -1.
      YMAX = +1.
      K = 0
      THETA = 3.14159265/32.
C
      CALL CLEAR (0)
      CALL DISPLY (0,3000,IGET)
C
C  GENERATE A SET OF AXES
C
      PICT(1,1) = 0.
      PICT(2,1) = 1.
      PICT(3,1) = 0.
      PICT(4,1) = -1.
      PICT(1,2) = -1.
      PICT(2,2) = 0.
      PICT(3,2) = 1.
      PICT(4,2) = 0.
C
C  NOW GENERATE A DISPLAY FILE
C
      CALL VECTOR (1,PICT,1,2,IVECT,1,LAST,7,1,0)
      CALL DISPLY (6,1023,IVECT,1,LAST)
C
C  NOW GENERATE A MOVING DISPLAY
C
   2  K = K+1
      AK = K
      KTHETA = AK*THETA
      A = 64./(63.+AK)
      PIC(1,1) = A*COS(KTHETA)-0.25
      PIC(2,1) = A*SIN(KTHETA)-0.25
      PIC(1,2) = A*COS(KTHETA)
      PIC(2,2) = A*SIN(KTHETA)-0.25
      PIC(1,3) = A*COS(KTHETA)
      PIC(2,3) = A*SIN(KTHETA)
      PIC(1,4) = A*COS(KTHETA)-0.25
      PIC(2,4) = A*SIN(KTHETA)
      PIC(1,5) = PIC(1,1)
      PIC(2,5) = PIC(2,1)
C
      CALL VECTOR (3,PIC,1,5,IVECT,1,LAST,7,1,0)
      KM1 = K-1
      CALL DISPLY (6,K,IVECT,1,LAST)
      CALL DISPLY (3,KM1)
      CALL PULSE (IDUM,ICOUNT)
      GO TO 2
      END
