      subroutine pread
      parameter(maxsym=8,maxorb=500)
      IMPLICIT REAL*8(A-H,O-X,Z),logical*1(y)
      common/adr/iadr0(maxsym),nbint
      common/sym/ itsym(maxorb*2),its(maxsym,maxsym),nsym
      common /orb/ enuc,eref,norb,noca,nocb
     *,iorb(2*maxorb),ninac,nvirt,noca0
c
c--------------------------------------------------------------
c     preparation de l'adressage des integrales <ii,kk,jj,kk>
c     iadr0(isk)=nb d'int ou kk a la symetrie isk
c--------------------------------------------------------------
c
      yw=.false.
      do i=1,nsym
         iadr0(i)=0
      enddo
      do 2 i=1,norb
      isi=itsym(i)
      do 3 j=i+1,norb
      if(isi.ne.itsym(j)) goto 3
      iadr0(isi)=iadr0(isi)+norb
      if(yw)write(6,*)'i,j,isi,iadr0(isi)',i,j,isi,iadr0(isi)
 3    continue
 2    continue
      if(yw) then
         do i=1,nsym
            write(6,*)'sym,iadr0',i,iadr0(i)
         enddo
      endif
      ii=0
      do isi=1,nsym
         jj=iadr0(isi)
         iadr0(isi)=ii
         ii=ii+jj
      enddo
      nbint=ii
      if(yw) then
         do i=1,nsym
            write(6,*)'sym,iadr0',i,iadr0(i)
         enddo
      endif
      return
      end
