function permutation_distance_stats_test ( )

%*****************************************************************************80
%
%% permutation_distance_stats_test() tests permutation_distance_stats().
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    14 September 2022
%
%  Author:
%
%    John Burkardt
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'permutation_distance_stats_test():\n' );
  fprintf ( 1, '  Test permutation_distance_stats().\n' );

  n = 10000;
  fprintf ( 1, '  Using N = %d sample permutations.\n', n );
  fprintf ( 1, '  Permutation order is M\n' );
  fprintf ( 1, '  Compute mean and variance of Ulam permutation distance.\n' );
  fprintf ( 1, '\n' );

  fprintf ( 1, '   M   Mean    Variance\n' );
  fprintf ( 1, '\n' );
  for m = 5 : 20
    [ mu, variance ] = permutation_distance_stats ( m, n );
    fprintf ( 1, '  %2d  %g  %g\n', m, mu, variance );
  end

  return
end

