Community Profile # Rasul Khan

##### Last seen: 1 month ago
10 total contributions since 2020

View details...

Contributions in
View by

Categorizing array elements based on percentage
You can have the four categories separated this way. a = 1 : 20; odd_ind = a(1 : 2 : end); category1 = odd_ind( (1 : end) <= ...

1 month ago | 0

| accepted

wab =733;r=0.0405;L=0.13; theta = 0:0.1:2*pi; x = (r*sin(theta))/L; phi = asin(x); a = wab*r*sin(theta); b = L*sin(phi); w...

1 month ago | 0

lim x arrow 4 x^2+3x/x^2-x-12
You have to declare x as a symbol. Try it this way syms x; f = (x^2 + 3 * x) / (x ^ 2 - x - 12); % your function result = lim...

1 month ago | 0

How to make a structure unique?
You can achieve it using this script. m = []; for i = 1 : numel(pop) m = [m ; pop(i).x]; end [~ , ia , ~] = unique(m , ...

1 month ago | 1

| accepted

Find a row with all elements satisfying a condition
You can achieve it with a loop. The required matrix will be stored in res res = [] for i = 1 : size(mat , 1) if ~any( mat...

1 month ago | 0

Dimensions of matrices being concatenated are not consistent.
If you take a close look you can see there are 3 rows in Q with 8 elements in the first row and 4 on subsequent rows. But MATLAB...

2 months ago | 1

list of the names of the variables in a column
The output of tb(: , 1) is a cell array with all the variables. You can run this script. It will store the result in a res varia...

2 months ago | 0

| accepted

Mean returns Inf value why?
It's because there is atleast one Inf value in each row. You can check with this script for i = 1 : 101 if any(isinf(Mag1_...

2 months ago | 0

| accepted