function triangulation_test19 ( )

%*****************************************************************************80
%
%% TEST19 tests TRIANGULATION_NEIGHBOR_ELEMENTS.
%
%  Licensing:
%
%    This code is distributed under the GNU LGPL license.
%
%  Modified:
%
%    07 September 2009
%
%  Author:
%
%    John Burkardt
%
  triangle_order = 3;
  triangle_num = 16;

  triangle_node(1:triangle_order,1:triangle_num) = [ ...
     3,   4,   1; ...
     3,   1,   2; ...
     3,   2,   8; ...
     2,   1,   5; ...
     8,   2,  13; ...
     8,  13,   9; ...
     3,   8,   9; ...
    13,   2,   5; ...
     9,  13,   7; ...
     7,  13,   5; ...
     6,   7,   5; ...
     9,   7,   6; ...
    10,   9,   6; ...
     6,   5,  12; ...
    11,   6,  12; ...
    10,   6,  11 ]';

  fprintf ( 1, '\n');
  fprintf ( 1, 'TEST19\n' );
  fprintf ( 1, '  TRIANGULATION_NEIGHBOR_ELEMENTS determines the\n' );
  fprintf ( 1, '  adjacency relationships between elements.\n' );

  i4mat_transpose_print ( triangle_order, triangle_num, triangle_node, ...
    '  Elements:' );

  triangle_neighbor = triangulation_neighbor_elements ( triangle_order, ...
    triangle_num, triangle_node );

  i4mat_transpose_print ( 3, triangle_num, triangle_neighbor, ...
    '  Element neighbors:' );

  return
end
