function fx = p19_fx ( n, x )

%*****************************************************************************80
%
%% P19_FX evaluates the function for problem 19.
%
%  Discussion:
%
%    This problem has a single root at the origin.  Convergence of the
%    Newton iterates should be monotonic, but only linear in rate,
%    since the jacobian is singular at the origin.
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    10 October 2020
%
%  Author:
%
%    John Burkardt
%
%  Input:
%
%    integer N, the number of variables and equations.
%
%    real X(N), the evaluation point.
%
%  Output:
%
%    real FX(N), the function value.
%
  fx = zeros ( n, 1 );

  fx(1) = x(1) * ( x(1)^2 + x(2)^2 );
  fx(2) = x(2) * ( x(1)^2 + x(2)^2 );

  return
end

