function ww_product_integral_test ( )

%*****************************************************************************80
%
%% WW_PRODUCT_INTEGRAL_TEST tests WW_PRODUCT_INTEGRAL.
%
%  Discussion:
%
%    This process should match the WW_MASS_MATRIX computation.
%
%  Licensing:
%
%    This code is distributed under the GNU LGPL license.
%
%  Modified:
%
%    13 July 2015
%
%  Author:
%
%    John Burkardt
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'WW_PRODUCT_INTEGRAL_TEST:\n' );
  fprintf ( 1, '  WW_PRODUCT_INTEGRAL computes the product integral\n' );
  fprintf ( 1, '  of a pair of Chebyshev W polynomials W(i,x) and W(j,x).\n' );
  fprintf ( 1, '  A(I,J) = integral ( -1 <=x <= +1 ) W(i,x) W(j,x) sqrt ( 1 - x ) / sqrt ( 1 + x ) dx\n' );
  fprintf ( 1, '  0  if i is not equal to j;\n' );
  fprintf ( 1, '  pi if i = j\n' );

  n = 4;

  a = zeros ( n + 1, n + 1 );

  for i = 0 : n
    for j = 0 : n
      a(i+1,j+1) = ww_product_integral ( i, j );
    end
  end

  r8mat_print ( n + 1, n + 1, a, '  W(i,x)*W(j,x) integral matrix:' );

  return
end