function boundary_range_test ( )

%*****************************************************************************80
%
%% boundary_range_test() tests boundary_range().
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    05 November 2020
%
%  Author:
%
%    John Burkardt
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'boundary_range_test():\n' );
  fprintf ( 1, '  boundary_range() finds the minimum and maximum I and J\n' );
  fprintf ( 1, '  coordinates of a polyiamond drawn from its boundary word\n' );
  fprintf ( 1, '  and starting at P.\n' );
  fprintf ( 1, '\n' );
  fprintf ( 1, '        Name  Imin  Imax  Jmin  Jmax  Pi  Pj  Word\n' );
  fprintf ( 1, '\n' );

  name = 'tiny';
  [ w, p ] = boundary_tiny ( );
  [ imin, imax, jmin, jmax ] = boundary_range ( w, p );
  fprintf ( 1, '  %10s  %4d  %4d  %4d  %4d  %2d  %2d  %s\n', ...
    name, imin, imax, jmin, jmax, p(1), p(2), ['"', w, '"'] );

  for k = 1 : 12
    name = name_hexiamond ( k );
    [ w, p ] = boundary_hexiamond ( k );
    [ imin, imax, jmin, jmax ] = boundary_range ( w, p );
    fprintf ( 1, '  %10s  %4d  %4d  %4d  %4d  %2d  %2d  %s\n', ...
      name, imin, imax, jmin, jmax, p(1), p(2), ['"', w, '"'] );
  end

  name = 'gort';
  [ w, p ] = boundary_gort ( );
  [ imin, imax, jmin, jmax ] = boundary_range ( w, p );
  fprintf ( 1, '  %10s  %4d  %4d  %4d  %4d  %2d  %2d  %s\n', ...
    name, imin, imax, jmin, jmax, p(1), p(2), ['"', w, '"'] );

  return
end

