function interp_test ( )
%
%  Modified:
%
%    16 January 2020
%
%  Reference:
%
%    Kendall Atkinson, Weimin Han,
%    Elementary Numerical Analysis,
%    Wiley, 2004,
%    ISBN: 0471433373,
%    LC: QA297.A83.2004.
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'interp_test:\n' );
  fprintf ( 1, '  Test interp():\n' );

  nint = 11;
  xint = linspace ( 0.0, 2.0, nint );
  yint = humps_fun ( xint );

  np = 101;
  xp = linspace ( 0.0, 2.0, np );
  yp = interp ( xint, yint, xp );

  ytrue = humps_fun ( xp );

  hold ( 'on' )
  plot ( xp, ytrue, 'b-' )
  plot ( xp, yp, 'r', 'LineWidth', 1 )
  plot ( xint, yint, '.', 'markersize', 15 )
  legend('True function','Interpolant', 'Data' )
  hold ( 'off' )
  filename = 'interp_test.png';
  print ( '-dpng', filename );
  fprintf ( 1, '  Graphics saved as "%s"\n', filename );
  pause ( 5.0 )

  return
end


