The commands:
>> mat = magic( 4 );
>> out = cat( 3, mat, mat );
concatenate matrix 'mat', along third dimension, 2 time and produce a 4-by-4-by-2 array
how to do this work 'n' time an produce a 4-by-4-by-n array without using loop?
I know this is possible by using a cell array like this:
>> out = cat( 3, cellArray{:} );
but how to create this cell array? :
>> cellArray = {mat, mat, ... , mat}; % n time
how to Concatenate arrays n time in matlab ?