5.0

5.0 | 5 ratings Rate this file 117 downloads (last 30 days) File Size: 1.39 KB File ID: #10203

cholhilb

by Yi Cao

 

02 Mar 2006 (Updated 03 Mar 2006)

Code covered by BSD License  

Cholesky factorization of the Hilbert matrix of order n

Download Now | Watch this File

File Information
Description

The Hilbert matrix is extremely ill-conditioned, hence cannot be factorized by standard algorithms. However, an analytic solution for its Cholesky factorization exists, which has not been included in the current MATLAB function library.

MATLAB release MATLAB 7.1.0 (R14SP3)
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Comments and Ratings (4)
08 Mar 2006 John D'Errico

It indeed does produce a Cholesky factor, although the transpose of what chol would return. (Why does anyone need a hilbert matrix Cholesky factor?) I did verify that it is a valid Cholesky factor UP to n = 98, far beyond what chol can do. For n = 99 and above it began to generate some NaNs in the matrix. So beware the test cases in the help that show the use of cholhilb for n = 100 or even 1000.

08 Mar 2006 Yi Cao

On my machine (XP, MATLAB 7.1), it works upto n=171 without any NaNs although beyond n=85, there are zeros in the diagnal. The need for the Cholesky factor of a Hilbert matrix comes from a least square optimization problem, where the original objective function is J=integral of 0.5z(x)'z(x)dx and z(x) is a nth order polynomial of x and its coefficients are nonlinear functions of decision variables to be optimized. This problem can be represented as a nonlinear least square problem, i.e. J=0.5X'HX, where X is a coefficient matrix of z(x) and H is the Hilbter matrix. Therefore, to solve the nonlinear least square problem, we need the Cholesky factor of the Hilbert matrix.

09 Mar 2006 John D'Errico

Thanks for the explanation. Its apparent there is either a matlab release or OS related difference in this. But n=98 or 171 is still a serious improvement over the point where the direct chol(hilb(n)) gives up. chol only got as far as n=12 for me.

05 Apr 2009 V. Poor  
Please login to add a comment or rating.
Tag Activity for this File
Tag Applied By Date/Time
linear algebra Yi Cao 22 Oct 2008 08:17:18
cholesky factorization Yi Cao 22 Oct 2008 08:17:18
hilbert matrix Yi Cao 22 Oct 2008 08:17:18
algorithms Yi Cao 22 Oct 2008 08:17:18
solution Yi Cao 22 Oct 2008 08:17:18
 

MATLAB Central Terms of Use

NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content. Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available via MATLAB Central. Read the complete Terms prior to use.

Contact us at files@mathworks.com