!------------------------------------------------------------------- !
      subroutine ct_rrt_mm(msgtype)
! ------------------------------------------------------------------ !
      use communicate
      use grt
      implicit none
      
      integer, intent(in) :: msgtype
      integer :: nproc
      integer :: i
      character(len=40) :: mm = 'mm'
      external fbuff

      emis1d=0.0d0
      opac1d=0.0d0
      nproc = get_nproc(mm)
      write(1,*) 'ct_rrt_mm: nproc=',nproc
      do i=0,mz-1                   !nproc = mz
         call recv(msgtype,mm,i) 
         call upk(xspec,nsize)
         call upk(emis1d,nsize)
         write(1,*) 'i=',i,'nsize=',nsize
         emissivity%a2d(:,i+1)=emis1d(:)
         call upk(opac1d,nsize)
!        opac1d(:) = 1.0e-20    ! MAKES OPACITY EQUAL TO ~ZERO
         opacity%a2d(:,i+1)=opac1d(:)
      enddo 
        bdry=thick/mz            ! length between zones
        do i=0,(mz-1)            ! filling zone center data
           opacity%zc(i+1)=i*bdry+bdry/2.0
           emissivity%zc(i+1)=i*bdry+bdry/2.0
        enddo
!       do i=1,mz   ! filling emis. and opac. arrays
!          emissivity%a2d(:,i)=emis1d(:)
!          opacity%a2d(:,i)=opac1d(:)
!       enddo
        do i=0,mz
           hbdry(i)=i*bdry
        enddo
      end subroutine ct_rrt_mm 
