function r = rayleigh ( A, x )
%
% function r = rayleigh ( A, x )
%
%  Discussion:
%
%    RAYLEIGH computes the Rayleigh quotient ( x' * A * x ) / ( x' * x ).
%
%  Modified:
%
%    06 April 2000
%
%  Author:
%
%    John Burkardt
%
%  Parameters:
%
%    Input, real A(N,N), the matrix.
%
%    Input, real X(N), the vector.
%
%    Output, real R, the Rayleigh quotient.
%
r = ( x' * A * x ) / ( x' * x );


