function test_partial_digest_test ()

%*****************************************************************************80
%
%% test_partial_digest_test() tests test_partial_digest().
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    31 March 2019
%
%  Author:
%
%    John Burkardt
%
  addpath ( '../test_partial_digest' );

  timestamp ( );
  fprintf ( 1, '\n' );
  fprintf ( 1, 'test_partial_digest_test():\n' );
  fprintf ( 1, '  MATLAB/Octave version %s\n', version ( ) );
  fprintf ( 1, '  test_partial_digest() creates test problems for the\n' );
  fprintf ( 1, '  partial digest problem.\n' );
%
%  Request a sample problem.
%
  k = 6;
  dmax = 20;

  fprintf ( 1, '\n' );
  fprintf ( 1, '  Number of nodes = %d\n', k );
  fprintf ( 1, '  Maximum distance = %d\n', dmax );
  
  [ locate, d ] = test_partial_digest ( k, dmax );
%
%  Sort the data.
%
  locate = sort ( locate );
  d = sort ( d );
%
%  Print the data.
%
  i4vec_print ( k, locate, '  Locations:' );
  i4vec_print ( k * ( k - 1 ) / 2, d, '  Distances:' );
%
%  Terminate.
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'test_partial_digest_test():\n' );
  fprintf ( 1, '  Normal end of execution.\n' );
  fprintf ( 1, '\n' );
  timestamp ( );

  rmpath ( '../test_partial_digest' );

  return
end
function timestamp ( )

%*****************************************************************************80
%
%% timestamp() prints the current YMDHMS date as a timestamp.
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    14 February 2003
%
%  Author:
%
%    John Burkardt
%
  t = now;
  c = datevec ( t );
  s = datestr ( c, 0 );
  fprintf ( 1, '%s\n', s );

  return
end

