function elliptic_pik_test ( )

%*****************************************************************************80
%
%% ELLIPTIC_PIK_TEST tests ELLIPTIC_PIK.
%
%  Licensing:
%
%    This code is distributed under the GNU LGPL license.
%
%  Modified:
%
%    31 May 2018
%
%  Author:
%
%    John Burkardt
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'ELLIPTIC_PIK_TEST:\n' );
  fprintf ( 1, '  ELLIPTIC_PIK returns values of\n' );
  fprintf ( 1, '  the complete elliptic integral of the\n' );
  fprintf ( 1, '  third kind, with parameter K.\n' );
  fprintf ( 1, '\n' );
  fprintf ( 1, '      N            K       Pi(N,K)           Pi(N,K)\n' );
  fprintf ( 1, '                           Tabulated         Calculated\n' );
  fprintf ( 1, '\n' );

  n_data = 0;

  while ( true )

    [ n_data, n, k, pik ] = elliptic_pik_values ( n_data );

    if ( n_data == 0 )
      break
    end

    pik2 = elliptic_pik ( n, k );

    fprintf ( 1, '  %14.6f  %14.6f  %24.16g  %24.16g\n', n, k, pik, pik2 );

  end

  return
end
