Homework Statement
Hi. The problem assigned to me is to take a column vector of 100 entries and then to randomly assign add a 0 or 1 to a random entry, and then to repeat this "n" # of times, where the upper "n" is 1 million.
I have this so far
h = zeros(100,1)
h(round(rand(1)*100))...
Doesn't work either. I know a "for" loop would work, summing up the single "areas" to a specific value of x for each x, but I don't know how to implement it.
MATLAB - "for" loop for numerical integration
Hi. The following bit of MATLAB function is supposed indefinitely integrate successive points:
% Explode triplet format into vectors
x_in = data_in(:,1)';
y_in = data_in(:,2)';
e_in = data_in(:,3)';
x_left=x_in(1:end-1)...