!23456789a123456789b123456789c123456789d123456789e123456789f123456789g12
!
! A program for producing a supernova designation table. 
!
!
      program desig
      implicit none
!
      integer, parameter :: nalpha=26,number=nalpha*(nalpha+1)
      integer :: i,j,i1,i2,i3
      character :: capital*26='ABCDEFGHIJKLMNOPQRSTUVWXYZ',
     &               small*26='abcdefghijklmnopqrstuvwxyz',
     &             des(number)*2
!
      do410 : do i=1,number
       if(i .le. nalpha) then
           des(i)=' '//capital(i:i)
         else
           i1=i-nalpha
           i2=i1/nalpha
           if(i2*nalpha .lt. i1) then
               i3=i1-i2*nalpha
               i2=i2+1 
             else
               i3=nalpha
           end if     
           des(i)=small(i2:i2)//small(i3:i3) 
       end if
      end do do410
!
      open(unit=1,file='desig.dat',status='unknown',action='write')
!
      write(1,'(a)')
     & '_________________________________________________________'//
     & '____________________'
      write(1,*)
      write(1,'(4("Symbol  Number",4x))') 
      write(1,'(a)')
     & '_________________________________________________________'//
     & '____________________'
      write(1,*)
!
      i1=number/4
      do i=1,i1
       write(1,'(4(4x,a2,2x,i6,4x))') (des(j),j,j=i,i+3*i1,i1)
      end do 
      do i=i1*4+1,number
       write(1,'(58x,a2,2x,i6)') des(i),i 
      end do
!
      close(unit=1)
!
      end
