Question

How to select random number in a matrix?
The following command can find all max values in each iteration of matrix m and then chose *first* one: [rowsOfMaxes colsOf...

más de 7 años ago | 1 answer | 0

### 1

Question

How to sum up of sum unique arrays in a matrix
Suppose I have a matrix a: a = [12,7,1,1,1,1;28,5,2,1,1,1;28,4,2,2,1,1;32,10,2,1,1,1;32,10,2,2,1,1;37,2,4,1,1,1;48,11,4,1...

más de 7 años ago | 3 answers | 0

### 3

Question

How to make a new matrix with all common arrays from different matrices
Suppose I have some matrices as follow: m1 = [1;2;3;4;5;6;7;8]; m2 = [2;3;4;6;7;8;9;10;11;12]; m3 = [4;5;6;7;8;9;1;;1...

más de 7 años ago | 3 answers | 0

### 3

Question

Join some matrices without repeating arrays
Suppose I have matrices r1, r2 and r3 as follows: r1 = [50;10;90;30]; r2 = [60;50]; r3 = [30;20;100]; I need a joi...

más de 7 años ago | 1 answer | 0

### 1

Question

How to remove some arrays in a matrix
Suppose I have a matrix m: m = [3;5;6;1;2;8;5;2;9;1;2;7;8;3;4;9;3]; and restricted matrices r1 and r2: r1 = [5;1;9;...

más de 7 años ago | 1 answer | 0

### 1

Question

How to split output in Matlab and save it in two different excel files?
Is there any way that we can split output and save it two different excel files or even two different sheets in a excel file? ...

casi 8 años ago | 1 answer | 0

### 1

Question

How can I add a header line to the following code (header for txt output): O = [2,1;4,6;2,10;6,800]; fid = fopen('Output...

casi 8 años ago | 1 answer | 0

### 1

Question

How to find index of first 3 maximum number in matrix
I have the following function that n is the first 3 maximum value of matrix m: m = [7;1;4;4;12;2;6;10;2]; temp = sort( m...

casi 8 años ago | 3 answers | 0

### 3

Question

How to get first 3 maximum number in a matrix
Suppose I have a matrix m: m = [7;1;4;4;12;2;6;10;2]; I want to find first 3 maximum in matrix m, means like: n = [...

casi 8 años ago | 3 answers | 0

### 3

Question

Join some matrices to one matrix
I have a cell array of matrix m{j} % which row numbers are different in each j How can I bring all of them in one matrix? ...

casi 8 años ago | 1 answer | 0

### 1

Question

Mis match of dimensions
Suppose I want to find all maximum number in the matrix m: I used this command line: mm(:,:,j) = find( m(:,:,j) == maxli...

casi 8 años ago | 1 answer | 0

### 1

Question

Reshape a matrix in different way
Is there any other way to re-code this function (perhaps with for loop): mmm = [2;3;4;8;9;11;13;14;15;16]; Dmm = zeros(2...

casi 8 años ago | 1 answer | 0

### 1

Question

Sum of all odd and even arrays in matrix
Suppose I have a matrix a: a = [2,3;1,2;1,2;0,1;1,2;3,1;1,3;2,1;2,3;3,1]; I want to build matrix b with dimension 2*2 th...

casi 8 años ago | 1 answer | 0

### 1

Question

Creating a new matrix from two matrixes
Suppose I have a matrix a: a = [9,1;1,1;3,1;2,1;5,1;6,1;8,1;1,1;2,1;5,1;8,1;2,1]; And I have another matrix b which is l...

casi 8 años ago | 1 answer | 0

### 1

Question

Bhilding new matrix with selected index number
Suppose I have a matrix a: a = [9;1;3;2;5;6;8;1;2;5;8;2]; And I have another matrix b which is like some selected index ...

casi 8 años ago | 1 answer | 0

### 1

Question

How to build a new matrix
I have a matrix a = [4;6;8;2;8;2]; And I want it to be like: b = [7;8;11;12;15;16;3;4;15;16;3;4]; Matrix b is ca...

casi 8 años ago | 1 answer | 0

### 1

Question

How to find a subset matrix in the main matrix and build a new matrix
Hi everyone, Suppose I have two matrices A and B. The matrix A is a subset of matrix B (it can be possible that some of array...

casi 8 años ago | 1 answer | 1

### 1

Question

Filtering a matrix to some small matrices
Hi everyone, Suppose I have a matrix: a = [12,7;12,5;2,7;23,3;23,43;23,12;3,5;76,21;76,31;4,3;4,7;4,9]; Then I want ...

alrededor de 8 años ago | 2 answers | 0

### 2

Question

Classification of a matrix to 0 and 1 matrix
Hello everyone, I want matrix A to be like matrix B <</matlabcentral/answers/uploaded_files/15256/Hesam%20(1).jpg>> ...

alrededor de 8 años ago | 3 answers | 0

### 3

Question

How to find repeated array in a matrix
Hello everyone, Suppose matrix a is like: a=[1;2;2;3;3;4;5;6;6;7;7;7;8]; and matrix b: b=[2;7;1;3;2]; Then, I...

alrededor de 8 años ago | 2 answers | 0

### 2

Question

How to create a new matrix with some known rows
Hello everyone, Suppose matrix a is like: a = [2;3;6;2]; b = [1 3 6;2 3 7;2 2 1;3 1 9;3 2 8;4 1 5]; Then, I want m...

alrededor de 8 años ago | 1 answer | 0

### 1

Question

Counting duplicate cells in a matrix
Hello everyone, Suppose matrix a is like: a = [12,28,28,32,32,37,48,72,72,73,73,73,97,100,100,100]; I want matrix b ...

alrededor de 8 años ago | 1 answer | 0

### 1

Question

List of maximum number in the matrix
Hi everyone, Suppose I have a matrix: a = [3;1;4;2;3;4;1;4;3;1;2;4]; Then I want matrix b to be: b = [3;6;8;12] ...

alrededor de 8 años ago | 2 answers | 0

### 2

Question

Creating a matrix by some other matrices
Suppos I have: a = [3;3;5;8;2;1;8;1;5]; b = 2 I want matrix c to be: c = [3 2;3 2;5 2;8 2;2 2;1 2;8 2;1 2;5 2] ...

alrededor de 8 años ago | 3 answers | 0

### 3

Question

Updating values with for-loop
Hello everyone, I want to update the matrix "e" according to the new value of matrix "d" for each iteration. Matrix "d" i...

más de 8 años ago | 1 answer | 0

### 1

Question

Replacing row number with value
Hi everyone, Suppose I have a matrix a: a = [2 2;1 1;4 1;3 1;4 2]; and matrix b: b = [3;5;1;5;2;4;2;3;5;1]; T...

más de 8 años ago | 2 answers | 0

### 2

Question

Save max of each iteration
Suppose that matrix A have new value in each iteration (updatable), Is there anyway to save the rowsOfMaxes matrix A in each ite...

más de 8 años ago | 1 answer | 0

### 1

Question

Find the first position of maximum value in a Matrix
Hello everyone, Suppose there can be the max value at more than one location, how can I catch the first max value. A = [...

más de 8 años ago | 1 answer | 0

### 1

Question

How to save maximum value in each iteration
Hi everyone, Suppose I have a for-loop: a=rand(1); n(:,:,1) = zeros(1,1); for i = 2:4 n(:,:,i) = n(:,:,i-1)...

más de 8 años ago | 1 answer | 0