# MATLAB: How to add one space to a matrix

binary operationsstring manipulation

am using this code to generate binary matrix dec2bin(rand(50,1)*2^32) but i need to add one space between the matrix element so i can use it for other commands. the output matrix needs space to be useful for other calculation. how to do this?

m =  dec2bin(rand(50,1)*2^32)mwithspaces = cell2mat(regexprep(num2cell(m, 2),'\d(?=\d)', '\$0 '));