function jacobi_dn_test ( )

%*******************************************************************************
%
%% JACOBI_DN_TEST tests JACOBI_DN.
%
%  Licensing:
%
%    This code is distributed under the GNU LGPL license.
%
%  Modified:
%
%    25 June 2018
%
%  Author:
%
%    John Burkardt
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'JACOBI_DN_TEST:\n' );
  fprintf ( 1, '  JACOBI_DN evaluates the Jacobi elliptic function DN.\n' );
  fprintf ( 1, '\n' );
  fprintf ( 1, '    U       M       Exact DN                DN(U,M)\n' );
  fprintf ( 1, '\n' );

  n_data = 0;

  while ( true )

    [ n_data, u, m, dn1 ] = jacobi_dn_values ( n_data );

    if ( n_data == 0 )
      break;
    end

    dn2 = jacobi_dn ( u, m );

    fprintf ( 1, '%8.4f%8.4f%24.16g%24.16g\n', u, m, dn1, dn2 );

  end

  return
end