function [ n_data, p ] = gaussian_prime_complex_values ( n_data )

%*****************************************************************************80
%
%% gaussian_prime_real_values() returns some values of complex (integer) Gaussian primes.
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    26 January 2023
%
%  Author:
%
%    John Burkardt
%
%  Input:
%
%    integer ndata:  The user sets n_data to 0 before the first call.  
%    Thereafter, it should simply be the value returned by the previous call.
%
%  Output:
%
%    integer n_data: On each call, the routine increments n_data by 1, and
%    returns the corresponding data; when there is no more data, the
%    output value of n_data will be 0 again.
%
%    complex p: a complex Gaussian prime.
%
  n_max = 18;

  p_vec = [ ...
    -5-4i;
    -5-2i;
    -5+2i;
    -4-5i;
    -3-2i;
    -3;
    -2-5i;
    -2-i;
    -1-2i;
    -1-i;
     3i;
     1-4i;
     1-2i;
     1-i;
     2-3i;
     3;
     4+i;
     5+4i ];

  if ( n_data < 0 )
    n_data = 0;
  end

  n_data = n_data + 1;

  if ( n_max < n_data )
    n_data = 0;
    p = 0;
  else
    p = p_vec(n_data);
  end

  return
end
