function gradient_descent_test ( )

%*****************************************************************************80
%
%% gradient_descent_test() tests gradient_descent().
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    29 July 2022
%
%  Author:
%
%    John Burkardt.
%
  addpath ( '../gradient_descent' );

  timestamp ( );
  fprintf ( 1, '\n' );
  fprintf ( 1, 'gradient_descent_test():\n' );
  fprintf ( 1, '  MATLAB/Octave version %s\n', version ( ) );
  fprintf ( 1, '  gradient_descent() uses derivative information to\n' );
  fprintf ( 1, '  iteratively estimate the minimizer of a function.\n' );

  gradient_descent_data_fitting_test ( );
  gradient_descent_linear_test ( );
  gradient_descent_nonlinear_test ( );
  gradient_descent_stochastic_test ( );
  gradient_descent_vector_x_test ( );
  gradient_descent_vector_f_test ( );
%
%  Terminate.
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'gradient_descent_test():\n' );
  fprintf ( 1, '  Normal end of execution.\n' );
  timestamp ( );

  rmpath ( '../gradient_descent' );

  return
end
function timestamp ( )

%*****************************************************************************80
%
%% timestamp() prints the current YMDHMS date as a timestamp.
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    14 February 2003
%
%  Author:
%
%    John Burkardt
%
  t = now;
  c = datevec ( t );
  s = datestr ( c, 0 );
  fprintf ( 1, '%s\n', s );

  return
end

