octave-bug-tracker
[Top][All Lists]
Advanced

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

[Octave-bug-tracker] [bug #29768] logm fix


From: Jaroslav Hajek
Subject: [Octave-bug-tracker] [bug #29768] logm fix
Date: Fri, 07 May 2010 10:19:46 +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

Follow-up Comment #7, bug #29768 (project octave):

I removed the old unconditional error checks because Matlab doesn't seem to
do them either:
>> sqrtm([1 -1 -1; 0 1 -1; 0 1 -1]) 

ans =

   1.0e+08 *

    0.0000    1.0183   -1.0183
         0    0.5092   -0.5092
         0    0.5092   -0.5092


I believe the residual argument is intended to verify the result:

octave:1> [x,err] = sqrtm([1 -1 -1; 0 1 -1; 0 1 -1])
warning: sqrtm: matrix is singular, may not have a square root
x =

  1.0000e+00 + 0.0000e+00i  -3.0000e+00 - 1.3422e+08i  1.0000e+00 +
1.3422e+08i
  0.0000e+00 + 0.0000e+00i  0.0000e+00 - 6.7109e+07i  0.0000e+00 +
6.7109e+07i
  0.0000e+00 + 0.0000e+00i  0.0000e+00 - 6.7109e+07i  0.0000e+00 +
6.7109e+07i

err =  1.9640

isntead of computing the exact residual (which can be costly), Matlab also
allows estimating it using a special power method technique. Octave currently
can't.



    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?29768>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/





reply via email to

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