function universal_egg_test ( )

%*****************************************************************************80
%
%% universal_egg_test() tests universal_egg().
%
%  This code does NOT perform as advertised.
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    20 June 2022
%
%  Author:
%
%    John Burkardt
%
%  Reference:
%
%    Valeriy Narushin, Michael Romanov, Darren Griffin,
%    "Egg and math: introducing a universal formula for egg shape",
%    Annals of the New York Academy of Sciences,
%    Number 1505, pages 169-177, 23 August 2021.
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'universal_egg_test():\n' );
  fprintf ( 1, '  universal_egg() evaluates a universal formula\n' );
  fprintf ( 1, '  for bird egg shapes.\n' );

  n = 21;
  B = 0.5;
  L = 1.0;
  w = 0.1;
  D = 0.3;
  x = cheby1space ( - L/2.0, +L/2.0, n );
  y = universal_egg ( B, L, w, D, x );

  clf ( );
  hold ( 'on' );
  plot ( x, y, 'r-', 'linewidth', 3 );
  plot ( x, -y, 'g-', 'linewidth', 3 );
  hold ( 'off' );
  grid ( 'on' );
  axis ( 'equal' );
  title ( 'universal egg' );
  filename = 'universal_egg.png';
  print ( '-dpng', filename );
  fprintf ( 1, '  Graphics saved as "%s"\n', filename )

  return
end


