function i4_to_pascal_test ( )

%*****************************************************************************80
%
%% i4_to_pascal_test() tests i4_to_pascal().
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    13 April 2015
%
%  Author:
%
%    John Burkardt
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'i4_to_pascal_test():\n' );
  fprintf ( 1, '  i4_to_pascal() converts a linear index to\n' );
  fprintf ( 1, '  Pascal triangle indices.\n' );
  fprintf ( 1, '\n' );
  fprintf ( 1, '     K  =>   I     J\n' );
  fprintf ( 1, '\n' );

  for k = 1 : 20

    [ i, j ] = i4_to_pascal ( k );

    fprintf ( 1, '  %4d    %4d  %4d\n', k, i, j );

  end

  return
end
