In mathematics, a moment matrix is a special symmetric square matrix whose rows and columns are indexed by monomials. The entries of the matrix depend on the product of the indexing monomials only (cf. Hankel matrices.)
Moment matrices play an important role in polynomial optimization, since positive semidefinite moment matrices correspond to polynomials which are sums of squares, and econometrics.
A multiple linear regression model can be written as
y = β 0 + β 1 x 1 + β 2 x 2 + … β k x k + u where y is the explained variable, x 1 , x 2 … x k are the explanatory variables, u is the error, and β 0 , β 1 … β k are unknown coefficients to be estimated. Given observations { y i , x 1 i , x 2 i , … x k i } i = 1 n , we have a system of n linear equations that can be expressed in matrix notation.
[ y 1 y 2 ⋮ y n ] = [ 1 x 11 x 12 … x 1 k 1 x 21 x 22 … x 2 k ⋮ ⋮ ⋮ ⋱ ⋮ 1 x n 1 x n 2 … x n k ] [ β 0 β 1 ⋮ β k ] + [ u 1 u 2 ⋮ u n ] or
y = X β + u where y and u are each a vector of dimension n × 1 , X is a matrix of order N × ( k + 1 ) , and β is a vector of dimension ( k + 1 ) × 1 . Under the Gauss–Markov assumptions, the best linear unbiased estimator of β is the linear least squares estimator b = ( X T X ) − 1 X T y , involving the two moment matrices X T X and X T y defined as
X T X = [ n ∑ x i 1 ∑ x i 2 … ∑ x i k ∑ x i 1 ∑ x i 1 2 ∑ x i 1 x i 2 … ∑ x i 1 x i k ∑ x i 2 ∑ x i 1 x i 2 ∑ x i 2 2 … ∑ x i 2 x i k ⋮ ⋮ ⋮ ⋱ ⋮ ∑ x i k ∑ x i 1 x i k ∑ x i 2 x i k … ∑ x i k 2 ] and
X T y = [ ∑ y i ∑ x i 1 y i ⋮ ∑ x i k y i ] where obviously X T X is a square matrix of dimension ( k + 1 ) × ( k + 1 ) , and X T y is a vector of dimension ( k + 1 ) × 1 .