Question

use mvnrnd with some conditions

Hello Consider this example in MathWorks website: n=1000; sigma=0.5; Sigmalnd=sigma.^2.*[1 0; 0 1]; rng(default); ZIn...

27 days ago | 1 answer | 0

Question

Brace indexing is not supported for variables of this type.

Hello I have got this error message: Error in cell2mat (line 36) if isnumeric(c{1}) || ischar(c{1}) || islogical(c{1}) ...

1 month ago | 1 answer | 0

Question

problem in cell matrix operations

Hello I have code like this which gives out a 5*1 cell matrix: row = [0; 1; 2; 3; 4] ; Coh = [15;16 ;17; 18; 20;19;7;8;22;2...

1 month ago | 1 answer | 0

Question

grouping data in column vector based on another vector

Hello I have a column vector A as [0;1;2;3;4]. On the other hand, there is another column vector called C=[15;16 ;17; 18; 20;...

1 month ago | 2 answers | 0

Question

How to multiply a matrix to another cell matrix

Hello I have a 3*3 matrix such as [1 0 0; 8 23 1; 5 7 10] On the other hand, I have matrix 2000*1 containin...

1 month ago | 2 answers | 0

Question

How to convert a matrix into some cells?

Hello I have a big matrix which i want to convert to equal submatrixces in cell form. As an illustration imagine this matrix: ...

1 month ago | 1 answer | 0

Question

How to increase the size of a matrix within for loop

Hello There is a for loop in my code. imagine i obtain value 1 after the first iteration, so it would be my first array in the...

1 month ago | 1 answer | 0

Question

How to generate different numbers of random variables in each Monte Carlo iteration (random fields)

Hello I am modeling random fields in each monte carlo simulation. In this regard, I am usnig the mvnrnd command to generate dep...

1 month ago | 0 answers | 0

Question

generating correlated random variables

Hello Though the subject might seem similar to other subjects available in this forum, it is indeed different. I am doing a M...

1 month ago | 1 answer | 0

Question

Assigning values and classification/grouping

Hello I am defining some slices in matlab (n is the number of slice and the curve in the figure is part of a circle), which ha...

1 month ago | 0 answers | 0

Question

reproduce random numbers for the third dimension

Hello I want to generate random numbers for matrix A which has a second page(i.e. 2), whose values i am going to assign to ano...

2 months ago | 1 answer | 0

Question

unclear number of if or maybe other commands?!

Hello I am confused in writing a code which i am going to explain. imagine there is a row matrix whose dimension is not clea...

2 months ago | 1 answer | 0

Question

Classify rows of a matrix

Hello I want to know how it is possible to define a condition as if the numbers at the second column of some rows of a matrix a...

3 months ago | 1 answer | 0

Question

Speed up the code

Hello This code is part of a total code. It calculates the geometrical features of the main problem geometry. However, it takes...

3 months ago | 0 answers | 0

Question

solve a vector of independent equations with only one variable

Hello Could anyone please guide me as to how solve this system of vector equations(EQ), so it would give me a vector of solutio...

4 months ago | 1 answer | 0

Question

The solution process takes too long+vpasolve

Hello, I am solving a single variable nonlinear equation(i.e. eqn) using vpasolve. The solution speed is fine if n is equal to 1...

11 months ago | 0 answers | 0

Question

the error"The function values at the interval endpoints must differ in sign" + fzero

Hello. I want to solve the beneath nonlinear eqn(there is only one variable) as the code below. When using fzero, I get the erro...

11 months ago | 1 answer | 0

Question

How to solve this system of nonlinear equations composed of symbolic variables

Hi I want to solve 3 nonlinear equations with 2 unknowns. The equations are composed of symbolic variables. When I run the co...

12 months ago | 1 answer | 0