function cobweb_plot_test ( )

%*****************************************************************************80
%
%% cobweb_plot_test() tests cobweb_plot().
%
%  Licensing:
%
%    This code is distributed under the MIT license. 
%
%  Modified:
%
%    27 February 2020
%
%  Author:
%
%    Original Python code by John D Cook.
%    This version by John Burkardt
%
  addpath ( '../cobweb_plot' );

  timestamp ( );
  fprintf ( 1, '\n' );
  fprintf ( 1, 'cobweb_plot_test():\n' );
  fprintf ( 1, '  MATLAB/Octave version %s\n', version ( ) );
  fprintf ( 1, '  Test cobweb_plot().\n' );

  cobweb_plot ( @(x)cos(x), 1.0, 20, 0.0, 1.0, 'cos.png' );
  cobweb_plot ( @(x)0.5*x+1.0./x, 0.5, 20, 0.2, 4.0, 'sqrt2.png' );
  cobweb_plot ( @(x)2*abs(x-0.5), 0.123, 20, 0.0, 1.0, 'tent.png' );
  cobweb_plot ( @(x)0.5*x.*(1.0-x), 0.9, 20, 0.0, 1.0, 'logistic_0.5.png' );
  cobweb_plot ( @(x)1.5*x.*(1.0-x), 0.01, 20, 0.0, 1.0, 'logistic_1.5.png' );
  cobweb_plot ( @(x)2.5*x.*(1.0-x), 0.01, 20, 0.0, 1.0, 'logistic_2.5.png' );
  cobweb_plot ( @(x)3.5*x.*(1.0-x), 0.01, 20, 0.0, 1.0, 'logistic_3.5.png' );
  cobweb_plot ( @(x)3.6*x.*(1.0-x), 0.01, 40, 0.0, 1.0, 'logistic_3.6.png' );
  cobweb_plot ( @(x)3.7*x.*(1.0-x), 0.01, 40, 0.0, 1.0, 'logistic_3.7.png' );
  cobweb_plot ( @(x)3.8*x.*(1.0-x), 0.01, 40, 0.0, 1.0, 'logistic_3.8.png' );
%
%  Terminate.
%
  fprintf ( 1, '' );
  fprintf ( 1, 'cobweb_plot_test():\n' );
  fprintf ( 1, '  Normal end of execution.\n' );
  fprintf ( 1, '\n' );
  timestamp ( );

  rmpath ( '../cobweb_plot' );

  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

