function r8sr_mv_test ( )

%*****************************************************************************80
%
%% R8SR_MV_TEST tests R8SR_MV.
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    13 June 2016
%
%  Author:
%
%    John Burkardt
%
  n = 5;
  nz = 7;
  col = [ 2, 5, 5, 1, 1, 2, 3 ];
  row = [ 1, 3, 4, 5, 6, 8 ];
  seed = 123456789;

  fprintf ( 1, '\n' );
  fprintf ( 1, 'R8SR_MV_TEST\n' );
  fprintf ( 1, '  R8SR_MV multiplies an R8SR matrix by a vector;\n' );
  fprintf ( 1, '\n' );
  fprintf ( 1, '  Matrix order N = %d\n', n );
%
%  Set the matrix.
%
  [ diag, off, seed ] = r8sr_random ( n, nz, row, col, seed );
%
%  Make a R8GE copy.
%
  c = r8sr_to_r8ge ( n, nz, row, col, diag, off );
%
%  Print the R8GE copy.
%
  r8ge_print ( n, n, c, '  The R8SR matrix, in R8GE form:' );

  x = zeros ( n, 1 );

  x(1) = 1.0;
  x(n) = -1.0;

  r8vec_print ( n, x, '  The vector x:' );

  b = r8sr_mv ( n, nz, row, col, diag, off, x );

  r8vec_print ( n, b, '  The product A * x:' );

  return
end
