function bernstein_matrix_determinant_test ( )

%*****************************************************************************80
%
%% bernstein_matrix_determinant_test() tests bernstein_matrix_determinant().
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    26 January 2016
%
%  Author:
%
%    John Burkardt
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'bernstein_matrix_determinant_test():\n' );
  fprintf ( 1, '  bernstein_matrix_determinant() computes the determinant of\n' );
  fprintf ( 1, '  the Bernstein matrix.\n' );
  fprintf ( 1, '\n' );
  fprintf ( 1, '     N         |A|          det(A)            det(A)\n' );
  fprintf ( 1, '                              computed          Matlab\n' );
  fprintf ( 1, '\n' );

  for n = 5 : 15

    a = bernstein_matrix ( n );
    a_norm_frobenius = r8mat_norm_fro ( n, n, a );

    d1 = bernstein_matrix_determinant ( n );
    d2 = det ( a );

    fprintf ( 1, '  %4d  %14g  %14g  %14g\n', n, a_norm_frobenius, d1, d2 );

  end

  return
end

