function roulette_value_test ( )

%*****************************************************************************80
%
%% roulette_value_test() tests roulette_value().
%
%  Licensing:
%
%    This code is distributed under the MIT license. 
%
%  Modified:
%
%    29 February 2016
%
%  Author:
%
%    John Burkardt
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'roulette_value_test():\n' );
  fprintf ( 1, '  roulette_value() returns the value of N spins of a roulette\n' );
  fprintf ( 1, '  wheel with M = 36/37/38 pockets.\n' );
  fprintf ( 1, '\n' );
  fprintf ( 1, '  Here, we bet $10 on red every time.\n' );
  fprintf ( 1, '\n' );
  fprintf ( 1, '       M=36        M=37        M=38\n' );
  fprintf ( 1, '\n' );
%
%  Use a fair wheel, and spin in many times.
%
  for m = 36 : 38

    n = m * 100;

    v = roulette_result ( m, n );
%
%  Bet $10 every time.
%
    bet = 10.0;
%
%  Bet on red every time.
%
    [ l, b ] = bet_red ( );
%
%  What is the value of my bet on every turn?
%
    value = roulette_value ( m, n, v, bet, l, b );
%
%  What is the total return of my bets?
%
    result = sum ( value(1:n) );

    fprintf ( 1, '  %10g', result );

  end

  return
end
