Electronic Transactions on Numerical Analysis vol:3 pages:1-23
We give the solution of a discrete least squares approximation problem in terms of orthonormal polynomial vectors with respect to a discrete inner product. The degrees of the polynomial elements of these vectors can be different. An algorithm is constructed computing the coefficients of recurrence relations for the orthonormal polynomial vectors. In case the weight vectors are prescribed in points on the real axis or on the unit circle, variants of the original algorithm can be designed which are an order of magnitude more efficient. Although the recurrence relations require all previous vectors to compute the next orthonormal polynomial vector, in the real or the unit-circle case only a fixed number of previous vectors are required. As an application, we approximate a vector-valued function by a vector rational function in a linearized least squares sense.