function boundary_print ( w, p, label )

%*****************************************************************************80
%
%% boundary_print() prints the boundary word of a polyhex.
%
%  Discussion:
%
%    The boundary word describes how to trace the boundary by starting
%    at a base point P=(i,j), and taking a sequence of steps of unit length 
%    in one of 6 directions, as suggested by these diagrams:
%
%          3     2-----*             3     2     *  
%      ^        /                ^    \         /   
%     /        /                /      \       /     
%    J  4-----P     1          J  4     P-----1      
%      /       \                       /             
%     /         \                     /              
%    *     5     6             *-----5     6         
%
%          I-->                      I-->           
%
%    If the current position P has parallelogram coordinates (I,J), then
%    the step of given index moves to
%
%      1  (I+1,J)
%      2  (I,  J+1)
%      3  (I-1,J+1)
%      4  (I-1,J)
%      5  (I,  J-1)
%      6  (I+1,J-1)
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    22 June 2021
%
%  Author:
%
%    John Burkardt
%
%  Input:
%
%    string W: the boundary word. 
%
%    integer P(2): the boundary word start point.
%
%    string LABEL: a label to be printed.  
%
  fprintf ( 1, '\n' );
  fprintf ( 1, '%s\n', label );
  fprintf ( 1, '\n' );
  fprintf ( 1, '  hex boundary word:  "%s"\n', w );
  fprintf ( 1, '  base point (i,j)   :  [ %d, %d ]\n', p(1), p(2) );

  return
end

