[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Problem of polyfit
From: |
Fredrik Lingvall |
Subject: |
Re: Problem of polyfit |
Date: |
Fri, 07 Oct 2005 10:32:47 +0200 |
User-agent: |
Mozilla Thunderbird 1.0.6 (X11/20051004) |
Tetsuro KURITA wrote:
Also following two equations do not return same results, when
calculating data I posted.
p = inv(X'*X)*(X'*y);
p = (X'*X)\(X'*y);
In the case of data I posted, first equation give better results. It
looks that the operator "\" have a certain limitation. What is that ?
Can you post the output of norm( inv(X'*X)*X'*y - (X'*X)\X'*y )?
A simple test on my machine:
octave:26> X=randn(100,100);
octave:27> y=randn(100,1);
octave:28> norm( inv(X'*X)*X'*y - (X'*X)\X'*y )
ans = 3.7190e-13
Fredrik
-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.
Octave's home on the web: http://www.octave.org
How to fund new projects: http://www.octave.org/funding.html
Subscription information: http://www.octave.org/archive.html
-------------------------------------------------------------
- Problem of polyfit, Tetsuro KURITA, 2005/10/06
- Re: Problem of polyfit, Paul Kienzle, 2005/10/06
- Re: Problem of polyfit, Tetsuro KURITA, 2005/10/06
- Re: Problem of polyfit, Paul Kienzle, 2005/10/06
- Re: Problem of polyfit, Tetsuro KURITA, 2005/10/06
- Re: Problem of polyfit, Dmitri A. Sergatskov, 2005/10/07
- Re: Problem of polyfit, Tetsuro KURITA, 2005/10/07
- Re: Problem of polyfit,
Fredrik Lingvall <=
- Re: Problem of polyfit, Tetsuro KURITA, 2005/10/07
- Re: Problem of polyfit, Paul Kienzle, 2005/10/07
- Re: Problem of polyfit, Fredrik Lingvall, 2005/10/07
- Re: Problem of polyfit, Paul Kienzle, 2005/10/07
Re: Problem of polyfit, Fredrik Lingvall, 2005/10/06
Re: Problem of polyfit, Dmitri A. Sergatskov, 2005/10/07
Re: Problem of polyfit, Henry F. Mollet, 2005/10/06