function fprime = r8mat_jac_exact ( m, n, x )

%*****************************************************************************80
%
%% r8mat_jac_exact() is the exact jacobian of R8LIB_TEST067_F.
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    19 April 2009
%
%  Author:
%
%    John Burkardt
%
%  Input:
%
%    integer M, the number of functions.
%
%    integer N, the number of parameters.
%
%    real X(N), the parameter values.
%
%  Output:
%
%    real FPRIME(M,N), the jacobian values.
%
  fprime = zeros(m,n);

  fprime(1,1) = cos ( x(1) * x(2) ) * x(2);
  fprime(1,2) = cos ( x(1) * x(2) ) * x(1);
  fprime(1,3) = 0.0;
  fprime(1,4) = 0.0;

  fprime(2,1) = x(1) / sqrt ( 1.0 + x(1) * x(1) );
  fprime(2,2) = 0.0;
  fprime(2,3) = 1.0;
  fprime(2,4) = 0.0;

  fprime(3,1) = 1.0;
  fprime(3,2) = 2.0;
  fprime(3,3) = 3.0;
  fprime(3,4) = 4.0;

  return
end
