MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi
Learn moreOpportunities for recent engineering grads.
Apply TodayNew to MATLAB?
MATLAB Central > MATLAB Newsreader > reshaping matrix 

hello, 
On May 18, 10:23 pm, "Snow White" <gulesa...@gmail.com> wrote: 
i tried it as follows 

I want [a] to be arranged such that the resultant matrix has three rows and pmn columns and the depth of the matrix is p which is the length of vector a.so in the third dimension the first dimension will have all ones and then the second will have 0s and so on.. 
i have tried using this... 
Snow White wrote: 

i want b to be as follows: 

number of columns=mxn which is the number of row multiplied by columns 
A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.
Anyone can tag a thread. Tags are public and visible to everyone.