Community Profile

# Na

##### Last seen: 9 days ago
104 total contributions since 2018

View details...

Contributions in
View by

Question

How to get the minimum number of rows that, if removed, reduces the rank.
I have a matrix A How can I get the number of rows that make matrix A rank deficient. for example A =[ 6.5480 -6.5480 0...

2 months ago | 1 answer | 1

### 1

Question

produce combination one by one error
I want to produce combination to check some condition. For finding combination, I used combnk. but if n = 32; newn = 31; in...

2 months ago | 1 answer | 0

### 1

Question

keep the index of removed array in cell
I have M = [12,13; 6,12; 6,13; 7,8; 4,5; 5,6; 9,14; 1,2; 1,5; 13,14; 2,5; 4 9]; S = {[7,8],[6,12,13],[4,5,6,9,13,14],[1,2,5]};...

3 months ago | 1 answer | 0

### 1

Question

Find border edges of the graph
I have a graph like this, how I can find border edges. M = [1 8; 7 8; 1 7; 7 6; 1 6; 1 5; 4 5; 1 3; 2 3; 1 2; 1 4]; Layout = [...

3 months ago | 1 answer | 1

### 1

Question

selecting the random element by having distance to others
This code generates random number index = randperm(length(1:200),5); I want to control this generator. Each number have a dist...

4 months ago | 1 answer | 0

### 1

Question

separating element in cell according to some condition
I have A A={[237;238;241;243], [238;237;241;243;247], [241;237;238;243;247],... [243;237;238;241;247;310],[247;238;241;243...

4 months ago | 1 answer | 0

### 1

Question

Merge cell that has common element
I have A ={[1,2; 1,3; 2,4; 3,4; 2,5],[72,73],[5,6; 6,7],[36,39],[71,80;72,80],[27,70;28,71],[39,51],[21,29]}; I want to merge ...

4 months ago | 2 answers | 0

### 2

Question

Getting ith element of each cell array with different sizes in loop
I have A A ={[1;2;3;4],[5;6],[7;8;9;10],[17;13;15;20;25]}; val=cellfun(@(x) numel(x),A); for i=1:length(1:max(val)) te...

4 months ago | 1 answer | 0

### 1

Question

Determine separated node in graph
I have a graph like this s = [1 2 2 4 5 4 8 7 7 8 13]; t = [3 3 11 5 6 6 7 10 12 12 9]; G = graph(s,t); plot(G) Here, I h...

4 months ago | 1 answer | 0

### 1

Question

find row and column of a value in cell array
I have A matrix of dimension 10*10. C is linear index of non zero element in A C = {[11],[33;44;54;55],[77;87;98]}; I want to ...

4 months ago | 2 answers | 0

### 2

Question

Sort cell values greater and smaller than the threshold
I have C={[7],[4],[1],[2],[1],[3]}; A = [1 2 4 9; 6 9 9 13; 9 14 9 15; 11 14 11 14; 13 14 15 18; 11 16 11 16]; thresh = 3; ...

4 months ago | 2 answers | 0

### 2

Question

Select edges that connect subgraphs together
I have a graph like this M = [1 2; 2 3; 1 3; 4 5; 5 6; 6 7; 4 7;2 4; 5 7; 5 8;11 8; 8 9; 9 10; 10 11;4 12; 12,13; 13 14;12 14];...

4 months ago | 2 answers | 1

### 2

Question

Change the order of matrix
I want to change the order of B in accordance with Index. Index means that 'row 2' in B should change to 'row 5' in New_B. I w...

5 months ago | 1 answer | 0

### 1

Question

problem to write a condition for 'if'
I want to save A_new according to this condition: If A_new decreases the length of B, I want to save it. I wrote a code like ...

5 months ago | 1 answer | 0

### 1

Question

finding overlapping and non-overlapping values in matrix
I have A = [3 16 4 16 3 21 4 21 3 29 3 29 17 27 18 29 25 72 ...

5 months ago | 1 answer | 0

### 1

Question

How to reorder cell array based on the vector
I have index = [1; 2; 4; 3; 7; 6; 5]; list = {[1158;1159], [1543;1544], [2020;2096;2173], [2159], [4836], [5374], [5492;5493]...

5 months ago | 1 answer | 0

### 1

Question

using end in array
I have B=[]; A = {[1,2,3,15],[14,15,45,44,38,48,47,46]}; for i=1:length(A) for j=1: length(A{i})-1 temp = A{i}...

5 months ago | 1 answer | 0

### 1

Question

Find ones blocks in upper triangular matrix
I have A A=[0 0 0 0 0 0 0 0 0 0 0 0 0; 0 0 0 0 1 0 1 0 0 0 0 0 0; 0 0 0 0 0 1 0 0 0 0 0 0 0; 0 0 0 0 1 0 1 0 0 0 0 ...

5 months ago | 1 answer | 0

### 1

Question

remove rows in matrix if it is repeated 2 times
A = {[1,6,3,2],[3,6,5]}; A1 = unique([A{:}]); B = [1 2; 1 6; 2 3; 3 5; 3 6; 5 6]; B_bk = [1 2; 3 6; 3 5; 1 4; 4 6; 1 6; 6 5...

5 months ago | 1 answer | 0

### 1

Question

find missing element between two matrix
I have A=[1 2; 3 6; 3 5; 1 4; 4 6; 2 7; 1 6; 6 5; 2 3; 6 7; 3 4]; B=[1 2; 1 6; 2 3; 3 4; 4 6]; I want to find missing elemen...

5 months ago | 1 answer | 0

### 1

Question

save values in array
I have A={[1,6,3,2],[3,5,6]}; all_el =[]; for i=1:length(A) all_el(end)=A{i} end I want to have this result all_ell=...

5 months ago | 2 answers | 0

### 2

Question

produce all combinations of n choose k in binary
I have n=5; k=3; I want to have combinations of n choose k in binary result should be (5 choose 3=10) (the order does not m...

5 months ago | 3 answers | 0

### 3

Question

remove all ones from matrix in combinantion
I have A A=[0 0 0 0 0 0 0 0 0 0; 0 0 0 1 0 1 0 0 0 0; 0 0 0 1 1 0 0 0 0 0; 0 0 0 0 0 1 0 0 0 0; 0 0 0 0 0 0...

5 months ago | 1 answer | 0

### 1

Question

How to use unique function here
I have A={{[1,3,4],[1],[2,3,4,6,8]},{[1,2,34],[1,2,3,4,5,6,7],[1,2,9,6,4],[1,3,4]},{[8,9],[2,3,4,6,8],[1,3,4]}}; A = cellfun(...

5 months ago | 1 answer | 0

### 1

Question

Need to remove elements which repeated 2 times
I have A=[1 2; 1,3; 1,4; 1,5; 2,3; 3,6; 4,5; 5,6]; element 2, 4, 6 repeated 2 times. I want to remove them from A. A_new=[1...

5 months ago | 1 answer | 0

### 1

Question

How to keep column of removed row in matrix
I have matrix A and want to remove the rows of A that have nonzero element. Also want to keep the index of removed columns and r...

6 months ago | 1 answer | 0

### 1

Question

How can I draw non planar graph in 3D dimension
I have an edge data. G=graph(E(:,1),E(:,2)) h=plot(G) I want to draw it in 3D dimension. Is there any way to do that? I saw...

6 months ago | 1 answer | 0

### 1

Question

Find the index of zero in cell and put it as empty
A={[45;101],[2;7],[5;8],0,0}; A(cell2mat(A)==0)={[]}; % I want to find zero and put in empty A should be A={[45;101],[2;7],[5...

7 months ago | 1 answer | 0

### 1

Question

how to write superscripts for x-axis in a boxplot
I have h=boxplot(x, g, 'notch','off','label', {'89_{p}','10007_{p}','3067_{M}'}); how to write p as a superscripts for x-axis...

7 months ago | 2 answers | 0

### 2

Question

how to change font size of bus number in graph
I have this graph M=[1,2;3,4;4,1;2,3] g = graph(M(:, 1), M(:, 2)); h = plot(g); I have attached the graph here and want to c...

7 months ago | 1 answer | 0