Wednesday 18 March 2015

How to Declare a random Matrix M of size N x N in MATLAB

How to Declare a random Matrix M of size N x N.N is a random number(EVEN Number)

You can directly call it in matlab by Downloading the following files.

CODE:

M = uint8(randi([0 255],[88 88]));
p1 = M(1:end/2    ,1:end/2    );



p2 = M(1:end/2    ,end/2+1:end);
p3 = M(end/2+1:end,1:end/2    );
p4 = M(end/2+1:end,end/2+1:end);
N = [p1' p2';p3' p4'];
Download

Download

No comments:

Post a Comment

Android Studio Project Structure

Android Project Structure In this blog i have explained Android project structure and file organization in detail, by creating a new An...