function boundary_rotate_test ( )

%*****************************************************************************80
%
%% boundary_rotate_test() tests boundary_rotate().
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    19 June 2024
%
%  Author:
%
%    John Burkardt
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'boundary_rotate_test():\n' );
  fprintf ( 1, '  boundary_rotate() rotates a polyiamond\n' );
  fprintf ( 1, '  described by its boundary word.\n' );

  for r = 0 : 6

    k = 10;
    [ w, p ] = boundary_hexiamond ( k );
    name = name_hexiamond ( k );

    [ w2, p2 ] = boundary_rotate ( w, p, r );
    name2 = sprintf ( 'boundary_rotate_snake_%d', r * 60 );
    boundary_print ( w2, p2, name2 );

    clf ( );
    color = 'cyan';
    number = false;
    boundary_plot ( w2, p2, color, number );
    name3 = s_escape_tex ( name2 );
    title ( name3 );
    filename = [ name2, '.png' ];
    print ( '-dpng', filename );
    fprintf ( 1, '  Graphics saved as "%s"\n', filename );
  end

  return
end

