
I'm not sure if this can be done in the command window, but in a Live Script matrix output can be shown with square brackets.
A = rand(3);
sympref('FloatingPointOutput',true);
sympref('MatrixWithSquareBrackets',true);
disp(sym(A))


Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!