function errors_test08 ( )

%*****************************************************************************80
%
%% ERRORS_TEST08
%
%  Licensing:
%
%    This code is distributed under the GNU LGPL license.
%
%  Modified:
%
%    24 August 2017
%
%  Author:
%
%    John Burkardt
%
  fprintf ( 1, '\n' );
  fprintf ( 1, '+=============================================+\n' );
  fprintf ( 1, '|                                             |\n' );
  fprintf ( 1, '|  Exercise 8                                 |\n' );
  fprintf ( 1, '|                                             |\n' );
  fprintf ( 1, '|    P(X) =                                   |\n' );
  fprintf ( 1, '|        170.4  * x^3                         |\n' );
  fprintf ( 1, '|      - 356.41 * x^2                         |\n' );
  fprintf ( 1, '|      + 168.97 * x                           |\n' );
  fprintf ( 1, '|      +  18.601                              |\n' );
  fprintf ( 1, '|                                             |\n' );
  fprintf ( 1, '|  Seek the minimizer X* of P(X)              |\n' );
  fprintf ( 1, '|  over the interval 0 <= X <= 2.             |\n' );
  fprintf ( 1, '|                                             |\n' );
  fprintf ( 1, '|  The true minimizer lies in the interval    |\n' );
  fprintf ( 1, '|                                             |\n' );
  fprintf ( 1, '|  [1.091607978, 1.091607981 ]                |\n' );
  fprintf ( 1, '|                                             |\n' );
  fprintf ( 1, '+=============================================+\n' );

  a = 0.0;
  b = 2.0;

  r = fminbnd ( @f8, a, b );
  f = f8 ( r );

  fprintf ( 1, '  FMINBND finds a minimizer at X = %20.16g\n', r );
  fprintf ( 1, '  with function value P(X) = %20.16g\n', f );

  return
end
