function english_word_length_sample_test ( )

%*****************************************************************************80
%
%% ENGLISH_WORD_LENGTH_SAMPLE_TEST tests ENGLISH_WORD_LENGTH_SAMPLE.
%
%  Licensing:
%
%    This code is distributed under the GNU LGPL license.
%
%  Modified:
%
%    08 April 2016
%
%  Author:
%
%    John Burkardt
%
  sample_num = 1000;

  seed = 123456789;

  fprintf ( 1, '\n' );
  fprintf ( 1, 'ENGLISH_WORD_LENGTH_SAMPLE_TEST\n' );
  fprintf ( 1, '  ENGLISH_WORD_LENGTH_MEAN computes the English Word Length mean;\n' );
  fprintf ( 1, '  ENGLISH_WORD_LENGTH_SAMPLE samples the English Word Length distribution;\n' );
  fprintf ( 1, '  ENGLISH_WORD_LENGTH_VARIANCE computes the English Word Length variance.\n' );

  mean = english_word_length_mean ( );
  variance = english_word_length_variance ( );

  fprintf ( 1, '\n' );
  fprintf ( 1, '  PDF mean =                    %14g\n', mean );
  fprintf ( 1, '  PDF variance =                %14g\n', variance );

  for i = 1 : sample_num
    [ x(i), seed ] = english_word_length_sample ( seed );
  end

  mean = i4vec_mean ( sample_num, x );
  variance = i4vec_variance ( sample_num, x );
  xmax = i4vec_max ( sample_num, x );
  xmin = i4vec_min ( sample_num, x );

  fprintf ( 1, '\n' );
  fprintf ( 1, '  Sample size =     %12d\n', sample_num );
  fprintf ( 1, '  Sample mean =     %14g\n', mean );
  fprintf ( 1, '  Sample variance = %14g\n', variance );
  fprintf ( 1, '  Sample maximum =  %14d\n', xmax );
  fprintf ( 1, '  Sample minimum =  %14d\n', xmin );

  return
end
