function p = goldie ( )

%*****************************************************************************80
%
%% goldie()  What does this function do?
%
%  Licensing:
%
%    Copyright 2014 The MathWorks, Inc.
%
%  Author:
%
%    Cleve Moler
%
%  Reference:
%
%    Cleve Moler,
%    Experiments with MATLAB
%    https://www.mathworks.com/moler
%
p = 0
A = [1 1; 1 0]
x = [1 1]'
while p ~= x(1)/x(2)
   p = x(1)/x(2)
   x = A*x
end
