Rayleigh quotient

From HandWiki
Short description: Construct for Hermitian matrices

In mathematics, the Rayleigh quotient[1] (/ˈr.li/) for a given complex Hermitian matrix [math]\displaystyle{ M }[/math] and nonzero vector [math]\displaystyle{ x }[/math] is defined as:[2][3][math]\displaystyle{ R(M,x) = {x^{*} M x \over x^{*} x}. }[/math]For real matrices and vectors, the condition of being Hermitian reduces to that of being symmetric, and the conjugate transpose [math]\displaystyle{ x^{*} }[/math] to the usual transpose [math]\displaystyle{ x' }[/math]. Note that [math]\displaystyle{ R(M, c x) = R(M,x) }[/math] for any non-zero scalar [math]\displaystyle{ c }[/math]. Recall that a Hermitian (or real symmetric) matrix is diagonalizable with only real eigenvalues. It can be shown that, for a given matrix, the Rayleigh quotient reaches its minimum value [math]\displaystyle{ \lambda_\min }[/math] (the smallest eigenvalue of [math]\displaystyle{ M }[/math]) when [math]\displaystyle{ x }[/math] is [math]\displaystyle{ v_\min }[/math] (the corresponding eigenvector).[4] Similarly, [math]\displaystyle{ R(M, x) \leq \lambda_\max }[/math] and [math]\displaystyle{ R(M, v_\max) = \lambda_\max }[/math].

The Rayleigh quotient is used in the min-max theorem to get exact values of all eigenvalues. It is also used in eigenvalue algorithms (such as Rayleigh quotient iteration) to obtain an eigenvalue approximation from an eigenvector approximation.

The range of the Rayleigh quotient (for any matrix, not necessarily Hermitian) is called a numerical range and contains its spectrum. When the matrix is Hermitian, the numerical radius is equal to the spectral norm. Still in functional analysis, [math]\displaystyle{ \lambda_\max }[/math] is known as the spectral radius. In the context of [math]\displaystyle{ C^\star }[/math]-algebras or algebraic quantum mechanics, the function that to [math]\displaystyle{ M }[/math] associates the Rayleigh–Ritz quotient [math]\displaystyle{ R(M, x) }[/math] for a fixed [math]\displaystyle{ x }[/math] and [math]\displaystyle{ M }[/math] varying through the algebra would be referred to as vector state of the algebra.

In quantum mechanics, the Rayleigh quotient gives the expectation value of the observable corresponding to the operator [math]\displaystyle{ M }[/math] for a system whose state is given by [math]\displaystyle{ x }[/math].

If we fix the complex matrix [math]\displaystyle{ M }[/math], then the resulting Rayleigh quotient map (considered as a function of [math]\displaystyle{ x }[/math]) completely determines [math]\displaystyle{ M }[/math] via the polarization identity; indeed, this remains true even if we allow [math]\displaystyle{ M }[/math] to be non-Hermitian. However, if we restrict the field of scalars to the real numbers, then the Rayleigh quotient only determines the symmetric part of [math]\displaystyle{ M }[/math].

Bounds for Hermitian M

As stated in the introduction, for any vector x, one has [math]\displaystyle{ R(M,x) \in \left[\lambda_\min, \lambda_\max \right] }[/math], where [math]\displaystyle{ \lambda_\min, \lambda_\max }[/math] are respectively the smallest and largest eigenvalues of [math]\displaystyle{ M }[/math]. This is immediate after observing that the Rayleigh quotient is a weighted average of eigenvalues of M: [math]\displaystyle{ R(M,x) = {x^{*} M x \over x^{*} x} = \frac{\sum_{i=1}^n \lambda_i y_i^2}{\sum_{i=1}^n y_i^2} }[/math] where [math]\displaystyle{ (\lambda_i, v_i) }[/math] is the [math]\displaystyle{ i }[/math]-th eigenpair after orthonormalization and [math]\displaystyle{ y_i = v_i^* x }[/math] is the [math]\displaystyle{ i }[/math]th coordinate of x in the eigenbasis. It is then easy to verify that the bounds are attained at the corresponding eigenvectors [math]\displaystyle{ v_\min, v_\max }[/math].

The fact that the quotient is a weighted average of the eigenvalues can be used to identify the second, the third, ... largest eigenvalues. Let [math]\displaystyle{ \lambda_{\max} = \lambda_1 \ge \lambda_2 \ge \cdots \ge \lambda_n = \lambda_{\min} }[/math] be the eigenvalues in decreasing order. If [math]\displaystyle{ n=2 }[/math] and [math]\displaystyle{ x }[/math] is constrained to be orthogonal to [math]\displaystyle{ v_1 }[/math], in which case [math]\displaystyle{ y_1 = v_1^*x = 0 }[/math], then [math]\displaystyle{ R(M,x) }[/math] has maximum value [math]\displaystyle{ \lambda_2 }[/math], which is achieved when [math]\displaystyle{ x = v_2 }[/math].

Special case of covariance matrices

An empirical covariance matrix [math]\displaystyle{ M }[/math] can be represented as the product [math]\displaystyle{ A'A }[/math] of the data matrix [math]\displaystyle{ A }[/math] pre-multiplied by its transpose [math]\displaystyle{ A' }[/math]. Being a positive semi-definite matrix, [math]\displaystyle{ M }[/math] has non-negative eigenvalues, and orthogonal (or orthogonalisable) eigenvectors, which can be demonstrated as follows.

Firstly, that the eigenvalues [math]\displaystyle{ \lambda_i }[/math] are non-negative: [math]\displaystyle{ \begin{align} &M v_i = A' A v_i = \lambda_i v_i \\ \Rightarrow{}& v_i' A' A v_i = v_i' \lambda_i v_i \\ \Rightarrow{}& \left\| A v_i \right\|^2 = \lambda_i \left\| v_i \right\|^2 \\ \Rightarrow{}& \lambda_i = \frac{\left\| A v_i \right\|^2}{\left\| v_i \right\|^2} \geq 0. \end{align} }[/math]

Secondly, that the eigenvectors [math]\displaystyle{ v_i }[/math] are orthogonal to one another: [math]\displaystyle{ \begin{align} &M v_i = \lambda _i v_i \\ \Rightarrow{}& v_j' M v_i = v_j' \lambda _i v_i \\ \Rightarrow{}& \left (M v_j \right )' v_i = \lambda_j v_j' v_i \\ \Rightarrow{}& \lambda_j v_j ' v_i = \lambda _i v_j' v_i \\ \Rightarrow{}& \left (\lambda_j - \lambda_i \right ) v_j ' v_i = 0 \\ \Rightarrow{}& v_j ' v_i = 0 \end{align} }[/math] if the eigenvalues are different – in the case of multiplicity, the basis can be orthogonalized.

To now establish that the Rayleigh quotient is maximized by the eigenvector with the largest eigenvalue, consider decomposing an arbitrary vector [math]\displaystyle{ x }[/math] on the basis of the eigenvectors [math]\displaystyle{ v_i }[/math]: [math]\displaystyle{ x = \sum _{i=1} ^n \alpha _i v_i, }[/math] where [math]\displaystyle{ \alpha_i = \frac{x' v_i}{v_i' v_i} = \frac{\langle x,v_i\rangle}{\left\| v_i \right\| ^2} }[/math] is the coordinate of [math]\displaystyle{ x }[/math] orthogonally projected onto [math]\displaystyle{ v_i }[/math]. Therefore, we have: [math]\displaystyle{ \begin{align} R(M,x) &= \frac{x' A' A x}{x' x} \\ &= \frac{ \Bigl( \sum _{j=1} ^n \alpha _j v_j \Bigr)' \left ( A' A \right ) \Bigl(\sum _{i=1} ^n \alpha _i v_i \Bigr)}{ \Bigl( \sum _{j=1} ^n \alpha _j v_j \Bigr)' \Bigl( \sum _{i=1} ^n \alpha _i v_i \Bigr)} \\ &= \frac{ \Bigl( \sum _{j=1} ^n \alpha _j v_j \Bigr)'\Bigl(\sum _{i=1} ^n \alpha _i (A' A) v_i \Bigr)}{ \Bigl( \sum _{i=1}^n \alpha _i^2 {v_i}'{v_i} \Bigr)} \\ &= \frac{ \Bigl( \sum _{j=1} ^n \alpha _j v_j \Bigr)'\Bigl(\sum _{i=1} ^n \alpha _i \lambda_i v_i \Bigr)}{ \Bigl( \sum _{i=1}^n \alpha _i^2 \|{v_i}\|^2 \Bigr)} \end{align} }[/math] which, by orthonormality of the eigenvectors, becomes: [math]\displaystyle{ \begin{align} R(M,x) &= \frac{\sum _{i=1} ^n \alpha_i^2 \lambda _i}{\sum _{i=1} ^n \alpha_i^2} \\ &= \sum_{i=1}^n \lambda_i \frac{(x'v_i)^2}{ (x'x)( v_i' v_i)^2} \\ &= \sum_{i=1}^n \lambda_i \frac{(x'v_i)^2}{ (x'x)} \end{align} }[/math]

The last representation establishes that the Rayleigh quotient is the sum of the squared cosines of the angles formed by the vector [math]\displaystyle{ x }[/math] and each eigenvector [math]\displaystyle{ v_i }[/math], weighted by corresponding eigenvalues.

If a vector [math]\displaystyle{ x }[/math] maximizes [math]\displaystyle{ R(M,x) }[/math], then any non-zero scalar multiple [math]\displaystyle{ kx }[/math] also maximizes [math]\displaystyle{ R }[/math], so the problem can be reduced to the Lagrange problem of maximizing [math]\displaystyle{ \sum _{i=1}^n \alpha_i^2 \lambda _i }[/math] under the constraint that [math]\displaystyle{ \sum _{i=1} ^n \alpha _i ^2 = 1 }[/math].

Define: [math]\displaystyle{ \beta_i = \alpha_i^2 }[/math]. This then becomes a linear program, which always attains its maximum at one of the corners of the domain. A maximum point will have [math]\displaystyle{ \alpha_1 = \pm 1 }[/math] and [math]\displaystyle{ \alpha _i = 0 }[/math] for all [math]\displaystyle{ i \gt 1 }[/math] (when the eigenvalues are ordered by decreasing magnitude).

Thus, the Rayleigh quotient is maximized by the eigenvector with the largest eigenvalue.

Formulation using Lagrange multipliers

Alternatively, this result can be arrived at by the method of Lagrange multipliers. The first part is to show that the quotient is constant under scaling [math]\displaystyle{ x \to cx }[/math], where [math]\displaystyle{ c }[/math] is a scalar [math]\displaystyle{ R(M,cx) = \frac {(cx)^{*} M cx} {(cx)^{*} cx} = \frac {c^{*} c} {c^{*} c} \frac {x^{*} M x} {x^{*} x} = R(M,x). }[/math]

Because of this invariance, it is sufficient to study the special case [math]\displaystyle{ \|x\|^2 = x^Tx = 1 }[/math]. The problem is then to find the critical points of the function [math]\displaystyle{ R(M,x) = x^\mathsf{T} M x , }[/math] subject to the constraint [math]\displaystyle{ \|x\|^2 = x^Tx = 1. }[/math] In other words, it is to find the critical points of [math]\displaystyle{ \mathcal{L}(x) = x^\mathsf{T} M x -\lambda \left (x^\mathsf{T} x - 1 \right), }[/math] where [math]\displaystyle{ \lambda }[/math] is a Lagrange multiplier. The stationary points of [math]\displaystyle{ \mathcal{L}(x) }[/math] occur at [math]\displaystyle{ \begin{align} &\frac{d\mathcal{L}(x)}{dx} = 0 \\ \Rightarrow{}& 2x^\mathsf{T}M - 2\lambda x^\mathsf{T} = 0 \\ \Rightarrow{}& 2Mx - 2\lambda x = 0 \text{ (taking the transpose of both sides and noting that }M\text{ is Hermitian)}\\ \Rightarrow{}& M x = \lambda x \end{align} }[/math] and [math]\displaystyle{ \therefore R(M,x) = \frac{x^\mathsf{T} M x}{x^\mathsf{T} x} = \lambda \frac{x^\mathsf{T}x}{x^\mathsf{T} x} = \lambda. }[/math]

Therefore, the eigenvectors [math]\displaystyle{ x_1, \ldots, x_n }[/math] of [math]\displaystyle{ M }[/math] are the critical points of the Rayleigh quotient and their corresponding eigenvalues [math]\displaystyle{ \lambda_1, \ldots, \lambda_n }[/math] are the stationary values of [math]\displaystyle{ \mathcal{L} }[/math]. This property is the basis for principal components analysis and canonical correlation.

Use in Sturm–Liouville theory

Sturm–Liouville theory concerns the action of the linear operator [math]\displaystyle{ L(y) = \frac{1}{w(x)}\left(-\frac{d}{dx}\left[p(x)\frac{dy}{dx}\right] + q(x)y\right) }[/math] on the inner product space defined by [math]\displaystyle{ \langle{y_1,y_2}\rangle = \int_a^b w(x)y_1(x)y_2(x) \, dx }[/math] of functions satisfying some specified boundary conditions at a and b. In this case the Rayleigh quotient is [math]\displaystyle{ \frac{\langle{y,Ly}\rangle}{\langle{y,y}\rangle} = \frac{\int_a^b y(x)\left(-\frac{d}{dx}\left[p(x)\frac{dy}{dx}\right] + q(x)y(x)\right)dx}{\int_a^b{w(x)y(x)^2}dx}. }[/math]

This is sometimes presented in an equivalent form, obtained by separating the integral in the numerator and using integration by parts: [math]\displaystyle{ \begin{align} \frac{\langle{y,Ly}\rangle}{\langle{y,y}\rangle} &= \frac{ \left \{ \int_a^b y(x)\left(-\frac{d}{dx}\left[p(x)y'(x)\right]\right) dx \right \} + \left \{\int_a^b{q(x)y(x)^2} \, dx \right \}}{\int_a^b{w(x)y(x)^2} \, dx} \\ &= \frac{ \left \{\left. -y(x)\left[p(x)y'(x)\right] \right |_a^b \right \} + \left \{\int_a^b y'(x)\left[p(x)y'(x)\right] \, dx \right \} + \left \{\int_a^b{q(x)y(x)^2} \, dx \right \}}{\int_a^b w(x)y(x)^2 \, dx}\\ &= \frac{ \left \{ \left. -p(x)y(x)y'(x) \right |_a^b \right \} + \left \{ \int_a^b \left [p(x)y'(x)^2 + q(x)y(x)^2 \right] \, dx \right \} } {\int_a^b{w(x)y(x)^2} \, dx}. \end{align} }[/math]

Generalizations

  1. For a given pair (A, B) of matrices, and a given non-zero vector x, the generalized Rayleigh quotient is defined as: [math]\displaystyle{ R(A,B; x) := \frac{x^* A x}{x^* B x}. }[/math] The Generalized Rayleigh Quotient can be reduced to the Rayleigh Quotient [math]\displaystyle{ R(D, C^*x) }[/math] through the transformation [math]\displaystyle{ D = C^{-1} A {C^*}^{-1} }[/math] where [math]\displaystyle{ CC^* }[/math] is the Cholesky decomposition of the Hermitian positive-definite matrix B.
  2. For a given pair (x, y) of non-zero vectors, and a given Hermitian matrix H, the generalized Rayleigh quotient can be defined as: [math]\displaystyle{ R(H; x,y) := \frac{y^* H x}\sqrt{y^*y \cdot x^*x} }[/math] which coincides with R(H,x) when x = y. In quantum mechanics, this quantity is called a "matrix element" or sometimes a "transition amplitude".

See also

References

  1. Also known as the Rayleigh–Ritz ratio; named after Walther Ritz and Lord Rayleigh.
  2. Horn, R. A.; Johnson, C. A. (1985). Matrix Analysis. Cambridge University Press. pp. 176–180. ISBN 0-521-30586-1. https://books.google.com/books?id=PlYQN0ypTwEC&pg=PA176. 
  3. Parlett, B. N. (1998). The Symmetric Eigenvalue Problem. Classics in Applied Mathematics. SIAM. ISBN 0-89871-402-8. 
  4. Costin, Rodica D. (2013). "Midterm notes". Mathematics 5102 Linear Mathematics in Infinite Dimensions, lecture notes. The Ohio State University. https://people.math.osu.edu/costin.10/5102/Rayleigh%20quotient.pdf. 

Further reading