gistlib
To write a matrix in MATLAB, you can directly assign values to a variable using square brackets [ ] with rows separated by semicolons ;.
[ ]
;
Here's an example of how you can write a 2x3 matrix in MATLAB:
main.mA = [1, 2, 3; 4, 5, 6]; 30 chars3 lines
A = [1, 2, 3; 4, 5, 6];
gistlibby LogSnag