function mm_values_print_some ( rep, field, nnz, indx, jndx, value, ilo, ihi )

%*****************************************************************************80
%
%% mm_values_print_some() prints some matrix values of a Matrix Market file.
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    02 May 2004
%
%  Author:
%
%    John Burkardt
%
%  Input:
%
%    character REP, the Matrix Market 'representation'
%    indicator.  Possible values include:
%    'coordinate'   (for sparse data)
%    'array'        (for dense data)
%    'elemental'    (to be added)
%
%    character FIELD, the Matrix Market 'field'.
%    Possible values include:
%    'real'
%    'double'
%    'complex'
%    'integer'
%    'pattern'
%
%    integer NNZ, the number of nonzero entries required to store
%    the matrix, if REP = 'coordinate'.
%
%    integer INDX(NNZ), the row indices for coordinate format.
%    Not used if REP is 'array'.
%
%    integer JNDX(NNZ), the column indices for coordinate format.
%    Not used if REP is 'array'.
%
%    complex VALUE(NNZ), the matrix values.
%
%    integer ILO, IHI, the minimum and maximum indices of
%    the data to print.
%
  if ( s_eqi ( rep, 'coordinate' ) )
    fprintf ( 1, '\n' );
    fprintf ( 1, '  Sparse array storage by coordinate.\n' );
    fprintf ( 1, '  Listing entries %d through %d\n', ilo, ihi );
    fprintf ( 1, '\n' );
  elseif ( s_eqi ( rep, 'array' ) )
    fprintf ( 1, '\n' );
    fprintf ( 1, '  Dense array storage of all elements.\n' );
    fprintf ( 1, '  Listing entries %d through %d\n', ilo, ihi );
    fprintf ( 1, '\n' );
  end

  for i = max ( ilo, 1 ) : min ( ihi, nnz )

    if ( s_eqi ( rep, 'coordinate' ) )
        
      if ( s_eqi ( field, 'pattern' ) )
        fprintf ( 1, '%4d  %6d  %6d\n', i, indx(i), jndx(i) );
      else
        fprintf ( 1, '%4d  %6d  %6d  %f\n', i, indx(i), jndx(i), value(i) );
      end

    elseif ( s_eqi ( rep, 'array' ) )
        
      fprintf ( 1, '%4d  %f\n', i, value(i) );

    end

  end
  
  return
end
