[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #29487] Feature request: svd with 3 output var
From: |
Jaroslav Hajek |
Subject: |
[Octave-bug-tracker] [bug #29487] Feature request: svd with 3 output variables should use dgesdd |
Date: |
Mon, 03 May 2010 11:57:57 +0000 |
User-agent: |
Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.9) Gecko/20100317 SUSE/3.5.9-0.1.1 Firefox/3.5.9 |
Update of bug #29487 (project octave):
Status: Need Info => Fixed
_______________________________________________________
Follow-up Comment #12:
I added svd_driver to Octave. Now I'm getting this:
octave:1> a = randn (1000);
octave:2> svd (1);
octave:3> tic; [u1, s1, v1] = svd (a); toc
Elapsed time is 10.1431 seconds.
octave:4> svd_driver ("gesdd")
ans = gesvd
octave:5> tic; [u2, s2, v2] = svd (a); toc
Elapsed time is 1.70709 seconds.
octave:6> norm (u1*s1*v1' - a, "fro")
ans = 9.7938e-12
octave:7> norm (u2*s2*v2' - a, "fro")
ans = 3.8047e-12
So it's true that gesdd can be much faster. Both drivers seem to be
comparably accurate on normal data, though the singular vectors differ
significantly due to lots of close singular values:
octave:8> norm (u1 - u2, "fro")
ans = 46.562
The default is still gesvd. Add svd_driver ("gesdd") in your .octaverc to
enjoy the speed-up. Beware of possible problems for highly ill-conditioned,
though I failed to produce a matrix that demonstrates this.
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?29487>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
- [Octave-bug-tracker] [bug #29487] Feature request: svd with 3 output variables should use dgesdd,
Jaroslav Hajek <=