Search All of the Math Forum:
Views expressed in these public forums are not endorsed by
NCTM or The Math Forum.



Re: convert a matrix to vector
Posted:
Dec 13, 2012 3:29 PM


> "yafit maymon" wrote in message <i9rjub$jmg$1@fred.mathworks.com>... >> hello!!! i need to convert a matrix in to a vector , i have tried to >> use the reshape function but it does not convert the way i want , i >> need, for example : the matrix: >> 2 3 4 5 >> 6 7 >> >> >> and i need it to convert to a vector like this: [2 3 4 5 6 7 ] >> >> thank you ifor your help ....
A = [2 3; 4 5; 6 7]; v = reshape( A.' ,1,numel(A)); disp(v)
bartekltg



