function x = gompertz_sample ( a, b )

%*****************************************************************************80
%
%% gompertz_sample() samples the Gompertz PDF.
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    12 September 2004
%
%  Author:
%
%    John Burkardt
%
%  Input:
%
%    real A, B, the parameters of the PDF.
%    1 < A, 0 < B.
%
%  Output:
%
%    real X, a sample of the PDF.
%
  cdf = rand ( 1, 1 );

  x = gompertz_cdf_inv ( cdf, a, b );

  return
end
