function ijk_to_xy_test ( )

%*****************************************************************************80
%
%% ijk_to_xy_test tests ijk_to_xy().
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    25 August 2020
%
%  Author:
%
%    John Burkardt
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'ijk_to_xy_test\n' );
  fprintf ( 1, '  MATLAB/Octave version %s\n', version ( ) );
  fprintf ( 1, '  ijk_to_xy returns the (x,y) vertex coordinates of a\n' );
  fprintf ( 1, '  triangle, given its (i,j,k) coordinates.\n' );
%
%  Check the 4x5 parallelogram
%
  fprintf ( 1, '\n' );
  fprintf ( 1, '  (I,J,K)    (X1,Y1)  (X2,Y2)  (X3,Y3)\n' );
  for j = 1 : 4
    fprintf ( 1, '\n' );
    for i = 1 : 5
      for k = 0 : 1
        ijk = [ i, j, k ];
        [ x, y ] = ijk_to_xy ( ijk );
        fprintf ( 1, '  (%d,%d)   (%f,%f)   (%f,%f)   (%f,%f)\n', ...
          i, j, x(1), y(1), x(2), y(2), x(3), y(3) );
      end
    end
  end
%
%  Terminate.
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'ijk_to_xy_test\n' );
  fprintf ( 1, '  Normal end of execution.\n' );

  return
end
