Pregunta


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 9 años hace | 1 respuesta | 0

1

respuesta

Pregunta


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 9 años hace | 3 respuestas | 0

3

respuestas

Pregunta


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 9 años hace | 3 respuestas | 0

3

respuestas

Pregunta


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 9 años hace | 1 respuesta | 0

1

respuesta

Pregunta


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 9 años hace | 1 respuesta | 0

1

respuesta

Pregunta


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? ...

más de 9 años hace | 1 respuesta | 0

1

respuesta

Pregunta


How to add a header line to txt file?
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...

más de 9 años hace | 1 respuesta | 0

1

respuesta

Pregunta


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...

más de 9 años hace | 3 respuestas | 0

3

respuestas

Pregunta


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 = [...

más de 9 años hace | 3 respuestas | 0

3

respuestas

Pregunta


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? ...

más de 9 años hace | 1 respuesta | 0

1

respuesta

Pregunta


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...

más de 9 años hace | 1 respuesta | 0

1

respuesta

Pregunta


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...

más de 9 años hace | 1 respuesta | 0

1

respuesta

Pregunta


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...

más de 9 años hace | 1 respuesta | 0

1

respuesta

Pregunta


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...

más de 9 años hace | 1 respuesta | 0

1

respuesta

Pregunta


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 ...

más de 9 años hace | 1 respuesta | 0

1

respuesta

Pregunta


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...

más de 9 años hace | 1 respuesta | 0

1

respuesta

Pregunta


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...

más de 9 años hace | 1 respuesta | 1

1

respuesta

Pregunta


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 ...

más de 9 años hace | 2 respuestas | 0

2

respuestas

Pregunta


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>> ...

más de 9 años hace | 3 respuestas | 0

3

respuestas

Pregunta


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...

más de 9 años hace | 2 respuestas | 0

2

respuestas

Pregunta


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...

más de 9 años hace | 1 respuesta | 0

1

respuesta

Pregunta


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 ...

más de 9 años hace | 1 respuesta | 0

1

respuesta

Pregunta


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] ...

casi 10 años hace | 2 respuestas | 0

2

respuestas

Pregunta


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] ...

casi 10 años hace | 3 respuestas | 0

3

respuestas

Pregunta


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...

casi 10 años hace | 1 respuesta | 0

1

respuesta

Pregunta


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...

casi 10 años hace | 2 respuestas | 0

2

respuestas

Pregunta


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...

casi 10 años hace | 1 respuesta | 0

1

respuesta

Pregunta


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 = [...

casi 10 años hace | 1 respuesta | 0

1

respuesta

Pregunta


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)...

casi 10 años hace | 1 respuesta | 0

1

respuesta

Pregunta


Sum repetition in matrices
Hi everyone, Suppose I have matrix d1, d2, d3, d4, d5: d1 = [0 0 0 1;0 0 0 0]; % input data d2 = [0 0 0 0;1 0 0 0...

casi 10 años hace | 1 respuesta | 0

1

respuesta

Cargar más