Question


why when I use mvrnd to generate random vectors from a multivariate normal I always get small numbers in absolute value ?
Hi, why when I use mvrnd to generate random vectors from a multivariate normal I always get small numbers in absolute value (no...

fast 8 Jahre ago | 1 answer | 0

1

answer

Question


Using ngrid to create a matrix listing all combinations of values from row vectors
Hi, I have the following vectors A= [1 2 3 4]; B= [1 2]; C= [1 2 3 6 7 8]; D= [1 3 6]; and I want to cr...

fast 8 Jahre ago | 2 answers | 0

2

answers

Question


How to compare a vector A of real numbers with a vector of zeros using equalities and inequalities?
Hi, I have a vector A mx1 which should be compared with a mx1 vector of zeros. In particular: for the first n<m elements I want...

fast 8 Jahre ago | 1 answer | 0

1

answer

Question


"Meshgrid" in more than 3 dimensions?
Hi, I have the following vectors A= [1;2;3;4;5;6]; B= [1;2;3;4;5;6]; C= [1;2;3;6;7;8]; D= [-1;0;9;8;2;3;5]; E=...

fast 8 Jahre ago | 2 answers | 1

2

answers

Question


How can I set 32 workers performing parfor?
Hi, I'm using Matlab in the HPC cluster of my department. I know that the HPC has a matlab parallel license for up to 32 wor...

etwa 8 Jahre ago | 1 answer | 0

1

answer

Question


How can I sum the rows of a matrix at a fixed distance between each other?
Hi, I have a vector A (m*p)x1 and I want to create a vector B px1 where B(i)=sum_{n=0}^{m-1}A(i+p*n), e.g. m=3; p=4; ...

etwa 8 Jahre ago | 2 answers | 1

2

answers

Question


How can I count the occurrences of each element in a column vector and store them in a vector of the same dimension as the original one?
Hi, I have a vector A mx1 and I want to create a vector B mx1 reporting the number of occurrences of each element in A, e.g. i...

etwa 8 Jahre ago | 2 answers | 0

2

answers

Question


How to pick the elements in a vector with row coordinates satisfying a criterion determined by another vector?
Hi, I have a column vector A reporting the first m natural numbers, each of them repeated an arbitrary number of times, e.g. ...

etwa 8 Jahre ago | 2 answers | 0

2

answers

Question


"Kronecker" of varying dimensions?
Hi, I have a matrix A of dimension m x n and a vector b of natural numbers with dimension m x 1. I want to obtain a matrix C of...

etwa 8 Jahre ago | 1 answer | 0

1

answer

Question


How can I compare two matrices of different dimensions without looping?
Hi, I have two matrices of different dimensions. For example: A=[1 1 1 1; 2 1 1 1; 2 0 0 0; 3 0 1 0; 3 0 0 0; 3 0 0 1; 4 1...

etwa 8 Jahre ago | 1 answer | 0

1

answer

Question


Why is the execution time changing?
Hi, I have two versions of a code. Both versions are divided into two parts and the two versions differ for the first part, whi...

etwa 8 Jahre ago | 2 answers | 0

2

answers

Question


problems with parfor and matlabpool: Error using parallel_function at 598
Hi, I'm trying to speed up my code using parfor instead of for but it doesn't work. It gives me the error: ??? Error using ==> ...

etwa 8 Jahre ago | 2 answers | 0

2

answers

Question


How can I modify this code to use parfor s=1:r?
Hi, I have reported here a very simple piece of code but it basically faces the same issues of my actual estimation code. Could...

etwa 8 Jahre ago | 1 answer | 0

1

answer

Question


parfor and global variables
Hi, could you help me please in solving this problem? I need to use parfor and at the same time the function simuconf inside par...

etwa 8 Jahre ago | 2 answers | 0

2

answers

Question


Transform a two dimensional into a three dimensional and combine with another three dimensional array
Hi, I have this matrix A=randn(4,3); and I want to transform it in a three dimensional matrix by stacking that matrix ...

etwa 8 Jahre ago | 2 answers | 0

2

answers

Question


How can I change this code to be able to use parfor?
A=randn(5,1); parfor i=1:4 B=randn(3,1); for t=1:size(B,1) for w=1:size(A,1) ...

etwa 8 Jahre ago | 1 answer | 0

1

answer