# HG changeset patch # User Chris Cannam # Date 1382719025 -3600 # Node ID 11c8a8e666900684d1ae6b0fb912c0723a907ea6 # Parent 38a35e4b41c5b8ed897591f808e2d57b4f061ec6 Add flipped (storage order) diff -r 38a35e4b41c5 -r 11c8a8e66690 src/may/matrix/complex.yeti --- a/src/may/matrix/complex.yeti Fri Oct 25 16:56:03 2013 +0100 +++ b/src/may/matrix/complex.yeti Fri Oct 25 17:37:05 2013 +0100 @@ -106,6 +106,13 @@ imaginary = maybe none (Some . mat.transposed) cm.imaginary, }; +flipped cm = + { + size = { rows = cm.size.columns, columns = cm.size.rows }, + real = maybe none (Some . mat.flipped) cm.real, + imaginary = maybe none (Some . mat.flipped) cm.imaginary, + }; + toSparse cm = (ts = maybe none (Some . mat.toSparse); cm with { real = ts cm.real, imaginary = ts cm.imaginary }); @@ -253,6 +260,7 @@ equal, conjugateTransposed, transposed, + flipped, toSparse, toDense, scaled, @@ -283,6 +291,7 @@ equal is complexmatrix -> complexmatrix -> boolean, conjugateTransposed is complexmatrix -> complexmatrix, transposed is complexmatrix -> complexmatrix, + flipped is complexmatrix -> complexmatrix, toSparse is complexmatrix -> complexmatrix, toDense is complexmatrix -> complexmatrix, scaled is number -> complexmatrix -> complexmatrix,