help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: chol2inv for Octave?


From: Mike Miller
Subject: Re: chol2inv for Octave?
Date: Fri, 6 May 2005 09:49:25 -0500 (CDT)

On Fri, 6 May 2005, David Bateman wrote:

Octave has the "chol" function to calculate the cholesky factorization of a symmetric positive definite matrix, however octave can't have use of the fact that the factorization is triangular in its solve function to just have to do a back substitution.

By Octave's "solve function" do you mean "inv" or "\"? If it's "\" -- can that be used to obtain an inverse? In R, the "solve" function can have one argument or two. It's like this:

R method     Octave method
----------  ---------------
solve(A,b)      A\b
solve(A)       inv(A)

If we wish to have "inv" test the matrix type before computing the inverse, I suggest that we have several "inv" functions (inv1, inv2, inv3, etc. - with better names, I hope) so that the testing step can be skipped when the matrix is of a known type. Maybe "invpds" would compute the inverse of a positive definite symmetric matrix. I still think chol2inv isn't a bad idea.

Here are some interesting tidbits:

Linpack:
http://docs.sun.com/app/docs/doc/802-6439/6ia4l8o3b?a=view

MATLAB:
http://www.mathworks.com/access/helpdesk/help/toolbox/dspblks/choleskyinverse.html


Thanks for the reply, Dave!

Mike



-------------------------------------------------------------
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
-------------------------------------------------------------



reply via email to

[Prev in Thread] Current Thread [Next in Thread]