anchor.diff:    integer(int32)              :: alphabet_size
     integer(int32)              :: ndata
     integer(int32)              :: nfrq
  -  integer(int32), allocatable :: sparse_multip_frq(:)
  -  integer(int32), allocatable :: sparse_multip(:)
   
   contains
   
  -  subroutine compute_multiplicities(counts, alphabet_size)
  +  subroutine compute_multiplicities(counts, alphabet_size, sparse_multip_frq, sparse_multip)
       integer(int32), intent(in) :: counts(:)
       integer(int32), intent(in) :: alphabet_size
  +    integer(int32), intent(out) :: sparse_multip_frq(:)
  +    integer(int32), intent(out) :: sparse_multip(:)
   
       integer(int32)              :: nbins
       integer(int32)              :: i_,k_,ni_
  
positive.code:   integer(int32), intent(in)  :: nc
    real(real64),   intent(in)  :: alpha
    real(real64),   intent(out) :: estimate
  
    if (size(counts) == 1) then 
       estimate = 0.0_real64
       return
    end if
  
    call compute_multiplicities(counts, nc)
  
    estimate = hdir(alpha)
  
    call dirichlet_finalize()
  
  end subroutine dirichlet
  
  subroutine nsb(n,counts,nc,estimate,err_estimate)
    use iso_fortran_env
    use dirichlet_mod, only: compute_multiplicities,dirichlet_finalize
    use nsb_mod, only: hnsb
    use nsb_mod, only: compute_integration_range
    implicit none
  
negative.code:     deallocate(multip)
      
    end subroutine compute_multiplicities
  
    pure real(real64) function log_fpxa(alpha) 
      ! log(p(x|a)) (log of) marginal probability of data given alpha
  