C   29/01/79 C9073001   MEMBER NAME  LGCCTL   (SOURCE)      FORTRAN
      SUBROUTINE LGCCTL(IERT)
C
C     S.YAMADA      28-09-78  22:35
C     LAST MODIFICATION   29-01-79  10:35
C
C     CONTROL SUBROUTINE FOR LGCLUS
C     THIS IS CREATED TO FIND CLUSTERS IN THE THREE PARTS SEPARATELY.
C
      IMPLICIT INTEGER *2 (H)
C
C     USED IN LGANAL PART OF PROGRAMS
C        NO CUTS ON MAX FIRIED #CHANNELS (I.E. DIMENSION=2880)
C        CHANGE SIZE OF THE CLUSTER BANK TO 16.. 13/6/80
C        CHANGED BY Y.WATANABE ON 23/09/79. 00:30
      COMMON /CWORK/ LNG,HNORD,HNORML,HPOINT(4),HLGADC(2,2880),
     1               LGCL(3),LNGCL,NPNT(4),IDENT(2),NCLST,NCLBEC(3),
     2               ETOT(4),NNEUT,EGAM(4),IFLAG(5),NWPCL,
     3               MAPCL(81),  CLPRP(1280)
      INTEGER *2 HMAPCL(2,81)
      DIMENSION ICLSPR(16,80),CLSPRP(16,80), CLMPRP(1361)
      EQUIVALENCE (HMAPCL(1,1),MAPCL(1)), (CLMPRP(1),MAPCL(1))
      EQUIVALENCE (ICLSPR(1,1),CLPRP(1)),  (CLSPRP(1,1),CLPRP(1))
C
C
C---- NCLST = NO.OF THE LOCATED CLUSTERS.
C---- MAPCL(J)=THE INDEX OF THE FIRST MEMBER OF THE J-TH CLUSTER
C               IN THE HLGADC.
C
      COMMON/ CLGVRN/ NVRSN(20)
      DATA NVCODE/279012910/
      NVRSN(6) = NVCODE
C
      IF(LNG.LE.2) GO TO 101
C
C---- CLUSTER FINDING IS REPEATED FOR EACH PART
   10   DO 20 JP=1,3
        NHIT = (HPOINT(JP+1)-HPOINT(JP))/2
        INIT = (HPOINT(JP)+1)/2
        CALL LGCLUS(JP,INIT,NHIT,IER)
        IERT = IERT+IER
   20   CONTINUE
C---- SET NO. OF CLUSTERS IN EACH PART.
      NCLBEC(3) = NCLBEC(3)-NCLBEC(2)
      NCLBEC(2) = NCLBEC(2)-NCLBEC(1)
  100 RETURN
C
  101 MAPCL(1) = 1
      RETURN
      END
