function r8utp_size_test ( )

%*****************************************************************************80
%
%% r8utp_size_test() tests r8utp_size().
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    14 August 2022
%
%  Author:
%
%    John Burkardt
%
  m = 4;
 
  fprintf ( 1, '\n' );
  fprintf ( 1, 'r8utp_size_test():\n' );
  fprintf ( 1, '  r8utp_size() computes the storage needed for an R8UTP matrix.\n' );
  fprintf ( 1, '\n' );
  fprintf ( 1, '   M   N   Size  Size(check)\n' );
  fprintf ( 1, '\n' );

  for n = [ 3, 4, 6 ]
    value1 = r8utp_size ( m, n );
    value2 = 0;
    for j = 1 : n
      for i = 1 : min ( j, m )
        value2 = value2 + 1;
      end
    end
    fprintf ( '  %2d  %2d  %2d  %2d\n', m, n, value1, value2 )
  end

  return
end
