I am beginner of Matlab, Please explain the following line. X = [X1 X2];
No products are associated with this question.
X1=12 X2=24 X = [X1 X2] % create a line vector X by horizontal concatenation; Y=[X1;X2] %vertical concatenation
You have to read this
http://www.mathworks.com/matlabcentral/answers/8026-best-way-s-to-master-matlab
That is the same as horzcat; see http://www.mathworks.com/help/matlab/ref/horzcat.html
1 Comment
Direct link to this comment:
http://www.mathworks.com/matlabcentral/answers/58605#comment_122211
The forum is not the right place to explain the basics. The Getting Started chapters of the documentation explain them exhaustively and therefore it is strongly recommended to read them carefully.