function graph_adj_is_eulerian_test ( )

%*****************************************************************************80
%
%% graph_adj_is_eulerian_test() tests graph_adj_is_eulerian().
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    11 March 2023
%
%  Author:
%
%    John Burkardt
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'graph_adj_is_eulerian_test( ):\n' );
  fprintf ( 1, '  graph_adj_is_eulerian() determines whether a graph\n' );
  fprintf ( 1, '  is eulerian.\n' );

  A = [ ...
    0,0,1,0,0,0,1,0,0,1; ...
    0,0,0,0,1,0,0,0,0,1; ...
    1,0,0,0,0,1,0,0,1,0; ...
    0,0,0,0,0,0,1,1,0,0; ...
    0,1,0,0,0,0,0,0,0,0; ...
    0,0,1,0,0,0,0,0,1,0; ...
    1,0,0,1,0,0,0,0,0,0; ...
    0,0,0,1,0,0,0,0,0,1; ...
    0,0,1,0,0,1,0,0,0,0; ...
    1,1,0,0,0,0,0,1,0,0 ];

  fprintf ( 1, '\n' );
  fprintf ( 1, '  Matrix A:\n' );
  disp ( A );

  [ circuit_eulerian, path_eulerian ] = graph_adj_is_eulerian ( A );
  fprintf ( 1, '  circuit_eulerian = %s\n', mat2str ( circuit_eulerian ) );
  fprintf ( 1, '  path_eulerian    = %s\n', mat2str ( path_eulerian ) );

  B = [ ...
    0,0,1,0,1,0,1,0,0,1; ...
    0,0,0,0,1,0,0,0,0,1; ...
    1,0,0,0,0,1,0,0,1,0; ...
    0,0,0,0,0,0,1,1,0,0; ...
    1,1,0,0,0,0,0,0,0,0; ...
    0,0,1,0,0,0,0,0,1,0; ...
    1,0,0,1,0,0,0,0,0,0; ...
    0,0,0,1,0,0,0,0,0,1; ...
    0,0,1,0,0,1,0,0,0,0; ...
    1,1,0,0,0,0,0,1,0,0 ];

  fprintf ( 1, '\n' );
  fprintf ( 1, '  Matrix B:\n' );
  disp ( B );

  [ circuit_eulerian, path_eulerian ] = graph_adj_is_eulerian ( B );
  fprintf ( 1, '  circuit_eulerian = %s\n', mat2str ( circuit_eulerian ) );
  fprintf ( 1, '  path_eulerian    = %s\n', mat2str ( path_eulerian ) );

  C = [ ...
    0,0,1,0,1,0,1,0,0,1; ...
    0,0,0,0,1,0,0,0,0,1; ...
    1,0,0,0,0,1,0,0,1,1; ...
    0,0,0,0,0,0,1,1,0,0; ...
    1,1,0,0,0,0,0,0,0,0; ...
    0,0,1,0,0,0,0,0,1,0; ...
    1,0,0,1,0,0,0,0,0,0; ...
    0,0,0,1,0,0,0,0,0,1; ...
    0,0,1,0,0,1,0,0,0,0; ...
    1,1,1,0,0,0,0,1,0,0 ];

  fprintf ( 1, '\n' );
  fprintf ( 1, '  Matrix C:\n' );
  disp ( C );

  [ circuit_eulerian, path_eulerian ] = graph_adj_is_eulerian ( C );
  fprintf ( 1, '  circuit_eulerian = %s\n', mat2str ( circuit_eulerian ) );
  fprintf ( 1, '  path_eulerian    = %s\n', mat2str ( path_eulerian ) );

  return
end

