function graph_adj_transitive_closure_test ( )

%*****************************************************************************80
%
%% graph_adj_transitive_closure_test() tests graph_adj_transitive_closure().
%
%  Diagram:
%
%    1--5      2
%    | /|
%    |/ |      8--3--7
%    4  6
%
%  Licensing:
%
%    This code is distributed under the MIT license. 
%
%  Modified:
%
%    02 March 2023
%
%  Author:
%
%    John Burkardt
%
  node_num = 8;
  adj = zeros ( node_num, node_num );

  for i = 1 : node_num
    adj(i,i) = 1;
  end

  adj(1,4) = 1;
  adj(1,5) = 1;

  adj(3,7) = 1;
  adj(3,8) = 1;

  adj(4,1) = 1;
  adj(4,5) = 1;

  adj(5,1) = 1;
  adj(5,4) = 1;
  adj(5,6) = 1;

  adj(6,5) = 1;

  adj(7,3) = 1;

  adj(8,3) = 1;

  fprintf ( 1, '\n' );
  fprintf ( 1, 'graph_adj_transitive_closure_test():\n' );
  fprintf ( 1, '  graph_adj_transitive_closure() finds the transitive\n' );
  fprintf ( 1, '  closure of a graph;\n' );

  fprintf ( 1, '\n' );
  fprintf ( 1, '  Adjacency for G:\n' );
  disp ( adj );

  c = graph_adj_transitive_closure ( adj );

  fprintf ( 1, '\n' );
  fprintf ( 1, '  Adjacency for transitive closure:\n' );
  disp ( c );

  return
end
