function lagrange_basis_1d_test ( )

%*****************************************************************************80
%
%% lagrange_basis_1d_test() tests lagrange_basis_1d().
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    30 June 2015
%
%  Author:
%
%    John Burkardt
%
  nd = 4;
  ni = 21;

  xd = [ 0.0; 2.0; 5.0; 10.0 ];

  fprintf ( 1, '\n' );
  fprintf ( 1, 'lagrange_basis_1d_test():\n' );
  fprintf ( 1, '  lagrange_basis_1d() evaluates the Lagrange 1D basis functions.\n' );

  x_min = 0.0;
  x_max = 10.0;
  xi = ( linspace ( x_min, x_max, ni ) )';

  lb = lagrange_basis_1d ( nd, xd, ni, xi );

  disp ( '  The Lagrange basis functions:' );
  disp ( lb );

  return
end
