how to have A and A' show 3x2 column vector
1 次查看(过去 30 天)
显示 更早的评论
so for A = [1 2 3; 4 5 6]
I want A AND A' to BOTH display:
1 4
2 5
3 6
0 个评论
回答(1 个)
Walter Roberson
2022-11-21
You will need to create a new class that is derived from double, and for the new class you will need to either change the vertcat() and horzcat() operators, or else the disp() or display() function; which of the methods you override depends upon whether you want the result of constructing A to be a 3 x 2 array (despite the array seemingly having been constructed as 2 x 3), or if instead you only need A to display as-if it is 3 x 2 .
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Multidimensional Arrays 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!