function cheby_test ( )

%*****************************************************************************80
%
%% cheby_test() tests cheby().
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    21 September 2011
%
%  Author:
%
%    John Burkardt
%
  nf = 5;
  npl = 10;

  fprintf ( 1, '\n' );
  fprintf ( 1, 'cheby_test():\n' );
  fprintf ( 1, '  cheby() computes the Chebyshev series for several functions.\n' );

  x = cheby ( nf, npl, @functn );

  fprintf ( 1, '\n' );
  fprintf ( 1, '        Sin(x)      Cos(x)    Sin(2x)     Cos(2x)       X^5\n' );
  fprintf ( 1, '\n' );

  for i = 1 : npl
    fprintf ( 1, '  %10.4f  %10.f  %10.4f  %10.4f  %10.4f\n', x(i,1:nf) );
  end

  return
end
