vectorization
Show older comments
Hi, can any body suggest as to how I can vectorize this little bit of code:
% for i = 2:n % f(i) = f(i-1)+dx*x(i-1); % end
where, f = zeros(1,n); dx = 1/(n-1); x = 0:dx:1;
appreciate any help, because I am kind of stuck and right now don't think it can be done at all. Thanks, Asit
Accepted Answer
More Answers (0)
Categories
Find more on Creating and Concatenating Matrices in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!