function r8_erf_inverse_test ( )

%*****************************************************************************80
%
%% r8_erf_inverse_test() tests r8_erf_inverse().
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    05 August 2010
%
%  Author:
%
%    John Burkardt
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'r8_erf_inverse_test():\n' );
  fprintf ( 1, '  r8_erf_inverse() inverts the error function.\n' );
  fprintf ( 1, '\n' );
  fprintf ( 1, '    FX            X    R8_ERF_INVERSE(FX)\n' );
  fprintf ( 1, '\n' );

  n_data = 0;

  while ( true )

    [ n_data, x1, fx ] = erf_values ( n_data );

    if ( n_data == 0 )
      break
    end

    x2 = r8_erf_inverse ( fx );

    fprintf ( 1, '  %6f  %12f  %12f\n', fx, x1, x2 );

  end

  return
end
