function normal_square_test ( )

%*****************************************************************************80
%
%% normal_square_test() tests normal_square().
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    12 April 2022
%
%  Author:
%
%    John Burkardt
%
  n = 1000;
  d = 2;

  fprintf ( 1, '\n' );
  fprintf ( 1, 'normal_square_test():\n' );
  fprintf ( 1, '  normal_square() generates normal points\n' );
  fprintf ( 1, '  in D dimensions, using a zero mean, and with\n' );
  fprintf ( 1, '  the identity as the variance-covariance matrix.\n' );
  fprintf ( 1, '\n' );
  fprintf ( 1, '  Number of points N =    %12d\n', n );
  fprintf ( 1, '  Spatial dimension D =   %12d\n', d );

  p = normal_square ( n, d );
%
%  Make a plot.
%
  clf ( );
  plot ( p(:,1), p(:,2), 'b.' );
  grid ( 'on' );
  axis ( 'equal' );
  xlabel ( '<--- X --->' );
  ylabel ( '<--- Y --->' );
  title ( 'normal\_square() (2D)' );
  filename = 'normal_square.png';
  print ( '-dpng', filename );
  fprintf ( 1, '  Graphics saved as "%s".\n', filename );

  return
end
