function boxy_test ( )

%*****************************************************************************80
%
%% boxy_test() tests mesh_vtoe().
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    04 September 2017
%
%  Author:
%
%    John Burkardt
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'BOXY_TEST:\n' );
  fprintf ( 1, '  Test MESH_VTOE.\n' );
%
%  Load the ETOV information.
%
  etov = load ( 'boxy_elements.txt' );
  etov = etov';
  [ element_order, element_num ] = size ( etov );
%
%  Assume that the number of vertices is the same as the maximum
%  vertex index.
%
  v_base = min ( min ( etov ) );
  v_num = max ( max ( etov ) );

  if ( v_base == 0 ) 
    v_num = v_num + 1;
  end
%
%  Get the VTOE information.
%
  [ vtoe_pointer, vtoe ] = mesh_vtoe ( element_order, element_num, etov, v_num );
%
%  Display VTOE_POINTER.
%
  fprintf ( 1, '\n' );
  fprintf ( 1, '  VTOE_POINTER\n' );
  fprintf ( 1, '\n' );
  for v = 1 : v_num + 1
    fprintf ( 1, '  %3d:  %4d\n', v, vtoe_pointer(v) );
  end
%
%  Display VTOE.
%
  fprintf ( 1, '\n' );
  fprintf ( 1, '  VTOE\n' );
  fprintf ( 1, '\n' );
  for v = 1 : v_num
    fprintf ( 1, '  %3d:  ', v );
    for k = vtoe_pointer(v) : vtoe_pointer(v+1)-1
      fprintf ( 1, ' %d', vtoe(k) );
    end
    fprintf ( 1, '\n' );
  end
%
%  Terminate.
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'BOXY_TEST:\n' );
  fprintf ( 1, '  Normal end of execution.\n' );

  return
end

