diff liboctave/dMatrix.cc @ 12986:f217edac2c71 stable

fix dimension check for A'\B (bug #33997) * xdiv.cc (mx_leftdiv_conform): New arg, blas_trans. Change all callers. * dMatrix.cc: New tests.
author John W. Eaton <jwe@octave.org>
date Mon, 22 Aug 2011 21:20:42 -0400
parents 12df7854fa7c
children 0413227e407b
line wrap: on
line diff
--- a/liboctave/dMatrix.cc
+++ b/liboctave/dMatrix.cc
@@ -3112,14 +3112,19 @@
 
 /* Test some simple identities
 %!shared M, cv, rv
-%! M = randn(10,10);
+%! M = randn(10,10)+100*eye(10,10);
+%! Mt = M';
 %! cv = randn(10,1);
+%! cvt = cv';
 %! rv = randn(1,10);
+%! rvt = rv';
 %!assert([M*cv,M*cv],M*[cv,cv],1e-14)
 %!assert([M'*cv,M'*cv],M'*[cv,cv],1e-14)
 %!assert([rv*M;rv*M],[rv;rv]*M,1e-14)
 %!assert([rv*M';rv*M'],[rv;rv]*M',1e-14)
 %!assert(2*rv*cv,[rv,rv]*[cv;cv],1e-14)
+%!assert(M'\cv,Mt\cv,1e-14)
+%!assert(M'\rv',Mt\rvt,1e-14)
 */
 
 static inline char