function r8crs_mtv_test ( )

%*****************************************************************************80
%
%% r8crs_mtv_test tests r8crs_mtv.
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    14 February 2020
%
%  Author:
%
%    John Burkardt
%
  n = 5;
  nz = 12;
  col = [ ...
    1, 2, 5, ...
    2, 5, ...
    1, 3, ...
    1, 4, ...
    2, 3, 5 ];
  row = [ 1, 4, 6, 8, 10, 13 ];
  val = [ 11.0, 12.0, 15.0, 22.0, 25.0, 31.0, 33.0, 41.0, 44.0, 52.0, 53.0, 55.0 ];

  fprintf ( 1, '\n' );
  fprintf ( 1, 'r8crs_mtv_test\n' );
  fprintf ( 1, '  r8crs_mtv multiplies an R8CRS matrix transposed times a vector.\n' );
  fprintf ( 1, '\n' );
  fprintf ( 1, '  Matrix order N = %d\n', n );
%
%  Make a R8GE copy.
%
  A = r8crs_to_r8ge ( n, nz, row, col, val );

  x = rand ( n, 1 );

  y1 = r8crs_mtv ( n, nz, row, col, val, x );
  y2 = A' * x;

  r8vec2_print ( n, y1, y2, '  R8CRS and R8GE products:' );

  return
end
